diff options
author | Johanna Aijala <johanna.aijala@digia.com> | 2013-02-21 09:57:24 +0200 |
---|---|---|
committer | Johanna Aijala <johanna.aijala@digia.com> | 2013-02-21 09:58:20 +0200 |
commit | 8107c1ae8733cd38657d7023c03dc0906ac44d33 (patch) | |
tree | cf9983e57a4186bc60977c6bd3a734cb1b871439 | |
parent | 276c53531a95ce3f1f00c5c445e19584ac077917 (diff) | |
parent | ee74b8c84b9f435ede3bf81d1de4508dad088546 (diff) | |
download | qtwebkit-examples-8107c1ae8733cd38657d7023c03dc0906ac44d33.tar.gz |
Merge branch 'stable' into release
Change-Id: I7860ca6ccaafa79ca192847ae82b3c2167b53aa0
-rw-r--r-- | doc/qtwebkitexamples.qdocconf | 12 | ||||
-rw-r--r-- | examples/webkitqml/flickrview/flickrview.pro | 7 | ||||
-rw-r--r-- | examples/webkitqml/flickrview/flickrview.qml | 10 | ||||
-rw-r--r-- | examples/webkitqml/flickrview/flickrview.qrc | 6 | ||||
-rw-r--r-- | examples/webkitqml/flickrview/images/flickr.png (renamed from examples/webkitqml/shared/images/flickr.png) | bin | 6818 -> 6818 bytes | |||
-rw-r--r-- | examples/webkitqml/shared/LoadIndicator.qml | 2 | ||||
-rw-r--r-- | examples/webkitqml/shared/main.cpp | 4 | ||||
-rw-r--r-- | examples/webkitqml/shared/shared.qrc | 10 | ||||
-rw-r--r-- | examples/webkitqml/youtubeview/content/YouTubeDialog.qml | 4 | ||||
-rw-r--r-- | examples/webkitqml/youtubeview/youtubeview.pro | 3 | ||||
-rw-r--r-- | examples/webkitqml/youtubeview/youtubeview.qml | 16 | ||||
-rw-r--r-- | examples/webkitqml/youtubeview/youtubeview.qrc | 7 |
12 files changed, 54 insertions, 27 deletions
diff --git a/doc/qtwebkitexamples.qdocconf b/doc/qtwebkitexamples.qdocconf index 138cfab..e0228ba 100644 --- a/doc/qtwebkitexamples.qdocconf +++ b/doc/qtwebkitexamples.qdocconf @@ -2,8 +2,8 @@ include($QT_INSTALL_DOCS/global/qt-module-defaults.qdocconf) project = QtWebKitExamples description = "Qt WebKit Examples and Demos Documentation" -url = http://qt-project.org/doc/qt-5.0/qtwebkitexamples -version = 5.0.1 +url = http://qt-project.org/doc/qt-$QT_VER/qtwebkitexamples +version = $QT_VERSION # Defines the name of the project. You cannot use operators (+, =, -) in # the name. Properties for this project are set using a qhp.<projectname>.property @@ -12,13 +12,13 @@ version = 5.0.1 qhp.projects = QtWebKitExamples qhp.QtWebKitExamples.file = qtwebkitexamples.qhp -qhp.QtWebKitExamples.namespace = org.qt-project.qtwebkitexamples.501 +qhp.QtWebKitExamples.namespace = org.qt-project.qtwebkitexamples.$QT_VERSION_TAG qhp.QtWebKitExamples.indexTitle = Qt WebKit Examples qhp.QtWebKitExamples.virtualFolder = qtwebkitexamples qhp.QtWebKitExamples.indexRoot = -qhp.QtWebKitExamples.filterAttributes = qtwebkitexamples 5.0.1 qtrefdoc -qhp.QtWebKitExamples.customFilters.Qt.name = QtWebKit 5.0.1 -qhp.QtWebKitExamples.customFilters.Qt.filterAttributes = qtwebkitexamples 5.0.1 +qhp.QtWebKitExamples.filterAttributes = qtwebkitexamples $QT_VERSION qtrefdoc +qhp.QtWebKitExamples.customFilters.Qt.name = QtWebKit $QT_VERSION +qhp.QtWebKitExamples.customFilters.Qt.filterAttributes = qtwebkitexamples $QT_VERSION qhp.QtWebKitExamples.subprojects = manual qhp.QtWebKitExamples.subprojects.manual.title = Qt WebKit Examples diff --git a/examples/webkitqml/flickrview/flickrview.pro b/examples/webkitqml/flickrview/flickrview.pro index 33d9320..bc88cff 100644 --- a/examples/webkitqml/flickrview/flickrview.pro +++ b/examples/webkitqml/flickrview/flickrview.pro @@ -7,7 +7,8 @@ SOURCES += ../shared/main.cpp mac: CONFIG -= app_bundle +RESOURCES += flickrview.qrc \ + ../shared/shared.qrc + target.path = $$[QT_INSTALL_EXAMPLES]/webkitqml/flickrview -qml.files = flickrview.qml -qml.path = $$[QT_INSTALL_EXAMPLES]/webkitqml/flickrview -INSTALLS += target qml +INSTALLS += target diff --git a/examples/webkitqml/flickrview/flickrview.qml b/examples/webkitqml/flickrview/flickrview.qml index e5e3dfd..b303b1b 100644 --- a/examples/webkitqml/flickrview/flickrview.qml +++ b/examples/webkitqml/flickrview/flickrview.qml @@ -41,7 +41,7 @@ import QtQuick 2.0 import QtWebKit 3.0 import QtQuick.XmlListModel 2.0 -import "../shared" +import "qrc:/shared" as Shared Rectangle { id: container @@ -156,7 +156,7 @@ Rectangle { left: parent.left } Image { - source: "../shared/images/arrow.png" + source: "qrc:/shared/images/arrow.png" width: 30 height: 30 visible: updateInfo.state != "update" @@ -189,7 +189,7 @@ Rectangle { } } - LoadIndicator { + Shared.LoadIndicator { anchors.fill: parent color: "black" running: !listView.visible && model.status != XmlListModel.Error @@ -247,9 +247,9 @@ Rectangle { } } - LoadIndicator { + Shared.LoadIndicator { anchors.fill: parent - imageSource: "images/flickr.png" + imageSource: "qrc:/images/flickr.png" running: webView.loading } } diff --git a/examples/webkitqml/flickrview/flickrview.qrc b/examples/webkitqml/flickrview/flickrview.qrc new file mode 100644 index 0000000..35c793c --- /dev/null +++ b/examples/webkitqml/flickrview/flickrview.qrc @@ -0,0 +1,6 @@ +<RCC> + <qresource prefix="/"> + <file>flickrview.qml</file> + <file>images/flickr.png</file> + </qresource> +</RCC> diff --git a/examples/webkitqml/shared/images/flickr.png b/examples/webkitqml/flickrview/images/flickr.png Binary files differindex d0f0502..d0f0502 100644 --- a/examples/webkitqml/shared/images/flickr.png +++ b/examples/webkitqml/flickrview/images/flickr.png diff --git a/examples/webkitqml/shared/LoadIndicator.qml b/examples/webkitqml/shared/LoadIndicator.qml index 6d972e9..d181f15 100644 --- a/examples/webkitqml/shared/LoadIndicator.qml +++ b/examples/webkitqml/shared/LoadIndicator.qml @@ -44,7 +44,7 @@ Rectangle { id: container property bool running: false - property string imageSource: "images/busy.png" + property string imageSource: "qrc:/shared/images/busy.png" visible: running diff --git a/examples/webkitqml/shared/main.cpp b/examples/webkitqml/shared/main.cpp index c77a22b..ac1de3e 100644 --- a/examples/webkitqml/shared/main.cpp +++ b/examples/webkitqml/shared/main.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies). ** Contact: http://www.qt-project.org/legal ** ** This file is part of the examples of the Qt Toolkit. @@ -43,7 +43,7 @@ int main(int argc, char* argv[]) { QGuiApplication app(argc,argv); QQuickView view; - view.setSource(QUrl::fromLocalFile(QCoreApplication::applicationDirPath() + QLatin1String("/" QWEBKIT_EXAMPLE_NAME ".qml"))); + view.setSource(QUrl("qrc:///"QWEBKIT_EXAMPLE_NAME".qml")); view.setResizeMode(QQuickView::SizeRootObjectToView); view.show(); return app.exec(); diff --git a/examples/webkitqml/shared/shared.qrc b/examples/webkitqml/shared/shared.qrc new file mode 100644 index 0000000..9aa4172 --- /dev/null +++ b/examples/webkitqml/shared/shared.qrc @@ -0,0 +1,10 @@ +<RCC> + <qresource prefix="/shared"> + <file>images/arrow.png</file> + <file>images/busy.png</file> + <file>images/less.png</file> + <file>images/more.png</file> + <file>Button.qml</file> + <file>LoadIndicator.qml</file> + </qresource> +</RCC> diff --git a/examples/webkitqml/youtubeview/content/YouTubeDialog.qml b/examples/webkitqml/youtubeview/content/YouTubeDialog.qml index b02400e..21bdc40 100644 --- a/examples/webkitqml/youtubeview/content/YouTubeDialog.qml +++ b/examples/webkitqml/youtubeview/content/YouTubeDialog.qml @@ -39,7 +39,7 @@ ****************************************************************************/ import QtQuick 2.0 -import "../../shared" +import "qrc:/shared" as Shared Rectangle { id: container @@ -77,7 +77,7 @@ Rectangle { Component { id: delegate - Button { + Shared.Button { buttonWidth: 200 text: name onClicked: presetClicked(name) diff --git a/examples/webkitqml/youtubeview/youtubeview.pro b/examples/webkitqml/youtubeview/youtubeview.pro index cdc71e9..b67072f 100644 --- a/examples/webkitqml/youtubeview/youtubeview.pro +++ b/examples/webkitqml/youtubeview/youtubeview.pro @@ -14,3 +14,6 @@ INSTALLS += target qml OTHER_FILES += \ player.html + +RESOURCES += youtubeview.qrc \ + ../shared/shared.qrc diff --git a/examples/webkitqml/youtubeview/youtubeview.qml b/examples/webkitqml/youtubeview/youtubeview.qml index b002319..16873d6 100644 --- a/examples/webkitqml/youtubeview/youtubeview.qml +++ b/examples/webkitqml/youtubeview/youtubeview.qml @@ -41,8 +41,8 @@ import QtQuick 2.0 import QtWebKit 3.0 import QtQuick.XmlListModel 2.0 -import "content" -import "../shared" +import "qrc:/shared" as Shared +import "qrc:/content" as Content Rectangle { id: container @@ -77,7 +77,7 @@ Rectangle { anchors.fill: parent opacity: 0 - url: "content/player.html?" + currentVideo.vId + url: "qrc:///content/player.html?" + currentVideo.vId Behavior on opacity { NumberAnimation { duration: 200 } } @@ -105,7 +105,7 @@ Rectangle { } } - YouTubeDialog { + Content.YouTubeDialog { id: presetDialog anchors.fill: parent visible: false @@ -190,7 +190,7 @@ Rectangle { anchors.verticalCenter: parent.verticalCenter width: height height: visible ? listView.contentItem.height : 0 - Image { anchors.centerIn: parent; width: 50; height: 50; source: "../shared/images/less.png" } + Image { anchors.centerIn: parent; width: 50; height: 50; source: "qrc:/shared/images/less.png" } MouseArea { anchors.fill: parent onClicked: model.requestLess() @@ -205,7 +205,7 @@ Rectangle { anchors.verticalCenter: parent.verticalCenter width: height height: visible ? listView.contentItem.height : 0 - Image { anchors.centerIn: parent; width: 50; height: 50; source: "../shared/images/more.png" } + Image { anchors.centerIn: parent; width: 50; height: 50; source: "qrc:/shared/images/more.png" } MouseArea { anchors.fill: parent onClicked: model.requestMore() @@ -240,7 +240,7 @@ Rectangle { } } - LoadIndicator { + Shared.LoadIndicator { anchors.fill: parent color: "black" running: panel.state == "list" && model.status != XmlListModel.Ready @@ -308,7 +308,7 @@ Rectangle { } } - Button { + Shared.Button { id: button buttonHeight: container.padding buttonWidth: container.width diff --git a/examples/webkitqml/youtubeview/youtubeview.qrc b/examples/webkitqml/youtubeview/youtubeview.qrc new file mode 100644 index 0000000..1440b31 --- /dev/null +++ b/examples/webkitqml/youtubeview/youtubeview.qrc @@ -0,0 +1,7 @@ +<RCC> + <qresource prefix="/"> + <file>content/YouTubeDialog.qml</file> + <file>content/player.html</file> + <file>youtubeview.qml</file> + </qresource> +</RCC> |