summaryrefslogtreecommitdiffstats
path: root/tests/auto/declarative/qmlecmascript/data/selfDeletingBinding.qml
diff options
context:
space:
mode:
authorAaron Kennedy <aaron.kennedy@nokia.com>2009-10-07 13:33:32 (GMT)
committerAaron Kennedy <aaron.kennedy@nokia.com>2009-10-08 03:25:50 (GMT)
commit60a5afb67efcefa74cf452379dcef46b83daa265 (patch)
tree322711feaaad46c8c1945e6fab99f2b5ba805f4d /tests/auto/declarative/qmlecmascript/data/selfDeletingBinding.qml
parentd07270161ef3d1c4b3ed29110a16eaff54333fd5 (diff)
downloadQt-60a5afb67efcefa74cf452379dcef46b83daa265.zip
Qt-60a5afb67efcefa74cf452379dcef46b83daa265.tar.gz
Qt-60a5afb67efcefa74cf452379dcef46b83daa265.tar.bz2
Self deleting binding test
Diffstat (limited to 'tests/auto/declarative/qmlecmascript/data/selfDeletingBinding.qml')
-rw-r--r--tests/auto/declarative/qmlecmascript/data/selfDeletingBinding.qml18
1 files changed, 18 insertions, 0 deletions
diff --git a/tests/auto/declarative/qmlecmascript/data/selfDeletingBinding.qml b/tests/auto/declarative/qmlecmascript/data/selfDeletingBinding.qml
new file mode 100644
index 0000000..074851a
--- /dev/null
+++ b/tests/auto/declarative/qmlecmascript/data/selfDeletingBinding.qml
@@ -0,0 +1,18 @@
+import Qt.test 1.0
+
+MyQmlContainer {
+ property bool triggerDelete: false
+
+ children: [
+ MyQmlObject {
+ // Will trigger deletion during binding evaluation
+ stringProperty: {deleteMe(), "Hello"}
+ },
+
+ MyQmlObject {
+ // Will trigger deletion during binding evaluation, but after component creation
+ stringProperty: if (triggerDelete) { deleteMe(), "Hello" } else { "World" }
+ }
+
+ ]
+}