summaryrefslogtreecommitdiffstats
path: root/examples/declarative/dynamic
diff options
context:
space:
mode:
authorAlan Alpert <alan.alpert@nokia.com>2010-02-19 11:15:43 (GMT)
committerAlan Alpert <alan.alpert@nokia.com>2010-02-19 11:15:43 (GMT)
commitefecee2ca71bb89c9e40090c50fd5c27aeadbd18 (patch)
tree458dff670821814864084d5aeac22010ab82efa1 /examples/declarative/dynamic
parent6871d82c0f9c62d6b7bf0312324b51a4fbdf720c (diff)
downloadQt-efecee2ca71bb89c9e40090c50fd5c27aeadbd18.zip
Qt-efecee2ca71bb89c9e40090c50fd5c27aeadbd18.tar.gz
Qt-efecee2ca71bb89c9e40090c50fd5c27aeadbd18.tar.bz2
Fix dynamic example
Dynamic property creation appears to have been restricted.
Diffstat (limited to 'examples/declarative/dynamic')
-rw-r--r--examples/declarative/dynamic/qml/PerspectiveItem.qml1
1 files changed, 1 insertions, 0 deletions
diff --git a/examples/declarative/dynamic/qml/PerspectiveItem.qml b/examples/declarative/dynamic/qml/PerspectiveItem.qml
index 728c3a5..a0dfad3 100644
--- a/examples/declarative/dynamic/qml/PerspectiveItem.qml
+++ b/examples/declarative/dynamic/qml/PerspectiveItem.qml
@@ -6,6 +6,7 @@ Image {
property double scaleFactor: Math.max((y+height-250)*0.01, 0.3)
property double scaledBottom: y + (height+height*scaleFactor)/2
property bool onLand: scaledBottom > window.height/2
+ property string image //Needed for compatibility with GenericItem
opacity: onLand ? 1 : 0.25
onCreatedChanged: if (created && !onLand) { tree.destroy() } else { z = scaledBottom }
scale: scaleFactor