Use resource files for most examples
authorKai Koehne <kai.koehne@digia.com>
Tue, 11 Dec 2012 13:17:34 +0000 (14:17 +0100)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Wed, 12 Dec 2012 09:32:50 +0000 (10:32 +0100)
Make examples shadow-build-friendly by using resource
files instead of trying to derive the qml path from
applicationDirPath().

Change-Id: I669424554c772d9b261249b366247190f5fbd8b1
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
99 files changed:
examples/qml/xmlhttprequest/main.cpp
examples/qml/xmlhttprequest/xmlhttprequest.pro
examples/qml/xmlhttprequest/xmlhttprequest.qrc [new file with mode: 0644]
examples/quick/accessibility/accessibility.pro
examples/quick/accessibility/accessibility.qrc [new file with mode: 0644]
examples/quick/accessibility/main.cpp
examples/quick/animation/animation.pro
examples/quick/animation/animation.qrc [new file with mode: 0644]
examples/quick/animation/main.cpp
examples/quick/canvas/canvas.pro
examples/quick/canvas/canvas.qrc [new file with mode: 0644]
examples/quick/canvas/main.cpp
examples/quick/customitems/maskedmousearea/main.cpp
examples/quick/customitems/maskedmousearea/maskedmousearea.pro
examples/quick/customitems/maskedmousearea/maskedmousearea.qrc [new file with mode: 0644]
examples/quick/customitems/painteditem/painteditem.pro
examples/quick/customitems/painteditem/painteditem.qrc [new file with mode: 0644]
examples/quick/demos/calqlatr/calqlatr.pro
examples/quick/demos/calqlatr/calqlatr.qrc [new file with mode: 0644]
examples/quick/demos/calqlatr/main.cpp
examples/quick/demos/maroon/main.cpp
examples/quick/demos/maroon/maroon.pro
examples/quick/demos/maroon/maroon.qrc [new file with mode: 0644]
examples/quick/demos/samegame/main.cpp
examples/quick/demos/samegame/samegame.pro
examples/quick/demos/samegame/samegame.qrc [new file with mode: 0644]
examples/quick/demos/stocqt/main.cpp
examples/quick/demos/stocqt/stocqt.pro
examples/quick/demos/stocqt/stocqt.qrc [new file with mode: 0644]
examples/quick/demos/tweetsearch/main.cpp
examples/quick/demos/tweetsearch/tweetsearch.pro
examples/quick/demos/tweetsearch/tweetsearch.qrc [new file with mode: 0644]
examples/quick/draganddrop/draganddrop.pro
examples/quick/draganddrop/draganddrop.qrc [new file with mode: 0644]
examples/quick/draganddrop/main.cpp
examples/quick/imageelements/imageelements.pro
examples/quick/imageelements/imageelements.qrc [new file with mode: 0644]
examples/quick/imageelements/main.cpp
examples/quick/keyinteraction/keyinteraction.pro
examples/quick/keyinteraction/keyinteraction.qrc [new file with mode: 0644]
examples/quick/keyinteraction/main.cpp
examples/quick/localstorage/localstorage/localstorage.pro
examples/quick/localstorage/localstorage/localstorage.qrc [new file with mode: 0644]
examples/quick/localstorage/localstorage/main.cpp
examples/quick/mousearea/main.cpp
examples/quick/mousearea/mousearea.pro
examples/quick/mousearea/mousearea.qrc [new file with mode: 0644]
examples/quick/particles/affectors/affectors.pro
examples/quick/particles/affectors/affectors.qrc [new file with mode: 0644]
examples/quick/particles/affectors/main.cpp
examples/quick/particles/customparticle/customparticle.pro
examples/quick/particles/customparticle/customparticle.qrc [new file with mode: 0644]
examples/quick/particles/customparticle/main.cpp
examples/quick/particles/emitters/emitters.pro
examples/quick/particles/emitters/emitters.qrc [new file with mode: 0644]
examples/quick/particles/emitters/main.cpp
examples/quick/particles/imageparticle/imageparticle.pro
examples/quick/particles/imageparticle/imageparticle.qrc [new file with mode: 0644]
examples/quick/particles/imageparticle/main.cpp
examples/quick/particles/images.qrc [new file with mode: 0644]
examples/quick/particles/system/main.cpp
examples/quick/particles/system/system.pro
examples/quick/particles/system/system.qrc [new file with mode: 0644]
examples/quick/positioners/main.cpp
examples/quick/positioners/positioners.pro
examples/quick/positioners/positioners.qrc [new file with mode: 0644]
examples/quick/righttoleft/main.cpp
examples/quick/righttoleft/righttoleft.pro
examples/quick/righttoleft/righttoleft.qrc [new file with mode: 0644]
examples/quick/scenegraph/customgeometry/customgeometry.pro
examples/quick/scenegraph/customgeometry/customgeometry.qrc [new file with mode: 0644]
examples/quick/scenegraph/customgeometry/main.cpp
examples/quick/scenegraph/openglunderqml/main.cpp
examples/quick/scenegraph/openglunderqml/openglunderqml.pro
examples/quick/scenegraph/openglunderqml/openglunderqml.qrc [new file with mode: 0644]
examples/quick/scenegraph/simplematerial/simplematerial.cpp
examples/quick/scenegraph/simplematerial/simplematerial.pro
examples/quick/scenegraph/simplematerial/simplematerial.qrc [new file with mode: 0644]
examples/quick/shadereffects/main.cpp
examples/quick/shadereffects/shadereffects.pro
examples/quick/shadereffects/shadereffects.qrc [new file with mode: 0644]
examples/quick/shared/quick_shared.qrc [new file with mode: 0644]
examples/quick/shared/shared.h
examples/quick/shared/shared.qrc [new file with mode: 0644]
examples/quick/text/main.cpp
examples/quick/text/text.pro
examples/quick/text/text.qrc [new file with mode: 0644]
examples/quick/threading/main.cpp
examples/quick/threading/threading.pro
examples/quick/threading/threading.qrc [new file with mode: 0644]
examples/quick/touchinteraction/main.cpp
examples/quick/touchinteraction/touchinteraction.pro
examples/quick/touchinteraction/touchinteraction.qrc [new file with mode: 0644]
examples/quick/views/main.cpp
examples/quick/views/views.pro
examples/quick/views/views.qrc [new file with mode: 0644]
examples/quick/window/window/window.cpp
examples/quick/window/window/window.pro
examples/quick/window/window/window.qrc [new file with mode: 0644]

index 25f3759..8bf39fc 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../../quick/shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(xmlhttprequest)
+DECLARATIVE_EXAMPLE_MAIN(qml/xmlhttprequest/xmlhttprequest)
index 5af32ee..3e20d37 100644 (file)
@@ -2,11 +2,12 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    xmlhttprequest.qrc \
+    ../../quick/shared/quick_shared.qrc
 
 EXAMPLE_FILES = \
     data.xml
 
 target.path = $$[QT_INSTALL_EXAMPLES]/qml/xmlhttprequest
-qml.files = xmlhttprequest.qml get.qml
-qml.path = $$[QT_INSTALL_EXAMPLES]/qml/xmlhttprequest
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/qml/xmlhttprequest/xmlhttprequest.qrc b/examples/qml/xmlhttprequest/xmlhttprequest.qrc
new file mode 100644 (file)
index 0000000..532e508
--- /dev/null
@@ -0,0 +1,7 @@
+<RCC>
+    <qresource prefix="/qml/xmlhttprequest">
+        <file>xmlhttprequest.qml</file>
+        <file>get.qml</file>
+        <file>data.xml</file>
+    </qresource>
+</RCC>
index 9658a8e..3f4ea64 100644 (file)
@@ -2,8 +2,7 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += accessibility.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/accessibility
-qml.files = accessibility.qml content
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/accessibility
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/accessibility/accessibility.qrc b/examples/quick/accessibility/accessibility.qrc
new file mode 100644 (file)
index 0000000..462a9a5
--- /dev/null
@@ -0,0 +1,8 @@
+<RCC>
+    <qresource prefix="/accessibility">
+        <file>accessibility.qml</file>
+        <file>content/Button.qml</file>
+        <file>content/Checkbox.qml</file>
+        <file>content/Slider.qml</file>
+    </qresource>
+</RCC>
index 51374d0..07b2e71 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(accessibility)
+DECLARATIVE_EXAMPLE_MAIN(accessibility/accessibility)
index 58e9226..70d7168 100644 (file)
@@ -3,8 +3,9 @@ TEMPLATE = app
 QT += quick qml
 SOURCES += main.cpp
 
-target.path = $$[QT_INSTALL_EXAMPLES]/quick/animation
-qml.files = animation.qml  basics  behaviors  easing pathanimation  pathinterpolator  states
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/animation
-INSTALLS += target qml
+RESOURCES += \
+    ../shared/shared.qrc \
+    animation.qrc
 
+target.path = $$[QT_INSTALL_EXAMPLES]/quick/animation
+INSTALLS += target
diff --git a/examples/quick/animation/animation.qrc b/examples/quick/animation/animation.qrc
new file mode 100644 (file)
index 0000000..d1217ac
--- /dev/null
@@ -0,0 +1,22 @@
+<RCC>
+    <qresource prefix="/animation">
+        <file>animation.qml</file>
+        <file>basics/images/face-smile.png</file>
+        <file>basics/images/moon.png</file>
+        <file>basics/images/shadow.png</file>
+        <file>basics/images/star.png</file>
+        <file>basics/images/sun.png</file>
+        <file>basics/color-animation.qml</file>
+        <file>basics/property-animation.qml</file>
+        <file>behaviors/behavior-example.qml</file>
+        <file>behaviors/SideRect.qml</file>
+        <file>behaviors/tvtennis.qml</file>
+        <file>behaviors/wigglytext.qml</file>
+        <file>easing/easing.qml</file>
+        <file>pathanimation/pathanimation.qml</file>
+        <file>pathinterpolator/pathinterpolator.qml</file>
+        <file>states/qt-logo.png</file>
+        <file>states/states.qml</file>
+        <file>states/transitions.qml</file>
+    </qresource>
+</RCC>
index dc5b506..28bf080 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(animation)
+DECLARATIVE_EXAMPLE_MAIN(animation/animation)
index d721805..4c41404 100644 (file)
@@ -2,8 +2,9 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    canvas.qrc \
+    ../shared/shared.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/canvas
-qml.files = canvas.qml bezierCurve clip quadraticCurveTo roundedrect smile squircle tiger contents
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/canvas
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/canvas/canvas.qrc b/examples/quick/canvas/canvas.qrc
new file mode 100644 (file)
index 0000000..06d39f3
--- /dev/null
@@ -0,0 +1,32 @@
+<RCC>
+    <qresource prefix="/canvas">
+        <file>canvas.qml</file>
+        <file>bezierCurve/bezierCurve.qml</file>
+        <file>clip/clip.qml</file>
+        <file>contents/Button.qml</file>
+        <file>contents/qt-logo.png</file>
+        <file>contents/ScrollBar.qml</file>
+        <file>contents/Slider.qml</file>
+        <file>contents/TitleBar.qml</file>
+        <file>contents/ToolBar.qml</file>
+        <file>contents/images/button-pressed.png</file>
+        <file>contents/images/button.png</file>
+        <file>contents/images/default.svg</file>
+        <file>contents/images/gloss.png</file>
+        <file>contents/images/lineedit.png</file>
+        <file>contents/images/lineedit.sci</file>
+        <file>contents/images/quit.png</file>
+        <file>contents/images/stripes.png</file>
+        <file>contents/images/titlebar.png</file>
+        <file>contents/images/titlebar.sci</file>
+        <file>contents/images/toolbutton.png</file>
+        <file>contents/images/toolbutton.sci</file>
+        <file>quadraticCurveTo/quadraticCurveTo.qml</file>
+        <file>roundedrect/roundedrect.qml</file>
+        <file>smile/smile.qml</file>
+        <file>squircle/squircle.png</file>
+        <file>squircle/squircle.qml</file>
+        <file>tiger/tiger.js</file>
+        <file>tiger/tiger.qml</file>
+    </qresource>
+</RCC>
index 52c62ac..9b2fda1 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(canvas)
\ No newline at end of file
+DECLARATIVE_EXAMPLE_MAIN(canvas/canvas)
index a0ca0b6..a0235fc 100644 (file)
@@ -51,7 +51,7 @@ int main(int argc, char* argv[])
 
     qmlRegisterType<MaskedMouseArea>("Example", 1, 0, "MaskedMouseArea");
 
-    view.setSource(QUrl::fromLocalFile("maskedmousearea.qml"));
+    view.setSource(QUrl("qrc:///customitems/maskedmousearea/maskedmousearea.qml"));
     view.show();
     return app.exec();
 }
index d44fa59..fe5c05c 100644 (file)
@@ -7,7 +7,7 @@ HEADERS += maskedmousearea.h
 SOURCES += main.cpp \
            maskedmousearea.cpp
 
+RESOURCES += maskedmousearea.qrc
+
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/customitems/maskedmousearea
-qml.files = maskedmousearea.qml images
-qml.path = $$target.path
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/customitems/maskedmousearea/maskedmousearea.qrc b/examples/quick/customitems/maskedmousearea/maskedmousearea.qrc
new file mode 100644 (file)
index 0000000..3cc3955
--- /dev/null
@@ -0,0 +1,8 @@
+<RCC>
+    <qresource prefix="/customitems/maskedmousearea">
+        <file>maskedmousearea.qml</file>
+        <file>images/cloud_1.png</file>
+        <file>images/cloud_2.png</file>
+        <file>images/moon.png</file>
+    </qresource>
+</RCC>
index dfe6f96..8f94a0c 100644 (file)
@@ -9,12 +9,12 @@ HEADERS += TextBalloonPlugin/plugin.h \
 
 SOURCES += textballoon.cpp
 
+RESOURCES += painteditem.qrc
+
 DESTDIR = TextBalloonPlugin
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/customitems/painteditem/TextBalloonPlugin
 qmldir.files = TextBalloonPlugin/qmldir
 qmldir.path = $$[QT_INSTALL_EXAMPLES]/quick/customitems/painteditem/TextBalloonPlugin
-qml.files = textballoons.qml
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/customitems/painteditem/
 
-INSTALLS += qml qmldir target
+INSTALLS += qmldir target
diff --git a/examples/quick/customitems/painteditem/painteditem.qrc b/examples/quick/customitems/painteditem/painteditem.qrc
new file mode 100644 (file)
index 0000000..c240be0
--- /dev/null
@@ -0,0 +1,6 @@
+<RCC>
+    <qresource prefix="/painteditem">
+        <file>textballoon.h</file>
+        <file>textballoons.qml</file>
+    </qresource>
+</RCC>
index fec0d64..1b002a5 100644 (file)
@@ -3,7 +3,8 @@ TEMPLATE = app
 QT += qml quick
 SOURCES += main.cpp
 
+RESOURCES += calqlatr.qrc \
+    ../../shared/shared.qrc
+
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/demos/calqlatr
-qml.files = calqlatr.qml content
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/demos/calqlatr
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/demos/calqlatr/calqlatr.qrc b/examples/quick/demos/calqlatr/calqlatr.qrc
new file mode 100644 (file)
index 0000000..fda7d35
--- /dev/null
@@ -0,0 +1,22 @@
+<RCC>
+    <qresource prefix="/demos/calqlatr">
+        <file>calqlatr.qml</file>
+        <file>content/Button.qml</file>
+        <file>content/calculator.js</file>
+        <file>content/Display.qml</file>
+        <file>content/NumberPad.qml</file>
+        <file>content/StyleLabel.qml</file>
+        <file>content/audio/touch.wav</file>
+        <file>content/images/icon-back.png</file>
+        <file>content/images/icon-close.png</file>
+        <file>content/images/icon-settings.png</file>
+        <file>content/images/logo.png</file>
+        <file>content/images/paper-edge-left.png</file>
+        <file>content/images/paper-edge-right.png</file>
+        <file>content/images/paper-grip.png</file>
+        <file>content/images/settings-selected-a.png</file>
+        <file>content/images/settings-selected-b.png</file>
+        <file>content/images/touch-green.png</file>
+        <file>content/images/touch-white.png</file>
+    </qresource>
+</RCC>
index 9000bfc..65bfc97 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(calqlatr)
+DECLARATIVE_EXAMPLE_MAIN(demos/calqlatr/calqlatr)
index da2343e..6866cf8 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(maroon)
+DECLARATIVE_EXAMPLE_MAIN(demos/maroon/maroon)
index e193927..6ca0a2b 100644 (file)
@@ -2,8 +2,7 @@ TEMPLATE = app
 
 QT += qml quick
 SOURCES += main.cpp
+RESOURCES += maroon.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/demos/maroon
-qml.files = maroon.qml content
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/demos/maroon
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/demos/maroon/maroon.qrc b/examples/quick/demos/maroon/maroon.qrc
new file mode 100644 (file)
index 0000000..52c2a4e
--- /dev/null
@@ -0,0 +1,71 @@
+<RCC>
+    <qresource prefix="/demos/maroon">
+        <file>maroon.qml</file>
+        <file>content/BuildButton.qml</file>
+        <file>content/GameCanvas.qml</file>
+        <file>content/GameOverScreen.qml</file>
+        <file>content/InfoBar.qml</file>
+        <file>content/logic.js</file>
+        <file>content/NewGameScreen.qml</file>
+        <file>content/SoundEffect.qml</file>
+        <file>content/audio/bomb-action.wav</file>
+        <file>content/audio/catch-action.wav</file>
+        <file>content/audio/catch.wav</file>
+        <file>content/audio/currency.wav</file>
+        <file>content/audio/factory-action.wav</file>
+        <file>content/audio/melee-action.wav</file>
+        <file>content/audio/projectile-action.wav</file>
+        <file>content/audio/shooter-action.wav</file>
+        <file>content/gfx/background.png</file>
+        <file>content/gfx/bomb-action.png</file>
+        <file>content/gfx/bomb-idle.png</file>
+        <file>content/gfx/bomb.png</file>
+        <file>content/gfx/button-help.png</file>
+        <file>content/gfx/button-play.png</file>
+        <file>content/gfx/catch-action.png</file>
+        <file>content/gfx/catch.png</file>
+        <file>content/gfx/cloud.png</file>
+        <file>content/gfx/currency.png</file>
+        <file>content/gfx/dialog-bomb.png</file>
+        <file>content/gfx/dialog-factory.png</file>
+        <file>content/gfx/dialog-melee.png</file>
+        <file>content/gfx/dialog-pointer.png</file>
+        <file>content/gfx/dialog-shooter.png</file>
+        <file>content/gfx/dialog.png</file>
+        <file>content/gfx/factory-action.png</file>
+        <file>content/gfx/factory-idle.png</file>
+        <file>content/gfx/factory.png</file>
+        <file>content/gfx/grid.png</file>
+        <file>content/gfx/help.png</file>
+        <file>content/gfx/lifes.png</file>
+        <file>content/gfx/logo-bubble.png</file>
+        <file>content/gfx/logo-fish.png</file>
+        <file>content/gfx/logo.png</file>
+        <file>content/gfx/melee-action.png</file>
+        <file>content/gfx/melee-idle.png</file>
+        <file>content/gfx/melee.png</file>
+        <file>content/gfx/mob-idle.png</file>
+        <file>content/gfx/mob.png</file>
+        <file>content/gfx/points.png</file>
+        <file>content/gfx/projectile-action.png</file>
+        <file>content/gfx/projectile.png</file>
+        <file>content/gfx/scores.png</file>
+        <file>content/gfx/shooter-action.png</file>
+        <file>content/gfx/shooter-idle.png</file>
+        <file>content/gfx/shooter.png</file>
+        <file>content/gfx/sunlight.png</file>
+        <file>content/gfx/text-1.png</file>
+        <file>content/gfx/text-2.png</file>
+        <file>content/gfx/text-3.png</file>
+        <file>content/gfx/text-blank.png</file>
+        <file>content/gfx/text-gameover.png</file>
+        <file>content/gfx/text-go.png</file>
+        <file>content/gfx/wave.png</file>
+        <file>content/mobs/MobBase.qml</file>
+        <file>content/towers/Bomb.qml</file>
+        <file>content/towers/Factory.qml</file>
+        <file>content/towers/Melee.qml</file>
+        <file>content/towers/Ranged.qml</file>
+        <file>content/towers/TowerBase.qml</file>
+    </qresource>
+</RCC>
index 20bf7fa..c12804e 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(samegame)
+DECLARATIVE_EXAMPLE_MAIN(demos/samegame/samegame)
index fec2e53..59cacd3 100644 (file)
@@ -2,8 +2,7 @@ TEMPLATE = app
 
 QT += qml quick
 SOURCES += main.cpp
+RESOURCES += samegame.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/demos/samegame
-qml.files = samegame.qml content settings.js
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/demos/samegame
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/demos/samegame/samegame.qrc b/examples/quick/demos/samegame/samegame.qrc
new file mode 100644 (file)
index 0000000..951b9d1
--- /dev/null
@@ -0,0 +1,72 @@
+<RCC>
+    <qresource prefix="/demos/samegame">
+        <file>samegame.qml</file>
+        <file>settings.js</file>
+        <file>content/gfx/text-p1-won.png</file>
+        <file>content/gfx/background-puzzle.png</file>
+        <file>content/gfx/background.png</file>
+        <file>content/gfx/bar.png</file>
+        <file>content/gfx/blue-puzzle.png</file>
+        <file>content/gfx/blue.png</file>
+        <file>content/gfx/bubble-highscore.png</file>
+        <file>content/gfx/bubble-puzzle.png</file>
+        <file>content/gfx/but-game-1.png</file>
+        <file>content/gfx/but-game-2.png</file>
+        <file>content/gfx/but-game-3.png</file>
+        <file>content/gfx/but-game-4.png</file>
+        <file>content/gfx/but-game-new.png</file>
+        <file>content/gfx/but-menu.png</file>
+        <file>content/gfx/but-puzzle-next.png</file>
+        <file>content/gfx/but-quit.png</file>
+        <file>content/gfx/green-puzzle.png</file>
+        <file>content/gfx/green.png</file>
+        <file>content/gfx/icon-fail.png</file>
+        <file>content/gfx/icon-ok.png</file>
+        <file>content/gfx/icon-time.png</file>
+        <file>content/gfx/logo-a.png</file>
+        <file>content/gfx/logo-e.png</file>
+        <file>content/gfx/logo-g.png</file>
+        <file>content/gfx/logo-m.png</file>
+        <file>content/gfx/logo-s.png</file>
+        <file>content/gfx/logo.png</file>
+        <file>content/gfx/particle-brick.png</file>
+        <file>content/gfx/particle-paint.png</file>
+        <file>content/gfx/particle-smoke.png</file>
+        <file>content/gfx/red-puzzle.png</file>
+        <file>content/gfx/red.png</file>
+        <file>content/gfx/text-highscore-new.png</file>
+        <file>content/gfx/text-highscore.png</file>
+        <file>content/gfx/text-no-winner.png</file>
+        <file>content/gfx/text-p1-go.png</file>
+        <file>content/gfx/text-p1.png</file>
+        <file>content/gfx/text-p2-go.png</file>
+        <file>content/gfx/text-p2-won.png</file>
+        <file>content/gfx/text-p2.png</file>
+        <file>content/gfx/yellow-puzzle.png</file>
+        <file>content/gfx/yellow.png</file>
+        <file>content/levels/level0.qml</file>
+        <file>content/levels/level1.qml</file>
+        <file>content/levels/level2.qml</file>
+        <file>content/levels/level3.qml</file>
+        <file>content/levels/level4.qml</file>
+        <file>content/levels/level5.qml</file>
+        <file>content/levels/level6.qml</file>
+        <file>content/levels/level7.qml</file>
+        <file>content/levels/level8.qml</file>
+        <file>content/levels/level9.qml</file>
+        <file>content/levels/TemplateBase.qml</file>
+        <file>content/SamegameText.qml</file>
+        <file>content/SimpleBlock.qml</file>
+        <file>content/Block.qml</file>
+        <file>content/BlockEmitter.qml</file>
+        <file>content/Button.qml</file>
+        <file>content/GameArea.qml</file>
+        <file>content/LogoAnimation.qml</file>
+        <file>content/MenuEmitter.qml</file>
+        <file>content/PaintEmitter.qml</file>
+        <file>content/PrimaryPack.qml</file>
+        <file>content/PuzzleBlock.qml</file>
+        <file>content/samegame.js</file>
+        <file>content/SmokeText.qml</file>
+    </qresource>
+</RCC>
index 779d204..d893aa5 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(stocqt)
+DECLARATIVE_EXAMPLE_MAIN(demos/stocqt/stocqt)
index f33c4ae..efe37cb 100644 (file)
@@ -2,8 +2,7 @@ TEMPLATE = app
 
 QT += qml quick
 SOURCES += main.cpp
+RESOURCES += stocqt.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/demos/stocqt
-qml.files = stocqt.qml content
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/demos/stocqt
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/demos/stocqt/stocqt.qrc b/examples/quick/demos/stocqt/stocqt.qrc
new file mode 100644 (file)
index 0000000..b2b1aca
--- /dev/null
@@ -0,0 +1,21 @@
+<RCC>
+    <qresource prefix="/demos/stocqt">
+        <file>stocqt.qml</file>
+        <file>content/Button.qml</file>
+        <file>content/DatePicker.qml</file>
+        <file>content/StockChart.qml</file>
+        <file>content/StockListModel.qml</file>
+        <file>content/StockListView.qml</file>
+        <file>content/StockModel.qml</file>
+        <file>content/StockSettings.qml</file>
+        <file>content/StockView.qml</file>
+        <file>content/images/icon-calendar-anim.png</file>
+        <file>content/images/icon-calendar.png</file>
+        <file>content/images/icon-items.png</file>
+        <file>content/images/icon-settings.png</file>
+        <file>content/images/logo.png</file>
+        <file>content/images/stock-selected.png</file>
+        <file>content/images/wheel-touch.png</file>
+        <file>content/images/wheel.png</file>
+    </qresource>
+</RCC>
index 8b1d596..6253bc2 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(tweetsearch)
+DECLARATIVE_EXAMPLE_MAIN(demos/tweetsearch/tweetsearch)
index 887c05a..b063cc4 100644 (file)
@@ -2,8 +2,7 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += tweetsearch.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/demos/tweetsearch
-qml.files = tweetsearch.qml content
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/demos/tweetsearch
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/demos/tweetsearch/tweetsearch.qrc b/examples/quick/demos/tweetsearch/tweetsearch.qrc
new file mode 100644 (file)
index 0000000..b23c3c5
--- /dev/null
@@ -0,0 +1,19 @@
+<RCC>
+    <qresource prefix="/demos/tweetsearch">
+        <file>tweetsearch.qml</file>
+        <file>content/FlipBar.qml</file>
+        <file>content/LineInput.qml</file>
+        <file>content/ListFooter.qml</file>
+        <file>content/ListHeader.qml</file>
+        <file>content/SearchDelegate.qml</file>
+        <file>content/TweetDelegate.qml</file>
+        <file>content/tweetsearch.js</file>
+        <file>content/TweetsModel.qml</file>
+        <file>content/resources/anonymous.png</file>
+        <file>content/resources/bird-anim-sprites.png</file>
+        <file>content/resources/icon-clear.png</file>
+        <file>content/resources/icon-loading.png</file>
+        <file>content/resources/icon-refresh.png</file>
+        <file>content/resources/icon-search.png</file>
+    </qresource>
+</RCC>
index 451d03a..e62b936 100644 (file)
@@ -2,8 +2,9 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    draganddrop.qrc \
+    ../shared/shared.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/draganddrop
-qml.files = draganddrop.qml tiles views
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/draganddrop
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/draganddrop/draganddrop.qrc b/examples/quick/draganddrop/draganddrop.qrc
new file mode 100644 (file)
index 0000000..6d064f7
--- /dev/null
@@ -0,0 +1,9 @@
+<RCC>
+    <qresource prefix="/draganddrop">
+        <file>draganddrop.qml</file>
+        <file>tiles/DragTile.qml</file>
+        <file>tiles/DropTile.qml</file>
+        <file>tiles/tiles.qml</file>
+        <file>views/gridview.qml</file>
+    </qresource>
+</RCC>
index 7a7adf2..d9bf436 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(draganddrop)
+DECLARATIVE_EXAMPLE_MAIN(draganddrop/draganddrop)
index 281b44f..4d1c6f0 100644 (file)
@@ -2,8 +2,9 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    imageelements.qrc \
+    ../shared/shared.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/imageelements
-qml.files = *.qml content
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/imageelements
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/imageelements/imageelements.qrc b/examples/quick/imageelements/imageelements.qrc
new file mode 100644 (file)
index 0000000..ef8a9e5
--- /dev/null
@@ -0,0 +1,23 @@
+<RCC>
+    <qresource prefix="/imageelements">
+        <file>content/arrow.png</file>
+        <file>content/BearSheet.png</file>
+        <file>content/BorderImageSelector.qml</file>
+        <file>content/bw.png</file>
+        <file>content/colors-round.sci</file>
+        <file>content/colors-stretch.sci</file>
+        <file>content/colors.png</file>
+        <file>content/ImageCell.qml</file>
+        <file>content/MyBorderImage.qml</file>
+        <file>content/qt-logo.png</file>
+        <file>content/shadow.png</file>
+        <file>content/ShadowRectangle.qml</file>
+        <file>content/speaker.png</file>
+        <file>imageelements.qml</file>
+        <file>animatedsprite.qml</file>
+        <file>borderimage.qml</file>
+        <file>image.qml</file>
+        <file>shadows.qml</file>
+        <file>spritesequence.qml</file>
+    </qresource>
+</RCC>
index aa624e2..ab7d521 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(imageelements)
+DECLARATIVE_EXAMPLE_MAIN(imageelements/imageelements)
index a0c65be..edc157f 100644 (file)
@@ -2,8 +2,7 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += keyinteraction.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/keyinteraction
-qml.files = keyinteraction.qml focus
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/keyinteraction
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/keyinteraction/keyinteraction.qrc b/examples/quick/keyinteraction/keyinteraction.qrc
new file mode 100644 (file)
index 0000000..21bde44
--- /dev/null
@@ -0,0 +1,12 @@
+<RCC>
+    <qresource prefix="/keyinteraction">
+        <file>keyinteraction.qml</file>
+        <file>focus/focus.qml</file>
+        <file>focus/Core/images/arrow.png</file>
+        <file>focus/Core/images/qt-logo.png</file>
+        <file>focus/Core/ContextMenu.qml</file>
+        <file>focus/Core/GridMenu.qml</file>
+        <file>focus/Core/ListMenu.qml</file>
+        <file>focus/Core/ListViewDelegate.qml</file>
+    </qresource>
+</RCC>
index e82e1d8..4f226e7 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(keyinteraction)
+DECLARATIVE_EXAMPLE_MAIN(keyinteraction/keyinteraction)
index ef90b63..80c306f 100644 (file)
@@ -2,8 +2,9 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    localstorage.qrc \
+    ../../shared/shared.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/localstorage/localstorage
-qml.files = localstorage.qml hello.qml
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/localstorage/localstorage
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/localstorage/localstorage/localstorage.qrc b/examples/quick/localstorage/localstorage/localstorage.qrc
new file mode 100644 (file)
index 0000000..09ac2de
--- /dev/null
@@ -0,0 +1,6 @@
+<RCC>
+    <qresource prefix="/localstorage/localstorage">
+        <file>hello.qml</file>
+        <file>localstorage.qml</file>
+    </qresource>
+</RCC>
index 0f69fb7..8433dbe 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(localstorage)
+DECLARATIVE_EXAMPLE_MAIN(localstorage/localstorage/localstorage)
index 34e0b3b..f07341c 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(mousearea)
+DECLARATIVE_EXAMPLE_MAIN(mousearea/mousearea)
index eba203b..7820829 100644 (file)
@@ -2,11 +2,10 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += mousearea.qrc
 
 EXAMPLE_FILES = \
     mousearea-wheel-example.qml
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/mousearea
-qml.files = mousearea.qml
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/mousearea
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/mousearea/mousearea.qrc b/examples/quick/mousearea/mousearea.qrc
new file mode 100644 (file)
index 0000000..23d30aa
--- /dev/null
@@ -0,0 +1,6 @@
+<RCC>
+    <qresource prefix="/mousearea">
+        <file>mousearea.qml</file>
+        <file>mousearea-wheel-example.qml</file>
+    </qresource>
+</RCC>
index 9d7c3de..673ccfb 100644 (file)
@@ -2,8 +2,10 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    affectors.qrc \
+    ../images.qrc \
+    ../../shared/shared.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/particles/affectors
-qml.files = affectors.qml content
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/particles/affectors
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/particles/affectors/affectors.qrc b/examples/quick/particles/affectors/affectors.qrc
new file mode 100644 (file)
index 0000000..c1d797e
--- /dev/null
@@ -0,0 +1,16 @@
+<RCC>
+    <qresource prefix="/particles/affectors">
+        <file>affectors.qml</file>
+        <file>content/age.qml</file>
+        <file>content/attractor.qml</file>
+        <file>content/customaffector.qml</file>
+        <file>content/friction.qml</file>
+        <file>content/gravity.qml</file>
+        <file>content/GreyButton.qml</file>
+        <file>content/groupgoal.qml</file>
+        <file>content/move.qml</file>
+        <file>content/spritegoal.qml</file>
+        <file>content/turbulence.qml</file>
+        <file>content/wander.qml</file>
+    </qresource>
+</RCC>
index 358fcb4..76d79de 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(affectors)
+DECLARATIVE_EXAMPLE_MAIN(particles/affectors/affectors)
index 77db1a6..66a6895 100644 (file)
@@ -2,8 +2,11 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    customparticle.qrc \
+    ../images.qrc \
+    ../../shared/shared.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/particles/customparticle
-qml.files = customparticle.qml content
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/particles/customparticle
-INSTALLS += target qml
+INSTALLS += target
+
diff --git a/examples/quick/particles/customparticle/customparticle.qrc b/examples/quick/particles/customparticle/customparticle.qrc
new file mode 100644 (file)
index 0000000..8a4e087
--- /dev/null
@@ -0,0 +1,8 @@
+<RCC>
+    <qresource prefix="/particles/customparticle">
+        <file>customparticle.qml</file>
+        <file>content/blurparticles.qml</file>
+        <file>content/fragmentshader.qml</file>
+        <file>content/imagecolors.qml</file>
+    </qresource>
+</RCC>
index ec5619c..c873710 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(customparticle)
+DECLARATIVE_EXAMPLE_MAIN(particles/customparticle/customparticle)
index ea2e0d1..c5d8b8b 100644 (file)
@@ -2,8 +2,10 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    emitters.qrc \
+    ../images.qrc \
+    ../../shared/shared.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/particles/emitters
-qml.files = emitters.qml content
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/particles/emitters
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/particles/emitters/emitters.qrc b/examples/quick/particles/emitters/emitters.qrc
new file mode 100644 (file)
index 0000000..708c868
--- /dev/null
@@ -0,0 +1,12 @@
+<RCC>
+    <qresource prefix="/particles/emitters">
+        <file>emitters.qml</file>
+        <file>content/burstandpulse.qml</file>
+        <file>content/customemitter.qml</file>
+        <file>content/emitmask.qml</file>
+        <file>content/maximumemitted.qml</file>
+        <file>content/shapeanddirection.qml</file>
+        <file>content/trailemitter.qml</file>
+        <file>content/velocityfrommotion.qml</file>
+    </qresource>
+</RCC>
index 01aff50..579e0d0 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(emitters)
+DECLARATIVE_EXAMPLE_MAIN(particles/emitters/emitters)
index 94ed5fc..e639c74 100644 (file)
@@ -2,8 +2,10 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    imageparticle.qrc \
+    ../images.qrc \
+    ../../shared/shared.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/particles/imageparticle
-qml.files = imageparticle.qml content
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/particles/imageparticle
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/particles/imageparticle/imageparticle.qrc b/examples/quick/particles/imageparticle/imageparticle.qrc
new file mode 100644 (file)
index 0000000..d9e4115
--- /dev/null
@@ -0,0 +1,12 @@
+<RCC>
+    <qresource prefix="/particles/imageparticle">
+        <file>imageparticle.qml</file>
+        <file>content/allatonce.qml</file>
+        <file>content/colored.qml</file>
+        <file>content/colortable.qml</file>
+        <file>content/deformation.qml</file>
+        <file>content/rotation.qml</file>
+        <file>content/sharing.qml</file>
+        <file>content/sprites.qml</file>
+    </qresource>
+</RCC>
index 081aec0..576182e 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(imageparticle)
+DECLARATIVE_EXAMPLE_MAIN(particles/imageparticle/imageparticle)
diff --git a/examples/quick/particles/images.qrc b/examples/quick/particles/images.qrc
new file mode 100644 (file)
index 0000000..9f284a0
--- /dev/null
@@ -0,0 +1,38 @@
+<RCC>
+    <qresource prefix="/particles">
+        <file>images/_explo.png</file>
+        <file>images/backgroundLeaves.jpg</file>
+        <file>images/bear_tiles.png</file>
+        <file>images/candle.png</file>
+        <file>images/colortable.png</file>
+        <file>images/finalfrontier.png</file>
+        <file>images/flower.png</file>
+        <file>images/matchmask.png</file>
+        <file>images/meteor_explo.png</file>
+        <file>images/meteor.png</file>
+        <file>images/meteors.png</file>
+        <file>images/nullRock.png</file>
+        <file>images/particle.png</file>
+        <file>images/particle2.png</file>
+        <file>images/particle3.png</file>
+        <file>images/particle4.png</file>
+        <file>images/particleA.png</file>
+        <file>images/portal_bg.png</file>
+        <file>images/realLeaf1.png</file>
+        <file>images/realLeaf2.png</file>
+        <file>images/realLeaf3.png</file>
+        <file>images/realLeaf4.png</file>
+        <file>images/rocket.png</file>
+        <file>images/rocket2.png</file>
+        <file>images/sizeInOut.png</file>
+        <file>images/snowflake.png</file>
+        <file>images/sparkleSize.png</file>
+        <file>images/star.png</file>
+        <file>images/starfish_0.png</file>
+        <file>images/starfish_1.png</file>
+        <file>images/starfish_2.png</file>
+        <file>images/starfish_3.png</file>
+        <file>images/starfish_4.png</file>
+        <file>images/starfish_mask.png</file>
+    </qresource>
+</RCC>
index ea67283..0bc8404 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(system)
+DECLARATIVE_EXAMPLE_MAIN(particles/system/system)
index f2e3567..df143f1 100644 (file)
@@ -2,8 +2,10 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    system.qrc \
+    ../images.qrc \
+    ../../shared/shared.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/particles/system
-qml.files = system.qml content
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/particles/system
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/particles/system/system.qrc b/examples/quick/particles/system/system.qrc
new file mode 100644 (file)
index 0000000..3fb8221
--- /dev/null
@@ -0,0 +1,10 @@
+<RCC>
+    <qresource prefix="/particles/system">
+        <file>system.qml</file>
+        <file>content/dynamiccomparison.qml</file>
+        <file>content/dynamicemitters.qml</file>
+        <file>content/multiplepainters.qml</file>
+        <file>content/startstop.qml</file>
+        <file>content/timedgroupchanges.qml</file>
+    </qresource>
+</RCC>
index 4ee4c82..5554af6 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(positioners)
+DECLARATIVE_EXAMPLE_MAIN(positioners/positioners)
index 1a7622d..a754d2a 100644 (file)
@@ -2,8 +2,9 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    positioners.qrc \
+    ../shared/shared.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/positioners
-qml.files = positioners.qml positioners-transitions.qml positioners-attachedproperties.qml
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/positioners
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/positioners/positioners.qrc b/examples/quick/positioners/positioners.qrc
new file mode 100644 (file)
index 0000000..7025a6f
--- /dev/null
@@ -0,0 +1,7 @@
+<RCC>
+    <qresource prefix="/positioners">
+        <file>positioners.qml</file>
+        <file>positioners-attachedproperties.qml</file>
+        <file>positioners-transitions.qml</file>
+    </qresource>
+</RCC>
index e1d102c..c008e2c 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(righttoleft)
+DECLARATIVE_EXAMPLE_MAIN(righttoleft/righttoleft)
index e71030e..248564e 100644 (file)
@@ -2,8 +2,9 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    righttoleft.qrc \
+    ../shared/shared.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/righttoleft
-qml.files = righttoleft.qml layoutdirection layoutmirroring textalignment
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/righttoleft
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/righttoleft/righttoleft.qrc b/examples/quick/righttoleft/righttoleft.qrc
new file mode 100644 (file)
index 0000000..1d9f068
--- /dev/null
@@ -0,0 +1,8 @@
+<RCC>
+    <qresource prefix="/righttoleft">
+        <file>righttoleft.qml</file>
+        <file>layoutdirection/layoutdirection.qml</file>
+        <file>layoutmirroring/layoutmirroring.qml</file>
+        <file>textalignment/textalignment.qml</file>
+    </qresource>
+</RCC>
index 8044c5c..17c30fc 100644 (file)
@@ -8,8 +8,7 @@ SOURCES += \
 HEADERS += \
     beziercurve.h
 
-target.path = $$[QT_INSTALL_EXAMPLES]/quick/scenegraph/customgeometry
-qml.files = main.qml
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/scenegraph/customgeometry
+RESOURCES += customgeometry.qrc
 
-INSTALLS += target qml
+target.path = $$[QT_INSTALL_EXAMPLES]/quick/scenegraph/customgeometry
+INSTALLS += target
diff --git a/examples/quick/scenegraph/customgeometry/customgeometry.qrc b/examples/quick/scenegraph/customgeometry/customgeometry.qrc
new file mode 100644 (file)
index 0000000..39080c5
--- /dev/null
@@ -0,0 +1,5 @@
+<RCC>
+    <qresource prefix="/scenegraph/customgeometry">
+        <file>main.qml</file>
+    </qresource>
+</RCC>
index 6cb2b0e..ea699c1 100644 (file)
@@ -52,7 +52,7 @@ int main(int argc, char **argv)
     qmlRegisterType<BezierCurve>("CustomGeometry", 1, 0, "BezierCurve");
 
     QQuickView view;
-    view.setSource(QUrl("main.qml"));
+    view.setSource(QUrl("qrc:///scenegraph/customgeometry/main.qml"));
     view.show();
 
     app.exec();
index c5a68e8..adc389c 100644 (file)
@@ -53,7 +53,7 @@ int main(int argc, char **argv)
     qmlRegisterType<Squircle>("OpenGLUnderQML", 1, 0, "Squircle");
 
     QQuickView view;
-    view.setSource(QUrl("main.qml"));
+    view.setSource(QUrl("qrc:///scenegraph/openglunderqml/main.qml"));
     view.show();
 
     return app.exec();
index f86dd5f..54558ce 100644 (file)
@@ -2,8 +2,7 @@ QT += qml quick
 
 HEADERS += squircle.h
 SOURCES += squircle.cpp main.cpp
+RESOURCES += openglunderqml.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/scenegraph/openglunderqml
-qml.files = main.qml
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/scenegraph/openglunderqml
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/scenegraph/openglunderqml/openglunderqml.qrc b/examples/quick/scenegraph/openglunderqml/openglunderqml.qrc
new file mode 100644 (file)
index 0000000..d166ea9
--- /dev/null
@@ -0,0 +1,5 @@
+<RCC>
+    <qresource prefix="/scenegraph/openglunderqml">
+        <file>main.qml</file>
+    </qresource>
+</RCC>
index de5ae9e..b7bea08 100644 (file)
@@ -185,7 +185,7 @@ int main(int argc, char **argv)
     qmlRegisterType<Item>("SimpleMaterial", 1, 0, "SimpleMaterialItem");
 
     QQuickView view;
-    view.setSource(QUrl("main.qml"));
+    view.setSource(QUrl("qrc:///scenegraph/simplematerial/main.qml"));
     view.show();
 
     return app.exec();
index ae4fb0f..6ae935f 100644 (file)
@@ -3,6 +3,7 @@ QT += quick
 
 SOURCES += \
     simplematerial.cpp
+RESOURCES += simplematerial.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/scenegraph/simplematerial
 qml.files = main.qml
diff --git a/examples/quick/scenegraph/simplematerial/simplematerial.qrc b/examples/quick/scenegraph/simplematerial/simplematerial.qrc
new file mode 100644 (file)
index 0000000..4cc1eaa
--- /dev/null
@@ -0,0 +1,5 @@
+<RCC>
+    <qresource prefix="/scenegraph/simplematerial">
+        <file>main.qml</file>
+    </qresource>
+</RCC>
index 2bb3224..c40c780 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(shadereffects)
+DECLARATIVE_EXAMPLE_MAIN(shadereffects/shadereffects)
index 265cb72..088b4a3 100644 (file)
@@ -2,8 +2,7 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += shadereffects.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/shadereffects
-qml.files = shadereffects.qml content
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/shadereffects
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/shadereffects/shadereffects.qrc b/examples/quick/shadereffects/shadereffects.qrc
new file mode 100644 (file)
index 0000000..ff296a0
--- /dev/null
@@ -0,0 +1,8 @@
+<RCC>
+    <qresource prefix="/shadereffects">
+        <file>shadereffects.qml</file>
+        <file>content/face-smile.png</file>
+        <file>content/qt-logo.png</file>
+        <file>content/Slider.qml</file>
+    </qresource>
+</RCC>
diff --git a/examples/quick/shared/quick_shared.qrc b/examples/quick/shared/quick_shared.qrc
new file mode 100644 (file)
index 0000000..9fc114d
--- /dev/null
@@ -0,0 +1,8 @@
+<RCC>
+    <qresource prefix="/quick/shared">
+        <file>LauncherList.qml</file>
+        <file>SimpleLauncherDelegate.qml</file>
+        <file>Button.qml</file>
+        <file>images/back.png</file>
+    </qresource>
+</RCC>
index 7fd2f08..a7072da 100644 (file)
 {\
     QGuiApplication app(argc,argv);\
     QQuickView view;\
-    QDir directory(QCoreApplication::applicationDirPath());\
-    if (QGuiApplication::platformName() == QLatin1String("windows")) {\
-        if (directory.absolutePath().endsWith("/debug", Qt::CaseInsensitive)\
-            || directory.absolutePath().endsWith("/release", Qt::CaseInsensitive))\
-            if (!directory.cdUp()) {\
-                qWarning("Could not change to parent directory of '%s'",\
-                    qPrintable(QDir::toNativeSeparators(directory.absolutePath())));\
-                return -1;\
-            }\
-    } else if (QGuiApplication::platformName() == QLatin1String("cocoa")) {\
-        if (directory.absolutePath().endsWith(#NAME".app/Contents/MacOS"))\
-            for (int i = 0; i < 3; ++i) {\
-                if (!directory.cdUp()) {\
-                    qWarning("Could not change to parent directory of '%s'",\
-                        qPrintable(QDir::toNativeSeparators(directory.absolutePath())));\
-                    return -1;\
-                }\
-            }\
-    }\
-    const QString fileName(directory.absolutePath() + "/" #NAME ".qml");\
-    if (!QFile::exists(fileName)) {\
-            qWarning("Could not find file '%s'", qPrintable(QDir::toNativeSeparators(fileName)));\
-            return -1;\
-    }\
     view.connect(view.engine(), SIGNAL(quit()), &app, SLOT(quit()));\
-    view.setSource(QUrl::fromLocalFile(fileName)); \
+    view.setSource(QUrl("qrc:///" #NAME ".qml")); \
     if (QGuiApplication::platformName() == QLatin1String("qnx") || \
           QGuiApplication::platformName() == QLatin1String("eglfs")) {\
         view.setResizeMode(QQuickView::SizeRootObjectToView);\
diff --git a/examples/quick/shared/shared.qrc b/examples/quick/shared/shared.qrc
new file mode 100644 (file)
index 0000000..4ac856e
--- /dev/null
@@ -0,0 +1,8 @@
+<RCC>
+    <qresource prefix="/shared">
+        <file>LauncherList.qml</file>
+        <file>SimpleLauncherDelegate.qml</file>
+        <file>Button.qml</file>
+        <file>images/back.png</file>
+    </qresource>
+</RCC>
index 9b3c626..b8f927d 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(text)
+DECLARATIVE_EXAMPLE_MAIN(text/text)
index 2f78548..733a993 100644 (file)
@@ -2,8 +2,9 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    text.qrc \
+    ../shared/shared.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/text
-qml.files = fonts imgtag styledtext-layout.qml text.qml textselection
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/text
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/text/text.qrc b/examples/quick/text/text.qrc
new file mode 100644 (file)
index 0000000..f0d2162
--- /dev/null
@@ -0,0 +1,24 @@
+<RCC>
+    <qresource prefix="/text">
+        <file>text.qml</file>
+        <file>fonts/availableFonts.qml</file>
+        <file>fonts/banner.qml</file>
+        <file>fonts/fonts.qml</file>
+        <file>fonts/hello.qml</file>
+        <file>fonts/content/fonts/tarzeau_ocr_a.ttf</file>
+        <file>imgtag/imgtag.qml</file>
+        <file>imgtag/images/face-sad.png</file>
+        <file>imgtag/images/face-smile-big.png</file>
+        <file>imgtag/images/face-smile.png</file>
+        <file>imgtag/images/heart200.png</file>
+        <file>imgtag/images/qtlogo.png</file>
+        <file>imgtag/images/starfish_2.png</file>
+        <file>textselection/textselection.qml</file>
+        <file>textselection/pics/endHandle.png</file>
+        <file>textselection/pics/endHandle.sci</file>
+        <file>textselection/pics/startHandle.png</file>
+        <file>textselection/pics/startHandle.sci</file>
+        <file>styledtext-layout.qml</file>
+        <file>imgtag/TextWithImage.qml</file>
+    </qresource>
+</RCC>
index 47ea0b5..7e4e485 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(threading)
+DECLARATIVE_EXAMPLE_MAIN(threading/threading)
index fa5488a..cd9ed25 100644 (file)
@@ -2,8 +2,9 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    threading.qrc \
+    ../shared/shared.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/threading
-qml.files = threading.qml threadedlistmodel workerscript
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/threading
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/threading/threading.qrc b/examples/quick/threading/threading.qrc
new file mode 100644 (file)
index 0000000..6d15b7e
--- /dev/null
@@ -0,0 +1,10 @@
+<RCC>
+    <qresource prefix="/threading">
+        <file>threading.qml</file>
+        <file>threadedlistmodel/timedisplay.qml</file>
+        <file>threadedlistmodel/dataloader.js</file>
+        <file>workerscript/Spinner.qml</file>
+        <file>workerscript/workerscript.js</file>
+        <file>workerscript/workerscript.qml</file>
+    </qresource>
+</RCC>
index aac3175..6db041e 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(touchinteraction)
+DECLARATIVE_EXAMPLE_MAIN(touchinteraction/touchinteraction)
index 949651c..0ae0a41 100644 (file)
@@ -2,8 +2,9 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    touchinteraction.qrc \
+    ../shared/shared.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/touchinteraction
-qml.files = flickable multipointtouch pincharea touchinteraction.qml
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/touchinteraction
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/touchinteraction/touchinteraction.qrc b/examples/quick/touchinteraction/touchinteraction.qrc
new file mode 100644 (file)
index 0000000..6cec506
--- /dev/null
@@ -0,0 +1,27 @@
+<RCC>
+    <qresource prefix="/touchinteraction">
+        <file>touchinteraction.qml</file>
+        <file>flickable/basic-flickable.qml</file>
+        <file>flickable/corkboards.qml</file>
+        <file>flickable/content/cork.jpg</file>
+        <file>flickable/content/note-yellow.png</file>
+        <file>flickable/content/Panel.qml</file>
+        <file>flickable/content/tack.png</file>
+        <file>multipointtouch/bearwhack.qml</file>
+        <file>multipointtouch/multiflame.qml</file>
+        <file>multipointtouch/content/AugmentedTouchPoint.qml</file>
+        <file>multipointtouch/content/Bear0.png</file>
+        <file>multipointtouch/content/Bear1.png</file>
+        <file>multipointtouch/content/Bear2.png</file>
+        <file>multipointtouch/content/Bear3.png</file>
+        <file>multipointtouch/content/BearB.png</file>
+        <file>multipointtouch/content/BearWhackParticleSystem.qml</file>
+        <file>multipointtouch/content/blur-circle.png</file>
+        <file>multipointtouch/content/blur-circle3.png</file>
+        <file>multipointtouch/content/heart-blur.png</file>
+        <file>multipointtouch/content/ParticleFlame.qml</file>
+        <file>multipointtouch/content/title.png</file>
+        <file>pincharea/flickresize.qml</file>
+        <file>pincharea/qt-logo.jpg</file>
+    </qresource>
+</RCC>
index 3d41683..52704fc 100644 (file)
@@ -38,4 +38,4 @@
 **
 ****************************************************************************/
 #include "../shared/shared.h"
-DECLARATIVE_EXAMPLE_MAIN(views)
+DECLARATIVE_EXAMPLE_MAIN(views/views)
index b424ba6..a79126a 100644 (file)
@@ -2,16 +2,9 @@ TEMPLATE = app
 
 QT += quick qml
 SOURCES += main.cpp
+RESOURCES += \
+    views.qrc \
+    ../shared/shared.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/views
-qml.files = \
-        views.qml \
-        gridview \
-        listview \
-        package \
-        parallax \
-        pathview \
-        visualdatamodel \
-        visualitemmodel
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/views
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/quick/views/views.qrc b/examples/quick/views/views.qrc
new file mode 100644 (file)
index 0000000..e35f128
--- /dev/null
@@ -0,0 +1,69 @@
+<RCC>
+    <qresource prefix="/views">
+        <file>gridview/gridview-example.qml</file>
+        <file>gridview/pics/AddressBook_48.png</file>
+        <file>gridview/pics/AudioPlayer_48.png</file>
+        <file>gridview/pics/Camera_48.png</file>
+        <file>gridview/pics/DateBook_48.png</file>
+        <file>gridview/pics/EMail_48.png</file>
+        <file>gridview/pics/TodoList_48.png</file>
+        <file>gridview/pics/VideoPlayer_48.png</file>
+        <file>listview/dynamiclist.qml</file>
+        <file>listview/expandingdelegates.qml</file>
+        <file>listview/highlight.qml</file>
+        <file>listview/highlightranges.qml</file>
+        <file>listview/sections.qml</file>
+        <file>listview/content/PetsModel.qml</file>
+        <file>listview/content/PressAndHoldButton.qml</file>
+        <file>listview/content/RecipesModel.qml</file>
+        <file>listview/content/SmallText.qml</file>
+        <file>listview/content/TextButton.qml</file>
+        <file>listview/content/ToggleButton.qml</file>
+        <file>listview/content/pics/arrow-down.png</file>
+        <file>listview/content/pics/arrow-up.png</file>
+        <file>listview/content/pics/fruit-salad.jpg</file>
+        <file>listview/content/pics/hamburger.jpg</file>
+        <file>listview/content/pics/lemonade.jpg</file>
+        <file>listview/content/pics/list-delete.png</file>
+        <file>listview/content/pics/minus-sign.png</file>
+        <file>listview/content/pics/moreDown.png</file>
+        <file>listview/content/pics/moreUp.png</file>
+        <file>listview/content/pics/pancakes.jpg</file>
+        <file>listview/content/pics/plus-sign.png</file>
+        <file>listview/content/pics/vegetable-soup.jpg</file>
+        <file>package/Delegate.qml</file>
+        <file>package/view.qml</file>
+        <file>parallax/parallax.qml</file>
+        <file>parallax/content/Smiley.qml</file>
+        <file>parallax/content/background.png</file>
+        <file>parallax/content/center.png</file>
+        <file>parallax/content/clock-night.png</file>
+        <file>parallax/content/clock.png</file>
+        <file>parallax/content/Clock.qml</file>
+        <file>parallax/content/hour.png</file>
+        <file>parallax/content/minute.png</file>
+        <file>parallax/content/ParallaxView.qml</file>
+        <file>parallax/content/quit.png</file>
+        <file>parallax/content/QuitButton.qml</file>
+        <file>parallax/content/second.png</file>
+        <file>parallax/content/pics/background.jpg</file>
+        <file>parallax/content/pics/face-smile.png</file>
+        <file>parallax/content/pics/home-page.png</file>
+        <file>parallax/content/pics/home-page.svg</file>
+        <file>parallax/content/pics/shadow.png</file>
+        <file>parallax/content/pics/yast-joystick.png</file>
+        <file>parallax/content/pics/yast-wol.png</file>
+        <file>pathview/pathview-example.qml</file>
+        <file>pathview/pics/AddressBook_48.png</file>
+        <file>pathview/pics/AudioPlayer_48.png</file>
+        <file>pathview/pics/Camera_48.png</file>
+        <file>pathview/pics/DateBook_48.png</file>
+        <file>pathview/pics/EMail_48.png</file>
+        <file>pathview/pics/TodoList_48.png</file>
+        <file>pathview/pics/VideoPlayer_48.png</file>
+        <file>visualdatamodel/slideshow.qml</file>
+        <file>visualdatamodel/dragselection.qml</file>
+        <file>visualitemmodel/visualitemmodel.qml</file>
+        <file>views.qml</file>
+    </qresource>
+</RCC>
index c9e6e90..619e275 100644 (file)
@@ -49,7 +49,7 @@ int main(int argc, char* argv[])
     QGuiApplication app(argc, argv);
     QQmlEngine engine;
     QQmlComponent component(&engine);
-    component.loadUrl(QUrl::fromLocalFile("Window.qml"));
+    component.loadUrl(QUrl("qrc:///window/window/Window.qml"));
     if ( component.isReady() )
         component.create();
     else
index e8a0223..6df7ce8 100644 (file)
@@ -3,9 +3,7 @@ CONFIG += qt
 QT += qml
 
 SOURCES += window.cpp
+RESOURCES += window.qrc
 
 target.path = $$[QT_INSTALL_EXAMPLES]/quick/window/window
-qml.files = Window.qml nogui.qml standalone.qml twowindows.qml
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/window/window
-
-INSTALLS = target qml
+INSTALLS = target
diff --git a/examples/quick/window/window/window.qrc b/examples/quick/window/window/window.qrc
new file mode 100644 (file)
index 0000000..c203c14
--- /dev/null
@@ -0,0 +1,5 @@
+<RCC>
+    <qresource prefix="/window/window">
+        <file>Window.qml</file>
+    </qresource>
+</RCC>