aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/quick/qquicklistview/data/destroyItemOnCreation.qml
diff options
context:
space:
mode:
authorKent Hansen <kent.hansen@nokia.com>2012-03-27 16:43:26 +0200
committerKent Hansen <kent.hansen@nokia.com>2012-03-27 16:56:14 +0200
commit24fb8dc27eddfdd62bd2c3a6e863cbf433762cd6 (patch)
tree917eff8c50fe4699547b9de852ee53257c1585cf /tests/auto/quick/qquicklistview/data/destroyItemOnCreation.qml
parent3e6a8eca00334df344a45f09afbcf8fd8e2b7c54 (diff)
parentffdbf216dc80b3d781307bb6b4b7150281c874a3 (diff)
Merge master into api_changes
Conflicts: src/qml/debugger/qqmlenginedebugservice.cpp src/qml/debugger/qqmlprofilerservice_p.h src/qml/qml/qqmlboundsignal.cpp src/qml/qml/qqmlpropertycache.cpp src/quick/util/qquickimageprovider.cpp Change-Id: I0609aa5ed54c7769f1e2773a96a7cd43a69f133c
Diffstat (limited to 'tests/auto/quick/qquicklistview/data/destroyItemOnCreation.qml')
-rw-r--r--tests/auto/quick/qquicklistview/data/destroyItemOnCreation.qml37
1 files changed, 37 insertions, 0 deletions
diff --git a/tests/auto/quick/qquicklistview/data/destroyItemOnCreation.qml b/tests/auto/quick/qquicklistview/data/destroyItemOnCreation.qml
new file mode 100644
index 0000000000..12f43b029a
--- /dev/null
+++ b/tests/auto/quick/qquicklistview/data/destroyItemOnCreation.qml
@@ -0,0 +1,37 @@
+import QtQuick 2.0
+
+Rectangle {
+ id: root
+
+ width: 240
+ height: 320
+
+ property int createdIndex: -1
+
+ Component {
+ id: myDelegate
+
+ Rectangle {
+ id: wrapper
+ width: 240; height: 20
+ objectName: "wrapper"
+
+ Text { text: index }
+
+ Component.onCompleted: {
+ root.createdIndex = index
+ ListView.view.model.removeItem(index)
+ }
+ }
+ }
+
+ ListView {
+ id: list
+ objectName: "list"
+ focus: true
+ width: 240
+ height: 320
+ delegate: myDelegate
+ model: testModel
+ }
+}