diff options
author | Titta Heikkala <titta.heikkala@qt.io> | 2017-02-16 09:21:28 +0200 |
---|---|---|
committer | Maurice Kalinowski <maurice.kalinowski@qt.io> | 2017-02-16 07:29:23 +0000 |
commit | 90e26ea85564f22458dbec138e91e8078371f8b2 (patch) | |
tree | c23302440cb76ccf320ddf9e4313f908121ce8ba | |
parent | 08d742dca27bec71aca83b92e91be44e2d177827 (diff) |
iot-sensortag: Update the time
Add a timer to update the time.
Change-Id: I1ec817c15f4609c6c362481d2c5276b2dc167cca
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
-rw-r--r-- | tradeshow/iot-sensortag/resources/base/TopToolbar.qml | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tradeshow/iot-sensortag/resources/base/TopToolbar.qml b/tradeshow/iot-sensortag/resources/base/TopToolbar.qml index 85dcb69..eb94cb2 100644 --- a/tradeshow/iot-sensortag/resources/base/TopToolbar.qml +++ b/tradeshow/iot-sensortag/resources/base/TopToolbar.qml @@ -171,6 +171,13 @@ Item { anchors.bottom: parent.bottom } + Timer { + interval: 60000 // Update time once a minute + running: true + repeat: true + onTriggered: timeLabel.text = Qt.formatTime(new Date, "HH:mm") + } + Text { text: "UTC/GMT" color: "white" |