summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorMilian Wolff <milian.wolff@kdab.com>2013-12-11 15:54:33 +0100
committerMilian Wolff <milian.wolff@kdab.com>2013-12-12 13:41:18 +0100
commitfb587a3a996d2e9d2fca34cc053df29f6d23f64e (patch)
tree52020dfe8ad740c5a68a402b0cd37fbd1f43f660 /examples
parentacf7f0b1ae956f2fac7182c194e0441cd9c6f4d0 (diff)
downloadqtwebchannel-fb587a3a996d2e9d2fca34cc053df29f6d23f64e.tar.gz
Restructure sources and assimilate to Qt module structure.
This module can hopefully be done in time for 5.3. This commit changes the source structure and QMake files to adapt to typical Qt modules. With this in place, we can now use QT += webchannel in qmake files to link against the pure Qt/C++ QtWebChannel library. The QML plugin is separated from it and can be loaded optionally, if the quick module could be found. Also added is now a qmlplugindump for tooling integration. Note that the Qt.labs namespace is removed. The test file structure is also adapted to how its done in the QtDeclarative module. Note that this setup apparently does not support to run tests without running make install first. Change-Id: I1c15d72e7ab5f525d5a6f651f4e965ef86bc17bd Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'examples')
-rw-r--r--examples/examples.pro8
-rw-r--r--examples/hybridshell/main.qml3
-rw-r--r--examples/qmlapp/qmlapp.qml2
-rw-r--r--examples/qtobject/main.qml3
4 files changed, 8 insertions, 8 deletions
diff --git a/examples/examples.pro b/examples/examples.pro
index 532c07e..decf465 100644
--- a/examples/examples.pro
+++ b/examples/examples.pro
@@ -1,5 +1,7 @@
TEMPLATE = subdirs
-SUBDIRS = \
- hybridshell \
- qtobject
+qtHaveModule(quick) {
+ SUBDIRS += \
+ hybridshell \
+ qtobject
+}
diff --git a/examples/hybridshell/main.qml b/examples/hybridshell/main.qml
index d6d598d..0dedb74 100644
--- a/examples/hybridshell/main.qml
+++ b/examples/hybridshell/main.qml
@@ -41,8 +41,7 @@
import QtQuick 2.0
-import Qt.labs 1.0
-import Qt.labs.WebChannel 1.0
+import QtWebChannel 1.0
import QtWebKit 3.0
import QtWebKit.experimental 1.0
diff --git a/examples/qmlapp/qmlapp.qml b/examples/qmlapp/qmlapp.qml
index 6599bf1..35bce57 100644
--- a/examples/qmlapp/qmlapp.qml
+++ b/examples/qmlapp/qmlapp.qml
@@ -41,7 +41,7 @@
import QtQuick 2.0
-import Qt.labs.WebChannel 1.0
+import QtWebChannel 1.0
import QtWebKit 3.0
import QtWebKit.experimental 1.0
diff --git a/examples/qtobject/main.qml b/examples/qtobject/main.qml
index bb67663..6dd82fa 100644
--- a/examples/qtobject/main.qml
+++ b/examples/qtobject/main.qml
@@ -41,8 +41,7 @@
import QtQuick 2.0
-import Qt.labs 1.0
-import Qt.labs.WebChannel 1.0
+import QtWebChannel 1.0
import QtWebKit 3.0
import QtWebKit.experimental 1.0