aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@digia.com>2013-09-23 16:35:34 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-09-25 13:13:30 +0200
commit36919b3e9e62feae1716493c57df051906325721 (patch)
treee62e09e785f9f347f02149d5c4cc8733aad337f3 /src
parent17588320da4598c61a72ac156d23f96a52d4c2fe (diff)
Fix Component.onCompleted emission and bindings for composite types
When instantiating the composite type with a sub QQmlObjectCreator, make sure to link the componentAttached objects back into the parent creator. Similarly we need to collect the bindings the sub-creator created, as finalize() is only called on the top-level creator. Fixes remaining failures in tst_qqmllanguage::onCompleted Change-Id: If79b31ee94000aeec280284200df8ee97e57fd03 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'src')
-rw-r--r--src/qml/qml/qqmlobjectcreator.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/qml/qml/qqmlobjectcreator.cpp b/src/qml/qml/qqmlobjectcreator.cpp
index fc841a916a..601f4dbba0 100644
--- a/src/qml/qml/qqmlobjectcreator.cpp
+++ b/src/qml/qml/qqmlobjectcreator.cpp
@@ -1241,6 +1241,9 @@ QObject *QmlObjectCreator::createInstance(int index, QObject *parent)
errors += subCreator.errors;
return 0;
}
+ if (subCreator.componentAttached)
+ subCreator.componentAttached->add(&componentAttached);
+ allCreatedBindings << subCreator.allCreatedBindings;
}
// ### use no-event variant
if (parent)