summaryrefslogtreecommitdiffstats
path: root/tests/auto/declarative/qdeclarativelanguage/data
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@digia.com>2013-07-16 15:28:11 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-07-17 07:36:24 +0200
commit1f3d0ae63b2501460fc1c75f22b579b29147a80d (patch)
tree05617de2bd37bce11de6bfb0e7217a75ddbed64e /tests/auto/declarative/qdeclarativelanguage/data
parent86b1cc8113f7151417206fe0478fbd71336b9c8f (diff)
Fix regression from Qt 4 for deep group properties
Setting a property like someObject.font.family would cause an out-of-bounds assertion in QList, called from QQmlCompiler::genValueTypeProperty. This appears to be a regression from commit 5e970b84663f5398eb51d4575856d1a3c44df953, which replaced one -1 to QMetaType::QVariant too many times. It appears the use of -1 is rather deliberate here and not to indicate the use of a QVariant property. The attached test verifies this as well as the successful setting of the property at the end. Task-number: QTBUG-31576 Change-Id: I237ea08847e1db31481a311ea8ec23a5ccc702d8 Reviewed-by: Matthew Vogt <matthew.vogt@qinetic.com.au> Reviewed-by: Andrew den Exter <andrew.den.exter@qinetic.com.au>
Diffstat (limited to 'tests/auto/declarative/qdeclarativelanguage/data')
-rw-r--r--tests/auto/declarative/qdeclarativelanguage/data/DeepComponent.qml7
-rw-r--r--tests/auto/declarative/qdeclarativelanguage/data/deepProperty.qml4
2 files changed, 11 insertions, 0 deletions
diff --git a/tests/auto/declarative/qdeclarativelanguage/data/DeepComponent.qml b/tests/auto/declarative/qdeclarativelanguage/data/DeepComponent.qml
new file mode 100644
index 00000000..55753def
--- /dev/null
+++ b/tests/auto/declarative/qdeclarativelanguage/data/DeepComponent.qml
@@ -0,0 +1,7 @@
+import QtQuick 1.1
+Item {
+ property alias someObject: text
+ Text {
+ id: text
+ }
+}
diff --git a/tests/auto/declarative/qdeclarativelanguage/data/deepProperty.qml b/tests/auto/declarative/qdeclarativelanguage/data/deepProperty.qml
new file mode 100644
index 00000000..0787bded
--- /dev/null
+++ b/tests/auto/declarative/qdeclarativelanguage/data/deepProperty.qml
@@ -0,0 +1,4 @@
+import QtQuick 1.1
+DeepComponent {
+ someObject.font.family: "test"
+}