From fd68b868aee89f40138492468745f0e5edb3286e Mon Sep 17 00:00:00 2001 From: Chris Adams Date: Tue, 12 Jul 2011 14:05:24 +1000 Subject: Honour the resettable flag of aliased properties Previously, alias properties were not considered isResettable even if the property they alias is resettable. This commit ensures that the IsResettable flag is set for alias properties iff the aliased property is resettable, and that it is honoured during property reset operations. Task-number: QTBUG-18182 Change-Id: I9cab11923a952df72e976a48489a78b24a34314f Reviewed-on: http://codereview.qt.nokia.com/1471 Reviewed-by: Qt Sanity Bot Reviewed-by: Aaron Kennedy --- .../data/aliasreset/AliasPropertyComponent.qml | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 tests/auto/declarative/qdeclarativeecmascript/data/aliasreset/AliasPropertyComponent.qml (limited to 'tests/auto/declarative/qdeclarativeecmascript/data/aliasreset/AliasPropertyComponent.qml') diff --git a/tests/auto/declarative/qdeclarativeecmascript/data/aliasreset/AliasPropertyComponent.qml b/tests/auto/declarative/qdeclarativeecmascript/data/aliasreset/AliasPropertyComponent.qml new file mode 100644 index 0000000000..9135e79469 --- /dev/null +++ b/tests/auto/declarative/qdeclarativeecmascript/data/aliasreset/AliasPropertyComponent.qml @@ -0,0 +1,17 @@ +import QtQuick 2.0 + +Item { + id: apc + property alias sourceComponent: loader.sourceComponent + + Component { + id: redSquare + Rectangle { color: "red"; width: 10; height: 10 } + } + + Loader { + id: loader + objectName: "loader" + sourceComponent: redSquare + } +} -- cgit v1.2.3