From fe0f2e3ce68ebdc257938c611bc5c95cb519c7a8 Mon Sep 17 00:00:00 2001 From: AdrianLxM Date: Thu, 3 May 2018 17:15:36 +0200 Subject: [PATCH] wearwizard settings on phone --- .../plugins/Wear/ActionStringHandler.java | 10 +++--- app/src/main/res/values/strings.xml | 7 ++++ app/src/main/res/xml/pref_wear.xml | 36 +++++++++++++++++++ 3 files changed, 48 insertions(+), 5 deletions(-) diff --git a/app/src/main/java/info/nightscout/androidaps/plugins/Wear/ActionStringHandler.java b/app/src/main/java/info/nightscout/androidaps/plugins/Wear/ActionStringHandler.java index 9f46e9e25c..5c0af35135 100644 --- a/app/src/main/java/info/nightscout/androidaps/plugins/Wear/ActionStringHandler.java +++ b/app/src/main/java/info/nightscout/androidaps/plugins/Wear/ActionStringHandler.java @@ -192,11 +192,11 @@ public class ActionStringHandler { return; } - boolean useBG = true; - boolean useBolusIOB = true; - boolean useBasalIOB = true; - boolean useCOB = true; - boolean useTrend = true; + boolean useBG = SP.getBoolean(R.string.key_wearwizard_bg, true); + boolean useBolusIOB = SP.getBoolean(R.string.key_wearwizard_bolusiob, true); + boolean useBasalIOB = SP.getBoolean(R.string.key_wearwizard_basaliob, true); + boolean useCOB = SP.getBoolean(R.string.key_wearwizard_cob, true); + boolean useTrend = SP.getBoolean(R.string.key_wearwizard_trend, false); int percentage = Integer.parseInt(act[2]); Profile profile = MainApp.getConfigBuilder().getProfile(); diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 84acd8205c..24b72693dc 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -1035,4 +1035,11 @@ Current basal safety multiplier n/a Autobackfill BG + Wizard settings + wearwizard_bg + wearwizard_trend + wearwizard_cob + wearwizard_bolusiob + wearwizard_basaliob + Calculations included in the Wizard result: diff --git a/app/src/main/res/xml/pref_wear.xml b/app/src/main/res/xml/pref_wear.xml index 0dce661482..a8f2255d05 100644 --- a/app/src/main/res/xml/pref_wear.xml +++ b/app/src/main/res/xml/pref_wear.xml @@ -13,6 +13,42 @@ android:summary="@string/wearcontrol_summary" android:title="@string/wearcontrol_title" /> + + + + + + + + + + + +