From 7876aa81472ac2f75b070670f98f7591f175bf22 Mon Sep 17 00:00:00 2001 From: micrusa Date: Wed, 29 Apr 2020 14:53:11 +0200 Subject: [PATCH] Now using showSeekBarValue instead of putting it on summary Signed-off-by: micrusa --- .../me/micrusa/amaztimer/activities/SettingsActivity.java | 2 -- app/src/main/res/xml/root_preferences.xml | 7 ++++--- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/app/src/main/java/me/micrusa/amaztimer/activities/SettingsActivity.java b/app/src/main/java/me/micrusa/amaztimer/activities/SettingsActivity.java index e5f60c64..f898ed5b 100644 --- a/app/src/main/java/me/micrusa/amaztimer/activities/SettingsActivity.java +++ b/app/src/main/java/me/micrusa/amaztimer/activities/SettingsActivity.java @@ -58,11 +58,9 @@ public boolean onPreferenceChange(Preference preference, Object newValue) { break; case "age": bodyFile.set(defValues.sAge, (int) newValue); - preference.setSummary(newValue.toString()); break; case "weight": bodyFile.set(defValues.sWeight, (int) newValue); - preference.setSummary(newValue.toString() + "Kg"); break; case "huamiactivity": file.set(defValues.sLongPrepare, (Boolean) newValue); diff --git a/app/src/main/res/xml/root_preferences.xml b/app/src/main/res/xml/root_preferences.xml index a22129ae..b6b2eec0 100644 --- a/app/src/main/res/xml/root_preferences.xml +++ b/app/src/main/res/xml/root_preferences.xml @@ -48,14 +48,15 @@ android:defaultValue="70" android:key="weight" android:max="150" - android:summary="70" - android:title="@string/weight" /> + android:summary="Kg" + android:title="@string/weight" + app:showSeekBarValue="true"/>