aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/declarative/qdeclarativeecmascript/data
diff options
context:
space:
mode:
authorGlenn Watson <glenn.watson@nokia.com>2011-11-22 09:13:21 +1000
committerQt by Nokia <qt-info@nokia.com>2011-11-22 03:31:11 +0100
commit0bf08af2b945f10f44561ffa0abd6f89b093b376 (patch)
treef7cb7e6cd3061eaf3878bf8787708ed03428c07e /tests/auto/declarative/qdeclarativeecmascript/data
parent3ef0ce6b794ed58d26ec6355cc13fd00f66c5176 (diff)
Fix default property preventing signals from being emitted.
Change the way connectAlias works so that even if the target for the connection is not available immediately, anything that is bound to it is notified when the target is changed. (Fix is authored by Aaron). Task-number: QTBUG-21580 Change-Id: Ida23c0e620069c50b123c71b5078929d4c7ec4e4 Reviewed-by: Martin Jones <martin.jones@nokia.com>
Diffstat (limited to 'tests/auto/declarative/qdeclarativeecmascript/data')
-rw-r--r--tests/auto/declarative/qdeclarativeecmascript/data/qtbug_21580.qml22
1 files changed, 22 insertions, 0 deletions
diff --git a/tests/auto/declarative/qdeclarativeecmascript/data/qtbug_21580.qml b/tests/auto/declarative/qdeclarativeecmascript/data/qtbug_21580.qml
new file mode 100644
index 0000000000..dc0066ba3f
--- /dev/null
+++ b/tests/auto/declarative/qdeclarativeecmascript/data/qtbug_21580.qml
@@ -0,0 +1,22 @@
+import QtQuick 2.0
+
+QtObject {
+ property bool test: false
+
+ property list<QtObject> objects: [
+ QtObject {
+ id: first
+ property alias myAlias: other.myProperty
+ onMyAliasChanged: if (myAlias == 20) test = true
+ },
+ QtObject {
+ id: other
+ property real myProperty
+ }
+ ]
+
+ Component.onCompleted: {
+ other.myProperty = 20;
+ }
+}
+