summaryrefslogtreecommitdiff
path: root/liveview/qml
diff options
context:
space:
mode:
authorJavier S. Pedro <maemo@javispedro.com>2013-07-07 13:50:28 +0200
committerJavier S. Pedro <maemo@javispedro.com>2013-07-07 13:50:28 +0200
commitf61dfc6557303a8bba5301927f42e5b2a7ffcac6 (patch)
treefdba31b412015684d46c7a3cb070b8a57ff37ef4 /liveview/qml
parent92475d094cfddf7dd3036f5f1a9d6845a83ee350 (diff)
downloadsowatch-f61dfc6557303a8bba5301927f42e5b2a7ffcac6.tar.gz
sowatch-f61dfc6557303a8bba5301927f42e5b2a7ffcac6.zip
add some notification support to liveview
Diffstat (limited to 'liveview/qml')
-rw-r--r--liveview/qml/com/javispedro/sowatch/liveview/LVPage.qml7
-rw-r--r--liveview/qml/com/javispedro/sowatch/liveview/qmldir2
-rw-r--r--liveview/qml/liveview-config.qml53
3 files changed, 62 insertions, 0 deletions
diff --git a/liveview/qml/com/javispedro/sowatch/liveview/LVPage.qml b/liveview/qml/com/javispedro/sowatch/liveview/LVPage.qml
new file mode 100644
index 0000000..f3eaf96
--- /dev/null
+++ b/liveview/qml/com/javispedro/sowatch/liveview/LVPage.qml
@@ -0,0 +1,7 @@
+import Qt 4.7
+
+Rectangle {
+ width: 128
+ height: 128
+ color: "black"
+}
diff --git a/liveview/qml/com/javispedro/sowatch/liveview/qmldir b/liveview/qml/com/javispedro/sowatch/liveview/qmldir
new file mode 100644
index 0000000..82dc2a2
--- /dev/null
+++ b/liveview/qml/com/javispedro/sowatch/liveview/qmldir
@@ -0,0 +1,2 @@
+LVPage 1.0 LVPage.qml
+LVLabel 1.0 LVLabel.qml
diff --git a/liveview/qml/liveview-config.qml b/liveview/qml/liveview-config.qml
new file mode 100644
index 0000000..f6c84b0
--- /dev/null
+++ b/liveview/qml/liveview-config.qml
@@ -0,0 +1,53 @@
+import QtQuick 1.1
+import com.nokia.meego 1.1
+import com.javispedro.sowatch 1.0
+
+Column {
+ property string configKey;
+
+ Item {
+ id: hourModeItem
+ width: parent.width
+ height: UiConstants.ListItemHeightDefault
+
+ GConfKey {
+ id: hourModeKey
+ key: configKey + "/24h-mode"
+ }
+ MouseArea {
+ id: hourModeArea
+ anchors.fill: parent
+ onClicked: hourModeSelect.open();
+ }
+ SelectionDialog {
+ id: hourModeSelect
+ titleText: qsTr("Time format")
+ selectedIndex: hourModeKey.value ? 1 : 0
+ model: ListModel {
+ ListElement { name: QT_TR_NOOP("12 hour") }
+ ListElement { name: QT_TR_NOOP("24 hour") }
+ }
+ onSelectedIndexChanged: hourModeKey.value = selectedIndex == 1
+ }
+ Column {
+ anchors.verticalCenter: parent.verticalCenter
+ anchors.left: parent.left
+
+ Label {
+ text: qsTr("Time format")
+ font: UiConstants.TitleFont
+ }
+
+ Label {
+ text: qsTr(hourModeSelect.model.get(hourModeSelect.selectedIndex).name)
+ font: UiConstants.FieldLabelFont
+ color: UiConstants.FieldLabelColor
+ }
+ }
+ Image {
+ anchors.verticalCenter: parent.verticalCenter
+ anchors.right: parent.right
+ source: "image://theme/meegotouch-combobox-indicator" + (theme.inverted ? "-inverted" : "")
+ }
+ }
+}