diff options
author | Andy Shaw <andy.shaw@theqtcompany.com> | 2016-02-26 01:10:31 +0100 |
---|---|---|
committer | Andy Shaw <andy.shaw@theqtcompany.com> | 2016-02-26 14:19:08 +0000 |
commit | e5b35c47f3bbb23800a50cfc1c34c9a99b2c6d7b (patch) | |
tree | 88a6d51d5e4f97c481589c6be9d689b2a75ae605 | |
parent | acddf902facb16b40d3f9c0ccd28fcdbc49c87dc (diff) |
Enable using the module in a statically built applicationv5.7.0-alpha1
Change-Id: I703af8402b38309562c2de9029070ac19a36c7f0
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
-rw-r--r-- | src/imports/winextras/plugin.cpp | 8 | ||||
-rw-r--r-- | src/imports/winextras/qmldir | 1 |
2 files changed, 9 insertions, 0 deletions
diff --git a/src/imports/winextras/plugin.cpp b/src/imports/winextras/plugin.cpp index 18e2ded..c74cd2b 100644 --- a/src/imports/winextras/plugin.cpp +++ b/src/imports/winextras/plugin.cpp @@ -49,6 +49,13 @@ #include <QtQml/QtQml> +static void initResources() +{ +#ifdef QT_STATIC + Q_INIT_RESOURCE(qmake_QtWinExtras); +#endif +} + QT_BEGIN_NAMESPACE class QWinExtrasQmlPlugin : public QQmlExtensionPlugin @@ -57,6 +64,7 @@ class QWinExtrasQmlPlugin : public QQmlExtensionPlugin Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QQmlExtensionInterface/1.0") public: + QWinExtrasQmlPlugin(QObject *parent = 0) : QQmlExtensionPlugin(parent) { initResources(); } void registerTypes(const char *uri) Q_DECL_OVERRIDE { Q_ASSERT(uri == QLatin1String("QtWinExtras")); diff --git a/src/imports/winextras/qmldir b/src/imports/winextras/qmldir index bcba196..f3c244c 100644 --- a/src/imports/winextras/qmldir +++ b/src/imports/winextras/qmldir @@ -3,3 +3,4 @@ plugin qml_winextras JumpListLink 1.0 JumpListLink.qml JumpListDestination 1.0 JumpListDestination.qml JumpListSeparator 1.0 JumpListSeparator.qml +classname QWinExtrasQmlPlugin |