summaryrefslogtreecommitdiffstats
path: root/examples/declarative/modelviews
diff options
context:
space:
mode:
authorBea Lam <bea.lam@nokia.com>2010-12-03 00:50:43 (GMT)
committerBea Lam <bea.lam@nokia.com>2010-12-03 00:56:37 (GMT)
commitfe63d0ee5671ec4f0a1926ad8875b9f11789b105 (patch)
tree1ba5b6111642292b7d9a1142a6712c669a3c50be /examples/declarative/modelviews
parent89f4a877c401e1ab18d3ed520d17440b3e9078e7 (diff)
downloadQt-fe63d0ee5671ec4f0a1926ad8875b9f11789b105.zip
Qt-fe63d0ee5671ec4f0a1926ad8875b9f11789b105.tar.gz
Qt-fe63d0ee5671ec4f0a1926ad8875b9f11789b105.tar.bz2
Add 'Writing New Components' docs, and document the connect() function.
The 'Writing QML Components' is mainly a restructuring of the 'Extending types from QML' page. It also documents the signal connect() function that was previously undocumented. Task-number: QTBUG-15718, QTBUG-15138
Diffstat (limited to 'examples/declarative/modelviews')
-rw-r--r--examples/declarative/modelviews/visualitemmodel/visualitemmodel.qml7
1 files changed, 7 insertions, 0 deletions
diff --git a/examples/declarative/modelviews/visualitemmodel/visualitemmodel.qml b/examples/declarative/modelviews/visualitemmodel/visualitemmodel.qml
index 15f2f11..f6564f7 100644
--- a/examples/declarative/modelviews/visualitemmodel/visualitemmodel.qml
+++ b/examples/declarative/modelviews/visualitemmodel/visualitemmodel.qml
@@ -55,16 +55,22 @@ Rectangle {
width: view.width; height: view.height
color: "#FFFEF0"
Text { text: "Page 1"; font.bold: true; anchors.centerIn: parent }
+
+ Component.onDestruction: print("destroyed 1")
}
Rectangle {
width: view.width; height: view.height
color: "#F0FFF7"
Text { text: "Page 2"; font.bold: true; anchors.centerIn: parent }
+
+ Component.onDestruction: print("destroyed 2")
}
Rectangle {
width: view.width; height: view.height
color: "#F4F0FF"
Text { text: "Page 3"; font.bold: true; anchors.centerIn: parent }
+
+ Component.onDestruction: print("destroyed 3")
}
}
@@ -76,6 +82,7 @@ Rectangle {
highlightRangeMode: ListView.StrictlyEnforceRange
orientation: ListView.Horizontal
snapMode: ListView.SnapOneItem; flickDeceleration: 2000
+ cacheBuffer: 200
}
Rectangle {