diff options
author | Friedemann Kleint <Friedemann.Kleint@nokia.com> | 2012-02-21 10:55:34 +0100 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-02-23 09:05:49 +0100 |
commit | fb3889a423365b1736cae8850cdb2b3ac77b14a8 (patch) | |
tree | 65d7c1f7db7de65035ab91a16a136c4556f026bd | |
parent | dc3165178851b9bda71dd238c8a5faca4dfa7a45 (diff) |
Use new plugin system in QtDeclarative.
- Use prefix "org.qt-project" for interfaces.
- Use new macros, add json files.
Change-Id: I53df83f95153c5c9c462098584606284470a5ae0
Reviewed-by: Martin Jones <martin.jones@nokia.com>
55 files changed, 101 insertions, 55 deletions
diff --git a/examples/declarative/cppextensions/imageprovider/imageprovider.cpp b/examples/declarative/cppextensions/imageprovider/imageprovider.cpp index 94f85753ed..7fe4b72c08 100644 --- a/examples/declarative/cppextensions/imageprovider/imageprovider.cpp +++ b/examples/declarative/cppextensions/imageprovider/imageprovider.cpp @@ -87,6 +87,7 @@ public: class ImageProviderExtensionPlugin : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "imageprovider.json") public: void registerTypes(const char *uri) { @@ -101,7 +102,8 @@ public: }; -#include "imageprovider.moc" -Q_EXPORT_PLUGIN(ImageProviderExtensionPlugin); +#define QDeclarativeExtensionInterface_iid "org.qt-project.Qt.QDeclarativeExtensionInterface" + +#include "imageprovider.moc" diff --git a/examples/declarative/cppextensions/imageprovider/imageprovider.json b/examples/declarative/cppextensions/imageprovider/imageprovider.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/examples/declarative/cppextensions/imageprovider/imageprovider.json @@ -0,0 +1 @@ +{} diff --git a/examples/declarative/cppextensions/imageprovider/imageprovider.pro b/examples/declarative/cppextensions/imageprovider/imageprovider.pro index cfa7923128..dd128d56a8 100644 --- a/examples/declarative/cppextensions/imageprovider/imageprovider.pro +++ b/examples/declarative/cppextensions/imageprovider/imageprovider.pro @@ -7,6 +7,8 @@ TARGET = qmlimageproviderplugin SOURCES += imageprovider.cpp +OTHER_FILES += imageprovider.json + sources.files = $$SOURCES imageprovider.qml imageprovider.pro sources.path = $$[QT_INSTALL_EXAMPLES]/qtdeclarative/declarative/imageprovider diff --git a/examples/declarative/cppextensions/plugins/plugin.cpp b/examples/declarative/cppextensions/plugins/plugin.cpp index 6fbf962f4e..4ba0a928eb 100644 --- a/examples/declarative/cppextensions/plugins/plugin.cpp +++ b/examples/declarative/cppextensions/plugins/plugin.cpp @@ -141,6 +141,8 @@ MinuteTimer *TimeModel::timer=0; class QExampleQmlPlugin : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "plugin.json") + public: void registerTypes(const char *uri) { @@ -151,7 +153,3 @@ public: //![plugin] #include "plugin.moc" - -//![export] -Q_EXPORT_PLUGIN2(qmlqtimeexampleplugin, QExampleQmlPlugin); -//![export] diff --git a/examples/declarative/cppextensions/plugins/plugin.json b/examples/declarative/cppextensions/plugins/plugin.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/examples/declarative/cppextensions/plugins/plugin.json @@ -0,0 +1 @@ +{} diff --git a/examples/declarative/cppextensions/plugins/plugins.pro b/examples/declarative/cppextensions/plugins/plugins.pro index bdcb62ca8a..a28582a07a 100644 --- a/examples/declarative/cppextensions/plugins/plugins.pro +++ b/examples/declarative/cppextensions/plugins/plugins.pro @@ -7,6 +7,8 @@ TARGET = qmlqtimeexampleplugin SOURCES += plugin.cpp +OTHER_FILES += "plugin.json" + qdeclarativesources.files += \ com/nokia/TimeExample/qmldir \ com/nokia/TimeExample/center.png \ diff --git a/examples/declarative/cppextensions/qwidgets/qwidgets.json b/examples/declarative/cppextensions/qwidgets/qwidgets.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/examples/declarative/cppextensions/qwidgets/qwidgets.json @@ -0,0 +1 @@ +{} diff --git a/examples/declarative/painteditem/textballoons/TextBalloonPlugin/plugin.h b/examples/declarative/painteditem/textballoons/TextBalloonPlugin/plugin.h index 6be8611dfd..f444d31f4e 100644 --- a/examples/declarative/painteditem/textballoons/TextBalloonPlugin/plugin.h +++ b/examples/declarative/painteditem/textballoons/TextBalloonPlugin/plugin.h @@ -46,11 +46,10 @@ class TextBalloonPlugin : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "textballoon.json") public: void registerTypes(const char *uri) { qmlRegisterType<TextBalloon>(uri, 1, 0, "TextBalloon"); } }; - -Q_EXPORT_PLUGIN2(qmltextballoonplugin, TextBalloonPlugin); diff --git a/examples/declarative/painteditem/textballoons/TextBalloonPlugin/textballoon.json b/examples/declarative/painteditem/textballoons/TextBalloonPlugin/textballoon.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/examples/declarative/painteditem/textballoons/TextBalloonPlugin/textballoon.json @@ -0,0 +1 @@ +{} diff --git a/examples/declarative/painteditem/textballoons/textballoons.pro b/examples/declarative/painteditem/textballoons/textballoons.pro index 453a00336d..e0b9404f65 100644 --- a/examples/declarative/painteditem/textballoons/textballoons.pro +++ b/examples/declarative/painteditem/textballoons/textballoons.pro @@ -9,6 +9,8 @@ HEADERS += TextBalloonPlugin/plugin.h \ SOURCES += textballoon.cpp +OTHER_FILES += textballoon.json + DESTDIR = TextBalloonPlugin qdeclarativesources.files += \ diff --git a/examples/declarative/tutorials/extending/chapter6-plugins/chartsplugin.cpp b/examples/declarative/tutorials/extending/chapter6-plugins/chartsplugin.cpp index 9c4027de8a..d75f810964 100644 --- a/examples/declarative/tutorials/extending/chapter6-plugins/chartsplugin.cpp +++ b/examples/declarative/tutorials/extending/chapter6-plugins/chartsplugin.cpp @@ -49,6 +49,5 @@ void ChartsPlugin::registerTypes(const char *uri) qmlRegisterType<PieSlice>(uri, 1, 0, "PieSlice"); } -Q_EXPORT_PLUGIN2(chartsplugin, ChartsPlugin); //![0] diff --git a/examples/declarative/tutorials/extending/chapter6-plugins/chartsplugin.h b/examples/declarative/tutorials/extending/chapter6-plugins/chartsplugin.h index bffcf000fd..863564b09c 100644 --- a/examples/declarative/tutorials/extending/chapter6-plugins/chartsplugin.h +++ b/examples/declarative/tutorials/extending/chapter6-plugins/chartsplugin.h @@ -46,6 +46,8 @@ class ChartsPlugin : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "chartsplugin.json") + public: void registerTypes(const char *uri); }; diff --git a/examples/declarative/tutorials/extending/chapter6-plugins/chartsplugin.json b/examples/declarative/tutorials/extending/chapter6-plugins/chartsplugin.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter6-plugins/chartsplugin.json @@ -0,0 +1 @@ +{} diff --git a/examples/tutorials/gettingStartedQml/filedialog/dialogPlugin.cpp b/examples/tutorials/gettingStartedQml/filedialog/dialogPlugin.cpp index 6bc3d4d006..626ef93adc 100644 --- a/examples/tutorials/gettingStartedQml/filedialog/dialogPlugin.cpp +++ b/examples/tutorials/gettingStartedQml/filedialog/dialogPlugin.cpp @@ -49,6 +49,3 @@ void DialogPlugin::registerTypes(const char *uri) qmlRegisterType<Directory>(uri, 1, 0, "Directory"); qmlRegisterType<File>(uri,1,0,"File"); } - -//FileDialog is the plugin name (same as the TARGET in the project file) and DialogPlugin is the plugin classs -Q_EXPORT_PLUGIN2(FileDialog, DialogPlugin);
\ No newline at end of file diff --git a/examples/tutorials/gettingStartedQml/filedialog/dialogPlugin.h b/examples/tutorials/gettingStartedQml/filedialog/dialogPlugin.h index 03bdc1a6e4..7ad707f6d9 100644 --- a/examples/tutorials/gettingStartedQml/filedialog/dialogPlugin.h +++ b/examples/tutorials/gettingStartedQml/filedialog/dialogPlugin.h @@ -46,6 +46,7 @@ class DialogPlugin : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "dialogplugin.json") public: //registerTypes is inherited from QDeclarativeExtensionPlugin diff --git a/examples/tutorials/gettingStartedQml/filedialog/dialogplugin.json b/examples/tutorials/gettingStartedQml/filedialog/dialogplugin.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/examples/tutorials/gettingStartedQml/filedialog/dialogplugin.json @@ -0,0 +1 @@ +{} diff --git a/src/declarative/debugger/qdeclarativedebugserverconnection_p.h b/src/declarative/debugger/qdeclarativedebugserverconnection_p.h index aa1c8aa0f1..e78657a73d 100644 --- a/src/declarative/debugger/qdeclarativedebugserverconnection_p.h +++ b/src/declarative/debugger/qdeclarativedebugserverconnection_p.h @@ -75,7 +75,9 @@ public: virtual bool waitForMessage() = 0; }; -Q_DECLARE_INTERFACE(QDeclarativeDebugServerConnection, "com.trolltech.Qt.QDeclarativeDebugServerConnection/1.0") +#define QDeclarativeDebugServerConnection_iid "org.qt-project.Qt.QDeclarativeDebugServerConnection" + +Q_DECLARE_INTERFACE(QDeclarativeDebugServerConnection, QDeclarativeDebugServerConnection_iid) QT_END_NAMESPACE diff --git a/src/declarative/debugger/qdeclarativeinspectorinterface_p.h b/src/declarative/debugger/qdeclarativeinspectorinterface_p.h index e109fc015e..adfd94333d 100644 --- a/src/declarative/debugger/qdeclarativeinspectorinterface_p.h +++ b/src/declarative/debugger/qdeclarativeinspectorinterface_p.h @@ -74,7 +74,9 @@ public: virtual void clientMessage(const QByteArray &message) = 0; }; -Q_DECLARE_INTERFACE(QDeclarativeInspectorInterface, "com.trolltech.Qt.QDeclarativeInspectorInterface/1.0") +#define QDeclarativeInspectorInterface_iid "org.qt-project.Qt." + +Q_DECLARE_INTERFACE(QDeclarativeInspectorInterface, QDeclarativeInspectorInterface_iid) QT_END_NAMESPACE diff --git a/src/declarative/qml/qdeclarativeextensioninterface.h b/src/declarative/qml/qdeclarativeextensioninterface.h index fcfaa7c402..ce2560cec0 100644 --- a/src/declarative/qml/qdeclarativeextensioninterface.h +++ b/src/declarative/qml/qdeclarativeextensioninterface.h @@ -65,8 +65,13 @@ public: virtual void initializeEngine(QDeclarativeEngine *engine, const char *uri) = 0; }; +#define QDeclarativeTypesExtensionInterface_iid "org.qt-project.Qt.QDeclarativeTypesExtensionInterface" + Q_DECLARE_INTERFACE(QDeclarativeTypesExtensionInterface, "org.qt-project.Qt.QDeclarativeTypesExtensionInterface/1.0") -Q_DECLARE_INTERFACE(QDeclarativeExtensionInterface, "org.qt-project.Qt.QDeclarativeExtensionInterface/1.0") + +#define QDeclarativeExtensionInterface_iid "org.qt-project.Qt.QDeclarativeExtensionInterface" + +Q_DECLARE_INTERFACE(QDeclarativeExtensionInterface, QDeclarativeExtensionInterface_iid) QT_END_NAMESPACE diff --git a/src/declarative/qml/qdeclarativepropertyvalueinterceptor_p.h b/src/declarative/qml/qdeclarativepropertyvalueinterceptor_p.h index ed5e54f646..939c45b6d4 100644 --- a/src/declarative/qml/qdeclarativepropertyvalueinterceptor_p.h +++ b/src/declarative/qml/qdeclarativepropertyvalueinterceptor_p.h @@ -66,7 +66,10 @@ public: virtual void setTarget(const QDeclarativeProperty &property) = 0; virtual void write(const QVariant &value) = 0; }; -Q_DECLARE_INTERFACE(QDeclarativePropertyValueInterceptor, "com.trolltech.qml.QDeclarativePropertyValueInterceptor") + +#define QDeclarativePropertyValueInterceptor_iid "org.qt-project.Qt.QDeclarativePropertyValueInterceptor" + +Q_DECLARE_INTERFACE(QDeclarativePropertyValueInterceptor, QDeclarativePropertyValueInterceptor_iid) QT_END_NAMESPACE diff --git a/src/declarative/qml/qdeclarativepropertyvaluesource.h b/src/declarative/qml/qdeclarativepropertyvaluesource.h index 4189cae345..d345319143 100644 --- a/src/declarative/qml/qdeclarativepropertyvaluesource.h +++ b/src/declarative/qml/qdeclarativepropertyvaluesource.h @@ -57,7 +57,10 @@ public: virtual ~QDeclarativePropertyValueSource(); virtual void setTarget(const QDeclarativeProperty &) = 0; }; -Q_DECLARE_INTERFACE(QDeclarativePropertyValueSource, "com.trolltech.qml.QDeclarativePropertyValueSource") + +#define QDeclarativePropertyValueSource_iid "org.qt-project.Qt.QDeclarativePropertyValueSource" + +Q_DECLARE_INTERFACE(QDeclarativePropertyValueSource, QDeclarativePropertyValueSource_iid) QT_END_NAMESPACE diff --git a/src/imports/folderlistmodel/folderlistmodel.json b/src/imports/folderlistmodel/folderlistmodel.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/src/imports/folderlistmodel/folderlistmodel.json @@ -0,0 +1 @@ +{} diff --git a/src/imports/folderlistmodel/plugin.cpp b/src/imports/folderlistmodel/plugin.cpp index 48d7b5b7cb..767f8f6c68 100644 --- a/src/imports/folderlistmodel/plugin.cpp +++ b/src/imports/folderlistmodel/plugin.cpp @@ -50,6 +50,8 @@ QT_BEGIN_NAMESPACE class QmlFolderListModelPlugin : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "folderlistmodel.json") + public: virtual void registerTypes(const char *uri) { @@ -64,8 +66,3 @@ public: QT_END_NAMESPACE #include "plugin.moc" - -//![plugin export decl] -Q_EXPORT_PLUGIN2(qmlfolderlistmodelplugin, QT_PREPEND_NAMESPACE(QmlFolderListModelPlugin)); -//![plugin export decl] - diff --git a/src/imports/gestures/gestures.json b/src/imports/gestures/gestures.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/src/imports/gestures/gestures.json @@ -0,0 +1 @@ +{} diff --git a/src/imports/localstorage/localstorage.json b/src/imports/localstorage/localstorage.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/src/imports/localstorage/localstorage.json @@ -0,0 +1 @@ +{} diff --git a/src/imports/localstorage/localstorage.pro b/src/imports/localstorage/localstorage.pro index 51a69aac4f..5164e8870d 100644 --- a/src/imports/localstorage/localstorage.pro +++ b/src/imports/localstorage/localstorage.pro @@ -6,10 +6,12 @@ QT += sql declarative declarative-private v8-private core-private SOURCES += plugin.cpp +OTHER_FILES += localstorage.json + DESTDIR = $$QT.declarative.imports/$$TARGETPATH target.path = $$[QT_INSTALL_IMPORTS]/$$TARGETPATH qmldir.files += $$PWD/qmldir qmldir.path += $$[QT_INSTALL_IMPORTS]/$$TARGETPATH -INSTALLS += target qmldir
\ No newline at end of file +INSTALLS += target qmldir diff --git a/src/imports/localstorage/plugin.cpp b/src/imports/localstorage/plugin.cpp index dd747d0d09..0ab47c1428 100644 --- a/src/imports/localstorage/plugin.cpp +++ b/src/imports/localstorage/plugin.cpp @@ -651,6 +651,8 @@ static QObject *module_api_factory(QDeclarativeEngine *engine, QJSEngine *script class QDeclarativeLocalStoragePlugin : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "localstorage.json") + public: QDeclarativeLocalStoragePlugin() { @@ -664,5 +666,3 @@ public: }; #include "plugin.moc" - -Q_EXPORT_PLUGIN2(plugin, QDeclarativeLocalStoragePlugin); diff --git a/src/imports/shaders/shaders.json b/src/imports/shaders/shaders.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/src/imports/shaders/shaders.json @@ -0,0 +1 @@ +{} diff --git a/src/imports/testlib/main.cpp b/src/imports/testlib/main.cpp index 672de10639..ec32d7c9ab 100644 --- a/src/imports/testlib/main.cpp +++ b/src/imports/testlib/main.cpp @@ -135,6 +135,8 @@ QT_BEGIN_NAMESPACE class QTestQmlModule : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "testlib.json") + public: virtual void registerTypes(const char *uri) { @@ -152,5 +154,3 @@ public: QT_END_NAMESPACE #include "main.moc" - -Q_EXPORT_PLUGIN2(qmltestplugin, QT_PREPEND_NAMESPACE(QTestQmlModule)) diff --git a/src/imports/testlib/testlib.json b/src/imports/testlib/testlib.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/src/imports/testlib/testlib.json @@ -0,0 +1 @@ +{} diff --git a/src/imports/testlib/testlib.pro b/src/imports/testlib/testlib.pro index 3b8a5bf75e..7e8f601468 100644 --- a/src/imports/testlib/testlib.pro +++ b/src/imports/testlib/testlib.pro @@ -7,7 +7,8 @@ CONFIG += qt plugin QT += declarative quick qmltest qmltest-private v8-private declarative-private core-private testlib SOURCES += main.cpp -HEADERS += + +OTHER_FILES += testlib.json DESTDIR = $$QT.declarative.imports/$$TARGETPATH diff --git a/src/imports/xmllistmodel/plugin.cpp b/src/imports/xmllistmodel/plugin.cpp index 9085a60885..07f59b846a 100644 --- a/src/imports/xmllistmodel/plugin.cpp +++ b/src/imports/xmllistmodel/plugin.cpp @@ -49,6 +49,8 @@ QT_BEGIN_NAMESPACE class QmlXmlListModelPlugin : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "xmllistmodel.json") + public: virtual void registerTypes(const char *uri) { @@ -61,5 +63,3 @@ public: QT_END_NAMESPACE #include "plugin.moc" - -Q_EXPORT_PLUGIN2(qmlxmllistmodelplugin, QT_PREPEND_NAMESPACE(QmlXmlListModelPlugin)); diff --git a/src/imports/xmllistmodel/xmllistmodel.json b/src/imports/xmllistmodel/xmllistmodel.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/src/imports/xmllistmodel/xmllistmodel.json @@ -0,0 +1 @@ +{} diff --git a/src/plugins/accessible/quick/accessible.json b/src/plugins/accessible/quick/accessible.json new file mode 100644 index 0000000000..845a45aa78 --- /dev/null +++ b/src/plugins/accessible/quick/accessible.json @@ -0,0 +1,3 @@ +{ + "Keys": [ "QQuickView", "QQuickItem" ] +} diff --git a/src/plugins/accessible/quick/main.cpp b/src/plugins/accessible/quick/main.cpp index 08a5fe546b..af9555c690 100644 --- a/src/plugins/accessible/quick/main.cpp +++ b/src/plugins/accessible/quick/main.cpp @@ -59,6 +59,9 @@ QT_BEGIN_NAMESPACE class AccessibleQuickFactory : public QAccessiblePlugin { + Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QAccessibleFactoryInterface" FILE "accessible.json") + public: AccessibleQuickFactory(); @@ -105,9 +108,8 @@ QAccessibleInterface *AccessibleQuickFactory::create(const QString &classname, Q return 0; } -Q_EXPORT_STATIC_PLUGIN(AccessibleQuickFactory) -Q_EXPORT_PLUGIN2(qtaccessiblequick, AccessibleQuickFactory) - QT_END_NAMESPACE +#include "main.moc" + #endif // QT_NO_ACCESSIBILITY diff --git a/src/plugins/accessible/quick/quick.pro b/src/plugins/accessible/quick/quick.pro index 97a1d50098..add275a815 100644 --- a/src/plugins/accessible/quick/quick.pro +++ b/src/plugins/accessible/quick/quick.pro @@ -19,5 +19,7 @@ SOURCES += \ HEADERS += \ qaccessiblequickview.h \ qaccessiblequickitem.h + +OTHERFILES += accessible.json } diff --git a/src/plugins/qmltooling/qmldbg_qtquick2/qmldbg_qtquick2.pro b/src/plugins/qmltooling/qmldbg_qtquick2/qmldbg_qtquick2.pro index b9c6584afc..24efee8725 100644 --- a/src/plugins/qmltooling/qmldbg_qtquick2/qmldbg_qtquick2.pro +++ b/src/plugins/qmltooling/qmldbg_qtquick2/qmldbg_qtquick2.pro @@ -27,5 +27,7 @@ HEADERS += \ ../shared/qdeclarativeinspectorprotocol.h \ ../shared/qmlinspectorconstants.h +OTHER_FILES += qtquick2plugin.json + target.path += $$[QT_INSTALL_PLUGINS]/qmltooling INSTALLS += target diff --git a/src/plugins/qmltooling/qmldbg_qtquick2/qtquick2plugin.cpp b/src/plugins/qmltooling/qmldbg_qtquick2/qtquick2plugin.cpp index 206d0b2eb9..1245a7e690 100644 --- a/src/plugins/qmltooling/qmldbg_qtquick2/qtquick2plugin.cpp +++ b/src/plugins/qmltooling/qmldbg_qtquick2/qtquick2plugin.cpp @@ -84,5 +84,3 @@ void QtQuick2Plugin::clientMessage(const QByteArray &message) } // namespace QtQuick2 } // namespace QmlJSDebugger - -Q_EXPORT_PLUGIN2(qmldbg_qtquick2, QmlJSDebugger::QtQuick2::QtQuick2Plugin) diff --git a/src/plugins/qmltooling/qmldbg_qtquick2/qtquick2plugin.h b/src/plugins/qmltooling/qmldbg_qtquick2/qtquick2plugin.h index d0f814c03c..f6f668d6b4 100644 --- a/src/plugins/qmltooling/qmldbg_qtquick2/qtquick2plugin.h +++ b/src/plugins/qmltooling/qmldbg_qtquick2/qtquick2plugin.h @@ -55,6 +55,7 @@ class QtQuick2Plugin : public QObject, public QDeclarativeInspectorInterface { Q_OBJECT Q_DISABLE_COPY(QtQuick2Plugin) + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeInspectorInterface" FILE "qtquick2plugin.json") Q_INTERFACES(QDeclarativeInspectorInterface) public: diff --git a/src/plugins/qmltooling/qmldbg_qtquick2/qtquick2plugin.json b/src/plugins/qmltooling/qmldbg_qtquick2/qtquick2plugin.json new file mode 100644 index 0000000000..311847daa5 --- /dev/null +++ b/src/plugins/qmltooling/qmldbg_qtquick2/qtquick2plugin.json @@ -0,0 +1,2 @@ +{} + diff --git a/src/plugins/qmltooling/qmldbg_tcp/qmldbg_tcp.pro b/src/plugins/qmltooling/qmldbg_tcp/qmldbg_tcp.pro index 8ab507c055..075cc49ae5 100644 --- a/src/plugins/qmltooling/qmldbg_tcp/qmldbg_tcp.pro +++ b/src/plugins/qmltooling/qmldbg_tcp/qmldbg_tcp.pro @@ -14,5 +14,7 @@ SOURCES += \ HEADERS += \ qtcpserverconnection.h +OTHER_FILES += qtcpserverconnection.json + target.path += $$[QT_INSTALL_PLUGINS]/qmltooling INSTALLS += target diff --git a/src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.cpp b/src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.cpp index 529d2094bf..216c2c30b1 100644 --- a/src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.cpp +++ b/src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.cpp @@ -193,7 +193,5 @@ void QTcpServerConnection::invalidPacket() qWarning("QDeclarativeDebugServer: Received a corrupted packet! Giving up ..."); } -Q_EXPORT_PLUGIN2(tcpserver, QTcpServerConnection) - QT_END_NAMESPACE diff --git a/src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.h b/src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.h index f090c9709f..1154a0aa25 100644 --- a/src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.h +++ b/src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.h @@ -54,9 +54,9 @@ class QTcpServerConnection : public QObject, public QDeclarativeDebugServerConne Q_OBJECT Q_DECLARE_PRIVATE(QTcpServerConnection) Q_DISABLE_COPY(QTcpServerConnection) + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeDebugServerConnection" FILE "qtcpserverconnection.json") Q_INTERFACES(QDeclarativeDebugServerConnection) - public: QTcpServerConnection(); ~QTcpServerConnection(); diff --git a/src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.json b/src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/src/plugins/qmltooling/qmldbg_tcp/qtcpserverconnection.json @@ -0,0 +1 @@ +{} diff --git a/src/quick/items/qquickvisualadaptormodel_p.h b/src/quick/items/qquickvisualadaptormodel_p.h index 9ae8325450..e431f3aa26 100644 --- a/src/quick/items/qquickvisualadaptormodel_p.h +++ b/src/quick/items/qquickvisualadaptormodel_p.h @@ -121,7 +121,9 @@ public: virtual QObject *proxiedObject() = 0; }; -Q_DECLARE_INTERFACE(QQuickVisualAdaptorModelProxyInterface, "com.trolltech.qml.QQuickVisualAdaptorModelProxyInterface") +#define QQuickVisualAdaptorModelProxyInterface_iid "org.qt-project.Qt.QQuickVisualAdaptorModelProxyInterface" + +Q_DECLARE_INTERFACE(QQuickVisualAdaptorModelProxyInterface, QQuickVisualAdaptorModelProxyInterface_iid) QT_END_NAMESPACE diff --git a/src/quick/scenegraph/qsgcontextplugin_p.h b/src/quick/scenegraph/qsgcontextplugin_p.h index 081e64ecdd..6080c8b394 100644 --- a/src/quick/scenegraph/qsgcontextplugin_p.h +++ b/src/quick/scenegraph/qsgcontextplugin_p.h @@ -62,7 +62,7 @@ struct Q_QUICK_EXPORT QSGContextFactoryInterface : public QFactoryInterface }; #define QSGContextFactoryInterface_iid \ - "com.trolltech.Qt.QSGContextFactoryInterface" + "org.qt-project.Qt.QSGContextFactoryInterface" Q_DECLARE_INTERFACE(QSGContextFactoryInterface, QSGContextFactoryInterface_iid) class Q_QUICK_EXPORT QSGContextPlugin : public QObject, public QSGContextFactoryInterface diff --git a/tests/auto/declarative/qdeclarativelanguage/testtypes.h b/tests/auto/declarative/qdeclarativelanguage/testtypes.h index 4a37139056..ec0c185123 100644 --- a/tests/auto/declarative/qdeclarativelanguage/testtypes.h +++ b/tests/auto/declarative/qdeclarativelanguage/testtypes.h @@ -67,7 +67,8 @@ public: }; QT_BEGIN_NAMESPACE -Q_DECLARE_INTERFACE(MyInterface, "com.trolltech.Qt.Test.MyInterface"); +#define MyInterface_iid "org.qt-project.Qt.Test.MyInterface" +Q_DECLARE_INTERFACE(MyInterface, MyInterface_iid); QT_END_NAMESPACE QML_DECLARE_INTERFACE(MyInterface); diff --git a/tests/auto/declarative/qdeclarativemoduleplugin/empty.json b/tests/auto/declarative/qdeclarativemoduleplugin/empty.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/tests/auto/declarative/qdeclarativemoduleplugin/empty.json @@ -0,0 +1 @@ +{} diff --git a/tests/auto/declarative/qdeclarativemoduleplugin/plugin.2.1/plugin.cpp b/tests/auto/declarative/qdeclarativemoduleplugin/plugin.2.1/plugin.cpp index 27e0beb4be..a8a0f69a3a 100644 --- a/tests/auto/declarative/qdeclarativemoduleplugin/plugin.2.1/plugin.cpp +++ b/tests/auto/declarative/qdeclarativemoduleplugin/plugin.2.1/plugin.cpp @@ -66,6 +66,8 @@ private: class MyPlugin : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "../empty.json") + public: MyPlugin() { @@ -80,5 +82,3 @@ public: }; #include "plugin.moc" - -Q_EXPORT_PLUGIN2(plugin, MyPlugin); diff --git a/tests/auto/declarative/qdeclarativemoduleplugin/plugin.2/plugin.cpp b/tests/auto/declarative/qdeclarativemoduleplugin/plugin.2/plugin.cpp index 904664ee0e..c67b5b1b63 100644 --- a/tests/auto/declarative/qdeclarativemoduleplugin/plugin.2/plugin.cpp +++ b/tests/auto/declarative/qdeclarativemoduleplugin/plugin.2/plugin.cpp @@ -66,6 +66,8 @@ private: class MyPlugin : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "../empty.json") + public: MyPlugin() { @@ -80,5 +82,3 @@ public: }; #include "plugin.moc" - -Q_EXPORT_PLUGIN2(plugin, MyPlugin); diff --git a/tests/auto/declarative/qdeclarativemoduleplugin/plugin/plugin.cpp b/tests/auto/declarative/qdeclarativemoduleplugin/plugin/plugin.cpp index 267535dd74..869630bd63 100644 --- a/tests/auto/declarative/qdeclarativemoduleplugin/plugin/plugin.cpp +++ b/tests/auto/declarative/qdeclarativemoduleplugin/plugin/plugin.cpp @@ -65,6 +65,8 @@ private: class MyPlugin : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "../empty.json") + public: MyPlugin() { @@ -79,5 +81,3 @@ public: }; #include "plugin.moc" - -Q_EXPORT_PLUGIN2(plugin, MyPlugin); diff --git a/tests/auto/declarative/qdeclarativemoduleplugin/pluginMixed/plugin.cpp b/tests/auto/declarative/qdeclarativemoduleplugin/pluginMixed/plugin.cpp index 0052c6ee53..51e48781f6 100644 --- a/tests/auto/declarative/qdeclarativemoduleplugin/pluginMixed/plugin.cpp +++ b/tests/auto/declarative/qdeclarativemoduleplugin/pluginMixed/plugin.cpp @@ -56,6 +56,8 @@ public: class MyMixedPlugin : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "../empty.json") + public: MyMixedPlugin() { @@ -69,5 +71,3 @@ public: }; #include "plugin.moc" - -Q_EXPORT_PLUGIN2(plugin, MyMixedPlugin); diff --git a/tests/auto/declarative/qdeclarativemoduleplugin/pluginVersion/plugin.cpp b/tests/auto/declarative/qdeclarativemoduleplugin/pluginVersion/plugin.cpp index 6fc6eee1c7..ab8b3d479e 100644 --- a/tests/auto/declarative/qdeclarativemoduleplugin/pluginVersion/plugin.cpp +++ b/tests/auto/declarative/qdeclarativemoduleplugin/pluginVersion/plugin.cpp @@ -56,6 +56,8 @@ public: class MyMixedPlugin : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "../empty.json") + public: MyMixedPlugin() { @@ -69,5 +71,3 @@ public: }; #include "plugin.moc" - -Q_EXPORT_PLUGIN2(plugin, MyMixedPlugin); diff --git a/tests/auto/declarative/qdeclarativemoduleplugin/pluginWithQmlFile/plugin.cpp b/tests/auto/declarative/qdeclarativemoduleplugin/pluginWithQmlFile/plugin.cpp index 7cb0365abe..88b807e14d 100644 --- a/tests/auto/declarative/qdeclarativemoduleplugin/pluginWithQmlFile/plugin.cpp +++ b/tests/auto/declarative/qdeclarativemoduleplugin/pluginWithQmlFile/plugin.cpp @@ -46,6 +46,8 @@ class MyPlugin : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "../empty.json") + public: void registerTypes(const char *uri) { @@ -54,5 +56,3 @@ public: }; #include "plugin.moc" - -Q_EXPORT_PLUGIN2(plugin, MyPlugin); diff --git a/tests/auto/declarative/qdeclarativemoduleplugin/pluginWrongCase/plugin.cpp b/tests/auto/declarative/qdeclarativemoduleplugin/pluginWrongCase/plugin.cpp index 2446c93bf9..fe110a28d4 100644 --- a/tests/auto/declarative/qdeclarativemoduleplugin/pluginWrongCase/plugin.cpp +++ b/tests/auto/declarative/qdeclarativemoduleplugin/pluginWrongCase/plugin.cpp @@ -65,6 +65,8 @@ private: class MyPlugin : public QDeclarativeExtensionPlugin { Q_OBJECT + Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "../empty.json") + public: MyPlugin() { @@ -79,5 +81,3 @@ public: }; #include "plugin.moc" - -Q_EXPORT_PLUGIN2(plugin, MyPlugin); |