summaryrefslogtreecommitdiff
path: root/metawatch/qml/com/javispedro
diff options
context:
space:
mode:
authorJavier S. Pedro <maemo@javispedro.com>2012-08-14 00:11:51 +0200
committerJavier S. Pedro <maemo@javispedro.com>2012-08-14 00:11:51 +0200
commit758cec1a767c056aaf9da36fd411cdf4a8fba32e (patch)
tree341cb8705e2e6c02d713860c8403ac8a3630a78a /metawatch/qml/com/javispedro
parent542d3489f45111aaca5514495af3847cf39e335b (diff)
downloadsowatch-758cec1a767c056aaf9da36fd411cdf4a8fba32e.tar.gz
sowatch-758cec1a767c056aaf9da36fd411cdf4a8fba32e.zip
rewrite live notifications handling using models
Diffstat (limited to 'metawatch/qml/com/javispedro')
-rw-r--r--metawatch/qml/com/javispedro/sowatch/metawatch/MWListView.qml11
1 files changed, 11 insertions, 0 deletions
diff --git a/metawatch/qml/com/javispedro/sowatch/metawatch/MWListView.qml b/metawatch/qml/com/javispedro/sowatch/metawatch/MWListView.qml
index 6af7b18..e16869f 100644
--- a/metawatch/qml/com/javispedro/sowatch/metawatch/MWListView.qml
+++ b/metawatch/qml/com/javispedro/sowatch/metawatch/MWListView.qml
@@ -67,6 +67,17 @@ ListView {
}
}
+ function scrollTop() {
+ if (count == 0) {
+ return;
+ }
+ if (selectable) {
+ currentIndex = 0;
+ }
+ positionViewAtIndex(0, ListView.Beginning);
+
+ }
+
Rectangle {
id: indicatorCont
visible: list.indicator && (list.contentHeight > list.height)