summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@nokia.com>2012-02-23 12:08:07 +0100
committerQt by Nokia <qt-info@nokia.com>2012-02-28 08:35:02 +0100
commitafebb988c090d7a941af2ac97b3d23b364b878fc (patch)
treec928fdd9ba01fc1a5eb45f1e5a2d26a49893ab56 /examples
parentdbf1c74bf24eb399e1281be795cf56659adc3308 (diff)
Use new plugin system in QtQuick1 examples/demos.
Change-Id: I76f930c32688d596aa58e28eb1d46e1ddeb57b4b Reviewed-by: Matthew Vogt <matthew.vogt@nokia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Diffstat (limited to 'examples')
-rw-r--r--examples/tutorials/gettingStarted/gsQml/filedialog/dialogPlugin.cpp3
-rw-r--r--examples/tutorials/gettingStarted/gsQml/filedialog/dialogPlugin.h1
-rw-r--r--examples/tutorials/gettingStarted/gsQml/filedialog/filedialog.json1
-rw-r--r--examples/tutorials/gettingStarted/gsQml/filedialog/filedialog.pro2
-rw-r--r--examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/dialogPlugin.cpp3
-rw-r--r--examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/dialogPlugin.h3
-rw-r--r--examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/filedialog.json1
-rw-r--r--examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/filedialog.pro2
8 files changed, 7 insertions, 9 deletions
diff --git a/examples/tutorials/gettingStarted/gsQml/filedialog/dialogPlugin.cpp b/examples/tutorials/gettingStarted/gsQml/filedialog/dialogPlugin.cpp
index 0630cb1a..4bb8c230 100644
--- a/examples/tutorials/gettingStarted/gsQml/filedialog/dialogPlugin.cpp
+++ b/examples/tutorials/gettingStarted/gsQml/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);
diff --git a/examples/tutorials/gettingStarted/gsQml/filedialog/dialogPlugin.h b/examples/tutorials/gettingStarted/gsQml/filedialog/dialogPlugin.h
index d7f5cd33..cb78367e 100644
--- a/examples/tutorials/gettingStarted/gsQml/filedialog/dialogPlugin.h
+++ b/examples/tutorials/gettingStarted/gsQml/filedialog/dialogPlugin.h
@@ -46,6 +46,7 @@
class DialogPlugin : public QDeclarativeExtensionPlugin
{
Q_OBJECT
+ Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "filedialog.json")
public:
//registerTypes is inherited from QDeclarativeExtensionPlugin
diff --git a/examples/tutorials/gettingStarted/gsQml/filedialog/filedialog.json b/examples/tutorials/gettingStarted/gsQml/filedialog/filedialog.json
new file mode 100644
index 00000000..0967ef42
--- /dev/null
+++ b/examples/tutorials/gettingStarted/gsQml/filedialog/filedialog.json
@@ -0,0 +1 @@
+{}
diff --git a/examples/tutorials/gettingStarted/gsQml/filedialog/filedialog.pro b/examples/tutorials/gettingStarted/gsQml/filedialog/filedialog.pro
index d85787d0..33eb51d4 100644
--- a/examples/tutorials/gettingStarted/gsQml/filedialog/filedialog.pro
+++ b/examples/tutorials/gettingStarted/gsQml/filedialog/filedialog.pro
@@ -1,6 +1,6 @@
TEMPLATE = lib
CONFIG += qt plugin
-QT += declarative
+QT += quick1
DESTDIR += ../plugins
OBJECTS_DIR = tmp
diff --git a/examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/dialogPlugin.cpp b/examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/dialogPlugin.cpp
index de84d9c4..290bd292 100644
--- a/examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/dialogPlugin.cpp
+++ b/examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/dialogPlugin.cpp
@@ -52,6 +52,3 @@ void DialogPlugin::registerTypes(const char *uri){
//qRegisterMetaType<QDeclarativeListProperty<QString> > ("QDeclarativeListProperty<QString>");
}
-
-//FileDialog is the plugin name (same as the TARGET in the project file) and DialogPlugin is the plugin classs
-Q_EXPORT_PLUGIN2(FileDialog, DialogPlugin);
diff --git a/examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/dialogPlugin.h b/examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/dialogPlugin.h
index cdcf59e5..232518fa 100644
--- a/examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/dialogPlugin.h
+++ b/examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/dialogPlugin.h
@@ -46,7 +46,8 @@
class DialogPlugin : public QDeclarativeExtensionPlugin
{
Q_OBJECT
-
+ Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QDeclarativeExtensionInterface" FILE "filedialog.json")
+
public:
//registerTypes is inherited from QDeclarativeExtensionPlugin
void registerTypes(const char *uri);
diff --git a/examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/filedialog.json b/examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/filedialog.json
new file mode 100644
index 00000000..0967ef42
--- /dev/null
+++ b/examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/filedialog.json
@@ -0,0 +1 @@
+{}
diff --git a/examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/filedialog.pro b/examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/filedialog.pro
index 62477470..9b1cfa11 100644
--- a/examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/filedialog.pro
+++ b/examples/tutorials/gettingStarted/gsQml/parts/part5/filedialog/filedialog.pro
@@ -1,6 +1,6 @@
TEMPLATE = lib
CONFIG += qt plugin
-QT += declarative
+QT += quick1
DESTDIR += ../plugins
OBJECTS_DIR = tmp