diff options
Diffstat (limited to 'src/plugins/qmlmodules/multimedia/multimedia.cpp')
-rw-r--r-- | src/plugins/qmlmodules/multimedia/multimedia.cpp | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/src/plugins/qmlmodules/multimedia/multimedia.cpp b/src/plugins/qmlmodules/multimedia/multimedia.cpp index d9414ee..0ebdfd9 100644 --- a/src/plugins/qmlmodules/multimedia/multimedia.cpp +++ b/src/plugins/qmlmodules/multimedia/multimedia.cpp @@ -39,27 +39,19 @@ ** ****************************************************************************/ -#include <QtDeclarative/qmlmoduleplugin.h> +#include <QtDeclarative/qmlextensionplugin.h> #include <QtDeclarative/qml.h> #include <QtMultimedia/qml.h> QT_BEGIN_NAMESPACE -class QMultimediaQmlModule : public QmlModulePlugin +class QMultimediaQmlModule : public QmlExtensionPlugin { Q_OBJECT public: - QStringList keys() const + virtual void initialize(QmlEngine *engine, const char *uri) { - return QStringList() << QLatin1String("Qt.multimedia"); - } - - void defineModule(const QString& uri) - { - Q_UNUSED(uri) - Q_ASSERT(uri == QLatin1String("Qt.multimedia")); - - QtMultimedia::qRegisterQmlElements(); + QtMultimedia::qRegisterQmlElements(engine, uri); } }; |