aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/qtsupport/gettingstartedwelcomepage.h
diff options
context:
space:
mode:
authorhjk <hjk@qt.io>2017-01-06 21:41:46 +0100
committerhjk <hjk@qt.io>2017-01-13 15:38:14 +0000
commit16944277d2aa2cdab194ec05de6c8e2d5ee814cd (patch)
tree65be67b94d693eaf5874880aa60241015acc8c6c /src/plugins/qtsupport/gettingstartedwelcomepage.h
parent36d1a75118ad31861b64272716d189090e0b4e4d (diff)
Welcome: Start some performance improvements
This is essentially a widgets based re-implementation of the current design. It is still using the QAIM based interface layer between to the real data and display even though this is not needed with this approach. Removal of this layer would further reduce code size and cycle counts. For now: old new Load time 215ms 182ms delete 22ms 2ms Change-Id: I90d779a60a47a78399eaad0f1bc032d39f3ae3c0 Reviewed-by: Eike Ziller <eike.ziller@qt.io> Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Diffstat (limited to 'src/plugins/qtsupport/gettingstartedwelcomepage.h')
-rw-r--r--src/plugins/qtsupport/gettingstartedwelcomepage.h31
1 files changed, 11 insertions, 20 deletions
diff --git a/src/plugins/qtsupport/gettingstartedwelcomepage.h b/src/plugins/qtsupport/gettingstartedwelcomepage.h
index 689e75fb4a9..8a78ceffe9d 100644
--- a/src/plugins/qtsupport/gettingstartedwelcomepage.h
+++ b/src/plugins/qtsupport/gettingstartedwelcomepage.h
@@ -30,7 +30,6 @@
#include <QStringList>
QT_BEGIN_NAMESPACE
-class QQmlEngine;
class QFileInfo;
QT_END_NAMESPACE
@@ -44,29 +43,21 @@ class ExamplesWelcomePage : public Core::IWelcomePage
Q_OBJECT
public:
- ExamplesWelcomePage();
+ explicit ExamplesWelcomePage(bool showExamples);
- void setShowExamples(bool showExamples);
- QUrl pageLocation() const;
- QString title() const;
- int priority() const;
- bool hasSearchBar() const;
- void facilitateQml(QQmlEngine *);
- Core::Id id() const;
- Q_INVOKABLE void openUrl(const QUrl &url);
+ QString title() const final;
+ int priority() const final;
+ Core::Id id() const final;
+ QWidget *createWidget() const final;
-public slots:
- void openHelpInExtraWindow(const QUrl &help);
- void openHelp(const QUrl &help);
- void openProject(const QString& projectFile, const QStringList& additionalFilesToOpen,
- const QString &mainFile, const QUrl& help, const QStringList &dependencies,
- const QStringList &platforms);
+ static void openHelpInExtraWindow(const QUrl &help);
+ static void openProject(const QString& projectFile, const QStringList& additionalFilesToOpen,
+ const QString &mainFile, const QUrl &help,
+ const QStringList &dependencies, const QStringList &platforms);
private:
- ExamplesListModel *examplesModel() const;
- QString copyToAlternativeLocation(const QFileInfo &fileInfo, QStringList &filesToOpen, const QStringList &dependencies);
- QQmlEngine *m_engine;
- bool m_showExamples;
+ static QString copyToAlternativeLocation(const QFileInfo &fileInfo, QStringList &filesToOpen, const QStringList &dependencies);
+ const bool m_showExamples;
};
} // namespace Internal