From 1747034feba274292cc9acfde21a1576d59a11a9 Mon Sep 17 00:00:00 2001 From: Arseniy Movshev Date: Sun, 2 Jul 2023 16:12:55 +0100 Subject: Add weight graph and preview The weight data collection is manual, so we need a page for the user to input data, hence this commit isn't sufficient for a weight logging implementation on its own. Weight doesn't have a dataChanged signal in sensorlogd, so that's currently not implemented here either Because weight tracking isn't for everyone, the preview isn't shown by default. --- src/settings/UiSettingsPage.qml | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'src/settings') diff --git a/src/settings/UiSettingsPage.qml b/src/settings/UiSettingsPage.qml index 2009ec6..c349db7 100644 --- a/src/settings/UiSettingsPage.qml +++ b/src/settings/UiSettingsPage.qml @@ -49,6 +49,13 @@ Item { checked: hrPreviewVisible.value onCheckedChanged: hrPreviewVisible.value = checked } + LabeledSwitch { + width: parent.width + height: width*0.25 + text: "Show weight preview" + checked: weightPreviewVisible.value + onCheckedChanged: weightPreviewVisible.value = checked + } } } @@ -62,4 +69,9 @@ Item { key: "/org/asteroidos/health/ui/heartrate/showpreview" defaultValue: true } + ConfigurationValue { + id: weightPreviewVisible + key: "/org/asteroidos/health/ui/weight/showpreview" + defaultValue: true + } } -- cgit v1.2.3-70-g09d2