demos/declarative/rssnews/rssnews.qml
changeset 37 758a864f9613
parent 30 5dc02b23752f
--- a/demos/declarative/rssnews/rssnews.qml	Fri Sep 17 08:34:18 2010 +0300
+++ b/demos/declarative/rssnews/rssnews.qml	Mon Oct 04 01:19:32 2010 +0300
@@ -71,6 +71,7 @@
                 id: categories
                 anchors.fill: parent
                 model: rssFeeds
+                footer: quitButtonDelegate
                 delegate: CategoryDelegate {}
                 highlight: Rectangle { color: "steelblue" }
                 highlightMoveSpeed: 9999999
@@ -87,7 +88,24 @@
             delegate: NewsDelegate {}
         }
     }
-
+    Component {
+        id: quitButtonDelegate
+        Item {
+            width: categories.width; height: 60
+            Text {
+                text: "Quit"
+                font { family: "Helvetica"; pixelSize: 16; bold: true }
+                anchors {
+                    left: parent.left; leftMargin: 15
+                    verticalCenter: parent.verticalCenter
+                }
+            }
+            MouseArea {
+                anchors.fill: parent
+                onClicked: Qt.quit()
+            }
+        }
+    }
     ScrollBar { scrollArea: list; height: list.height; width: 8; anchors.right: window.right }
     Rectangle { x: 220; height: window.height; width: 1; color: "#cccccc" }
 }