Port to Qt5
authorRusty Lynch <rusty.lynch@intel.com>
Tue, 12 Jun 2012 20:40:11 +0000 (13:40 -0700)
committerRusty Lynch <rusty.lynch@intel.com>
Tue, 12 Jun 2012 20:40:11 +0000 (13:40 -0700)
declarative/components.cpp
declarative/components.h
declarative/declarative.pro

index 57df6d4..0d74aea 100644 (file)
@@ -19,10 +19,8 @@ void Components::registerTypes(const char *uri)
     qmlRegisterType<BluetoothDevicesModel>(uri,0,0,"BluetoothDevicesModel");
 }
 
-void Components::initializeEngine(QDeclarativeEngine *engine, const char *uri)
+void Components::initializeEngine(QQmlEngine *engine, const char *uri)
 {
     Q_UNUSED(uri);
     Q_UNUSED(engine);
 }
-
-Q_EXPORT_PLUGIN(Components);
index 5e3813b..edf6434 100644 (file)
@@ -9,16 +9,17 @@
 #ifndef COMPONENTS_H
 #define COMPONENTS_H
 
-#include <QtDeclarative/qdeclarative.h>
-#include <QtDeclarative/QDeclarativeExtensionPlugin>
+#include <Qt/QtQml>
+#include <QtQml/QQmlEngine>
+#include <QtQml/QQmlExtensionPlugin>
 
-class Components : public QDeclarativeExtensionPlugin
+class Components : public QQmlExtensionPlugin
 {
     Q_OBJECT
 
 public:
     void registerTypes(const char *uri);
-    void initializeEngine(QDeclarativeEngine *engine, const char *uri);
+    void initializeEngine(QQmlEngine *engine, const char *uri);
 };
 
 #endif // COMPONENTS_H
index c9c2a63..d2dc887 100644 (file)
@@ -1,5 +1,5 @@
 TEMPLATE = lib
-QT += declarative dbus
+QT += qml dbus
 
 CONFIG += qt \
     plugin \