From c8385121987089af08ad95d28514af4b6dc13603 Mon Sep 17 00:00:00 2001 From: "Javier S. Pedro" Date: Sat, 4 May 2013 01:46:06 +0200 Subject: add basic support for settings pages --- sowatchui/qml/WatchPage.qml | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'sowatchui/qml') diff --git a/sowatchui/qml/WatchPage.qml b/sowatchui/qml/WatchPage.qml index 4799085..8d623a6 100644 --- a/sowatchui/qml/WatchPage.qml +++ b/sowatchui/qml/WatchPage.qml @@ -44,6 +44,7 @@ Page { Menu { id: watchletMenu property string watchlet; + property url watchletConfigQmlUrl; MenuLayout { MenuItem { text: qsTr("Move up") @@ -53,6 +54,11 @@ Page { text: qsTr("Move down") onClicked: watchletsModel.moveWatchletDown(watchletMenu.watchlet) } + MenuItem { + text: qsTr("Configure watchlet...") + onClicked: pageStack.push(watchletMenu.watchletConfigQmlUrl, {'configKey': configKey}) + visible: watchletMenu.watchletConfigQmlUrl != "" + } MenuItem { text: qsTr("Remove watchlet") onClicked: watchletsModel.removeWatchlet(watchletMenu.watchlet) @@ -161,6 +167,7 @@ Page { delegate: ListDelegate { onClicked: { watchletMenu.watchlet = model.name; + watchletMenu.watchletConfigQmlUrl = model.configQmlUrl; watchletMenu.open(); } } -- cgit v1.2.3