summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArseniy Movshev <dodoradio@outlook.com>2023-07-02 11:50:08 +0100
committerArseniy Movshev <dodoradio@outlook.com>2023-07-02 11:56:32 +0100
commit4de0f35b44edc69732bb34d8250db7b0aaf38f0b (patch)
tree0d6a9e589213a8481cfef631f0d7fa2d1f6229b6
parentb3f7a6f1f54f6ab52f58b1fb77ea87115dd3531f (diff)
Add settings for preview display to UI settings page
-rw-r--r--src/settings/UiSettingsPage.qml26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/settings/UiSettingsPage.qml b/src/settings/UiSettingsPage.qml
index 8abea6c..2009ec6 100644
--- a/src/settings/UiSettingsPage.qml
+++ b/src/settings/UiSettingsPage.qml
@@ -18,6 +18,7 @@
import QtQuick 2.15
import org.asteroid.controls 1.0
+import Nemo.Configuration 1.0
import org.asteroid.sensorlogd 1.0
@@ -34,6 +35,31 @@ Item {
anchors.fill: parent
Item { width: parent.width; height: parent.width*0.2}
+ LabeledSwitch {
+ width: parent.width
+ height: width*0.25
+ text: "Show step count preview"
+ checked: stepsPreviewVisible.value
+ onCheckedChanged: stepsPreviewVisible.value = checked
+ }
+ LabeledSwitch {
+ width: parent.width
+ height: width*0.25
+ text: "Show heartrate preview"
+ checked: hrPreviewVisible.value
+ onCheckedChanged: hrPreviewVisible.value = checked
+ }
}
}
+
+ ConfigurationValue {
+ id: stepsPreviewVisible
+ key: "/org/asteroidos/health/ui/stepCounter/showpreview"
+ defaultValue: true
+ }
+ ConfigurationValue {
+ id: hrPreviewVisible
+ key: "/org/asteroidos/health/ui/heartrate/showpreview"
+ defaultValue: true
+ }
}