mirror of
https://github.com/oliexdev/openScale.git
synced 2025-09-01 12:23:15 +02:00
Move dependency handling to settings class
This way it can check dependencies in isEnabled() as well.
This commit is contained in:
@@ -16,9 +16,7 @@
|
||||
|
||||
package com.health.openscale.gui.fragments;
|
||||
|
||||
import android.content.SharedPreferences;
|
||||
import android.os.Bundle;
|
||||
import android.preference.PreferenceManager;
|
||||
import android.support.v4.app.Fragment;
|
||||
import android.text.Html;
|
||||
import android.view.LayoutInflater;
|
||||
@@ -67,7 +65,6 @@ public class StatisticsFragment extends Fragment implements FragmentUpdateListen
|
||||
private TableLayout tableMonthAveragesLayoutColumnA;
|
||||
private TableLayout tableMonthAveragesLayoutColumnB;
|
||||
|
||||
private SharedPreferences prefs;
|
||||
private ScaleUser currentScaleUser;
|
||||
private ScaleMeasurement lastScaleMeasurement;
|
||||
|
||||
@@ -78,8 +75,6 @@ public class StatisticsFragment extends Fragment implements FragmentUpdateListen
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
|
||||
statisticsView = inflater.inflate(R.layout.fragment_statistics, container, false);
|
||||
|
||||
prefs = PreferenceManager.getDefaultSharedPreferences(statisticsView.getContext());
|
||||
|
||||
txtGoalWeight = (TextView) statisticsView.findViewById(R.id.txtGoalWeight);
|
||||
txtGoalDiff = (TextView) statisticsView.findViewById(R.id.txtGoalDiff);
|
||||
txtGoalDayLeft = (TextView) statisticsView.findViewById(R.id.txtGoalDayLeft);
|
||||
@@ -110,9 +105,9 @@ public class StatisticsFragment extends Fragment implements FragmentUpdateListen
|
||||
|
||||
for (MeasurementView measurement : viewMeasurementsListWeek) {
|
||||
measurement.setEditMode(STATISTIC);
|
||||
measurement.updatePreferences(prefs);
|
||||
|
||||
if (measurement.isVisible()) {
|
||||
if (measurement.getSettings().isEnabled()) {
|
||||
measurement.setVisible(true);
|
||||
measurement.setPadding(-1, -1, -1, paddingBottom);
|
||||
if ((i % 2) == 0) {
|
||||
tableWeekAveragesLayoutColumnA.addView(measurement);
|
||||
@@ -138,9 +133,9 @@ public class StatisticsFragment extends Fragment implements FragmentUpdateListen
|
||||
|
||||
for (MeasurementView measurement : viewMeasurementsListMonth) {
|
||||
measurement.setEditMode(STATISTIC);
|
||||
measurement.updatePreferences(prefs);
|
||||
|
||||
if (measurement.isVisible()) {
|
||||
if (measurement.getSettings().isEnabled()) {
|
||||
measurement.setVisible(true);
|
||||
measurement.setPadding(-1, -1, -1, paddingBottom);
|
||||
if ((i % 2) == 0) {
|
||||
tableMonthAveragesLayoutColumnA.addView(measurement);
|
||||
|
@@ -93,9 +93,9 @@ public class MeasurementPreferences extends PreferenceFragment {
|
||||
Preference preference = new MeasurementOrderPreference(
|
||||
getActivity(), measurementCategory, measurement);
|
||||
preference.setKey(measurement.getSettings().getEnabledKey());
|
||||
preference.setDefaultValue(measurement.getSettings().isEnabled());
|
||||
preference.setDefaultValue(measurement.getSettings().isEnabledIgnoringDependencies());
|
||||
preference.setPersistent(true);
|
||||
preference.setEnabled(!measurement.getIsDisabledByDependency());
|
||||
preference.setEnabled(measurement.getSettings().areDependenciesEnabled());
|
||||
|
||||
Drawable icon = measurement.getIcon();
|
||||
icon.setColorFilter(measurement.getForegroundColor(), PorterDuff.Mode.SRC_IN);
|
||||
@@ -178,7 +178,11 @@ public class MeasurementPreferences extends PreferenceFragment {
|
||||
@Override
|
||||
public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
|
||||
persistBoolean(isChecked);
|
||||
setEnableOnDependants(isChecked);
|
||||
for (int i = 0; i < getParent().getPreferenceCount(); ++i) {
|
||||
MeasurementOrderPreference preference =
|
||||
(MeasurementOrderPreference) getParent().getPreference(i);
|
||||
preference.setEnabled(preference.measurement.getSettings().areDependenciesEnabled());
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -200,19 +204,6 @@ public class MeasurementPreferences extends PreferenceFragment {
|
||||
view.setOnDragListener(new onDragListener());
|
||||
}
|
||||
|
||||
private void setEnableOnDependants(boolean enable) {
|
||||
for (int i = 0; i < getParent().getPreferenceCount(); ++i) {
|
||||
MeasurementOrderPreference preference =
|
||||
(MeasurementOrderPreference) getParent().getPreference(i);
|
||||
for (String dep : preference.measurement.getDependencyKeys()) {
|
||||
if (dep.equals(measurement.getKey())) {
|
||||
preference.setEnabled(enable);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onDown(MotionEvent e) {
|
||||
return isEnabled();
|
||||
|
@@ -26,7 +26,6 @@ import com.health.openscale.core.evaluation.EvaluationSheet;
|
||||
|
||||
public class BMIMeasurementView extends FloatMeasurementView {
|
||||
public static final String KEY = "bmi";
|
||||
private static final String[] DEPENDENCY = {WeightMeasurementView.KEY};
|
||||
|
||||
public BMIMeasurementView(Context context) {
|
||||
super(context, context.getResources().getString(R.string.label_bmi), ContextCompat.getDrawable(context, R.drawable.ic_bmi));
|
||||
@@ -37,11 +36,6 @@ public class BMIMeasurementView extends FloatMeasurementView {
|
||||
return KEY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getDependencyKeys() {
|
||||
return DEPENDENCY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isEditable() {
|
||||
return false;
|
||||
|
@@ -28,7 +28,6 @@ import java.util.Locale;
|
||||
|
||||
public class BMRMeasurementView extends FloatMeasurementView {
|
||||
public static final String KEY = "bmr";
|
||||
private static final String[] DEPENDENCY = {WeightMeasurementView.KEY};
|
||||
|
||||
public BMRMeasurementView(Context context) {
|
||||
super(context, context.getResources().getString(R.string.label_bmr), ContextCompat.getDrawable(context, R.drawable.ic_bmr));
|
||||
@@ -39,11 +38,6 @@ public class BMRMeasurementView extends FloatMeasurementView {
|
||||
return KEY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getDependencyKeys() {
|
||||
return DEPENDENCY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isEditable() {
|
||||
return false;
|
||||
|
@@ -26,7 +26,6 @@ import com.health.openscale.core.evaluation.EvaluationSheet;
|
||||
|
||||
public class BoneMeasurementView extends FloatMeasurementView {
|
||||
public static final String KEY = "bone";
|
||||
private static final String[] DEPENDENCY = {};
|
||||
|
||||
public BoneMeasurementView(Context context) {
|
||||
super(context, context.getResources().getString(R.string.label_bone), ContextCompat.getDrawable(context, R.drawable.ic_bone));
|
||||
@@ -37,11 +36,6 @@ public class BoneMeasurementView extends FloatMeasurementView {
|
||||
return KEY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getDependencyKeys() {
|
||||
return DEPENDENCY;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected float getMeasurementValue(ScaleMeasurement measurement) {
|
||||
return measurement.getBone();
|
||||
|
@@ -27,7 +27,6 @@ import com.health.openscale.core.datatypes.ScaleMeasurement;
|
||||
|
||||
public class CommentMeasurementView extends MeasurementView {
|
||||
public static final String KEY = "comment";
|
||||
private static final String[] DEPENDENCY = {};
|
||||
|
||||
private String comment;
|
||||
|
||||
@@ -40,11 +39,6 @@ public class CommentMeasurementView extends MeasurementView {
|
||||
return KEY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getDependencyKeys() {
|
||||
return DEPENDENCY;
|
||||
}
|
||||
|
||||
private void setValue(String newComment, boolean callListener) {
|
||||
if (!newComment.equals(comment)) {
|
||||
comment = newComment;
|
||||
|
@@ -30,7 +30,6 @@ import java.util.Date;
|
||||
|
||||
public class DateMeasurementView extends MeasurementView {
|
||||
public static final String KEY = "date";
|
||||
private static final String[] DEPENDENCY = {};
|
||||
|
||||
private static DateFormat dateFormat = DateFormat.getDateInstance();
|
||||
private Date date;
|
||||
@@ -44,11 +43,6 @@ public class DateMeasurementView extends MeasurementView {
|
||||
return KEY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getDependencyKeys() {
|
||||
return DEPENDENCY;
|
||||
}
|
||||
|
||||
private void setValue(Date newDate, boolean callListener) {
|
||||
if (!newDate.equals(date)) {
|
||||
date = newDate;
|
||||
|
@@ -28,7 +28,6 @@ import com.health.openscale.core.evaluation.EvaluationSheet;
|
||||
|
||||
public class FatMeasurementView extends FloatMeasurementView {
|
||||
public static final String KEY = "fat";
|
||||
private static final String[] DEPENDENCY = {WeightMeasurementView.KEY};
|
||||
|
||||
public FatMeasurementView(Context context) {
|
||||
super(context, context.getResources().getString(R.string.label_fat), ContextCompat.getDrawable(context, R.drawable.ic_fat));
|
||||
@@ -39,11 +38,6 @@ public class FatMeasurementView extends FloatMeasurementView {
|
||||
return KEY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getDependencyKeys() {
|
||||
return DEPENDENCY;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean canConvertPercentageToAbsoluteWeight() {
|
||||
return true;
|
||||
|
@@ -26,7 +26,6 @@ import com.health.openscale.core.evaluation.EvaluationSheet;
|
||||
|
||||
public class HipMeasurementView extends FloatMeasurementView {
|
||||
public static final String KEY = "hip";
|
||||
private static final String[] DEPENDENCY = {};
|
||||
|
||||
public HipMeasurementView(Context context) {
|
||||
super(context, context.getResources().getString(R.string.label_hip), ContextCompat.getDrawable(context, R.drawable.ic_hip));
|
||||
@@ -37,11 +36,6 @@ public class HipMeasurementView extends FloatMeasurementView {
|
||||
return KEY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getDependencyKeys() {
|
||||
return DEPENDENCY;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected float getMeasurementValue(ScaleMeasurement measurement) {
|
||||
return measurement.getHip();
|
||||
|
@@ -28,7 +28,6 @@ import com.health.openscale.core.evaluation.EvaluationSheet;
|
||||
|
||||
public class LBWMeasurementView extends FloatMeasurementView {
|
||||
public static final String KEY = "lbw";
|
||||
private static final String[] DEPENDENCY = {};
|
||||
|
||||
public LBWMeasurementView(Context context) {
|
||||
super(context, context.getResources().getString(R.string.label_lbw), ContextCompat.getDrawable(context, R.drawable.ic_lbw));
|
||||
@@ -39,11 +38,6 @@ public class LBWMeasurementView extends FloatMeasurementView {
|
||||
return KEY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getDependencyKeys() {
|
||||
return DEPENDENCY;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected float getMeasurementValue(ScaleMeasurement measurement) {
|
||||
return measurement.getLbw();
|
||||
|
@@ -24,7 +24,6 @@ import android.graphics.drawable.Drawable;
|
||||
import android.os.Bundle;
|
||||
import android.preference.PreferenceManager;
|
||||
import android.preference.PreferenceScreen;
|
||||
import android.support.annotation.CallSuper;
|
||||
import android.support.v4.content.ContextCompat;
|
||||
import android.text.SpannableStringBuilder;
|
||||
import android.text.TextUtils;
|
||||
@@ -78,7 +77,6 @@ public abstract class MeasurementView extends TableLayout {
|
||||
private MeasurementViewUpdateListener updateListener = null;
|
||||
private MeasurementViewMode measurementMode = VIEW;
|
||||
|
||||
private boolean isDisabledByDependency = false;
|
||||
private boolean updateViews = true;
|
||||
|
||||
public MeasurementView(Context context, String text, Drawable icon) {
|
||||
@@ -150,7 +148,7 @@ public abstract class MeasurementView extends TableLayout {
|
||||
}
|
||||
|
||||
for (MeasurementView measurement : sorted) {
|
||||
measurement.updatePreferences(prefs);
|
||||
measurement.setVisible(measurement.getSettings().isEnabled());
|
||||
}
|
||||
|
||||
return sorted;
|
||||
@@ -247,7 +245,6 @@ public abstract class MeasurementView extends TableLayout {
|
||||
}
|
||||
|
||||
public abstract String getKey();
|
||||
public abstract String[] getDependencyKeys();
|
||||
|
||||
public MeasurementViewSettings getSettings() {
|
||||
if (settings == null) {
|
||||
@@ -264,21 +261,6 @@ public abstract class MeasurementView extends TableLayout {
|
||||
public abstract void restoreState(Bundle state);
|
||||
public abstract void saveState(Bundle state);
|
||||
|
||||
@CallSuper
|
||||
public void updatePreferences(SharedPreferences prefs) {
|
||||
isDisabledByDependency = false;
|
||||
for (String dep : getDependencyKeys()) {
|
||||
MeasurementViewSettings depSettings = new MeasurementViewSettings(prefs, dep);
|
||||
if (!depSettings.isEnabled()) {
|
||||
isDisabledByDependency = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
boolean enable = !isDisabledByDependency && getSettings().isEnabled();
|
||||
setVisible(enable);
|
||||
}
|
||||
|
||||
public CharSequence getName() { return nameView.getText(); }
|
||||
public abstract String getValueAsString();
|
||||
public void appendDiffValue(SpannableStringBuilder builder) { }
|
||||
@@ -357,11 +339,7 @@ public abstract class MeasurementView extends TableLayout {
|
||||
showEvaluatorRow(false);
|
||||
}
|
||||
|
||||
public boolean getIsDisabledByDependency() {
|
||||
return isDisabledByDependency;
|
||||
}
|
||||
|
||||
protected void setVisible(boolean isVisible) {
|
||||
public void setVisible(boolean isVisible) {
|
||||
if (isVisible) {
|
||||
measurementRow.setVisibility(View.VISIBLE);
|
||||
} else {
|
||||
@@ -515,4 +493,3 @@ public abstract class MeasurementView extends TableLayout {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -45,9 +45,12 @@ public class MeasurementViewSettings {
|
||||
return getPreferenceKey(PREFERENCE_SUFFIX_ENABLE);
|
||||
}
|
||||
|
||||
public boolean isEnabled() {
|
||||
public boolean isEnabledIgnoringDependencies() {
|
||||
boolean defaultValue;
|
||||
switch (key) {
|
||||
case WeightMeasurementView.KEY:
|
||||
// Weight can't be disabled
|
||||
return true;
|
||||
case LBWMeasurementView.KEY:
|
||||
case BoneMeasurementView.KEY:
|
||||
case WaistMeasurementView.KEY:
|
||||
@@ -61,6 +64,41 @@ public class MeasurementViewSettings {
|
||||
return preferences.getBoolean(getEnabledKey(), defaultValue);
|
||||
}
|
||||
|
||||
private boolean isDependencyEnabled(String dependencyKey) {
|
||||
// Weight can't be disabled
|
||||
if (dependencyKey.equals(WeightMeasurementView.KEY)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return (new MeasurementViewSettings(preferences, dependencyKey)).isEnabled();
|
||||
}
|
||||
|
||||
public boolean areDependenciesEnabled() {
|
||||
switch (key) {
|
||||
case BMIMeasurementView.KEY:
|
||||
case BMRMeasurementView.KEY:
|
||||
return isDependencyEnabled(WeightMeasurementView.KEY);
|
||||
|
||||
// Requires weight as they are stored as percentage of it
|
||||
case FatMeasurementView.KEY:
|
||||
case MuscleMeasurementView.KEY:
|
||||
case WaterMeasurementView.KEY:
|
||||
return isDependencyEnabled(WeightMeasurementView.KEY);
|
||||
|
||||
case WHRMeasurementView.KEY:
|
||||
return isDependencyEnabled(HipMeasurementView.KEY)
|
||||
&& isDependencyEnabled(WaistMeasurementView.KEY);
|
||||
|
||||
case WHtRMeasurementView.KEY:
|
||||
return isDependencyEnabled(WaistMeasurementView.KEY);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
public boolean isEnabled() {
|
||||
return isEnabledIgnoringDependencies() && areDependenciesEnabled();
|
||||
}
|
||||
|
||||
public String getInOverviewGraphKey() {
|
||||
return getPreferenceKey(PREFERENCE_SUFFIX_IN_OVERVIEW_GRAPH);
|
||||
}
|
||||
|
@@ -26,7 +26,6 @@ import com.health.openscale.core.evaluation.EvaluationSheet;
|
||||
|
||||
public class MuscleMeasurementView extends FloatMeasurementView {
|
||||
public static final String KEY = "muscle";
|
||||
private static final String[] DEPENDENCY = {WeightMeasurementView.KEY};
|
||||
|
||||
public MuscleMeasurementView(Context context) {
|
||||
super(context, context.getResources().getString(R.string.label_muscle), ContextCompat.getDrawable(context, R.drawable.ic_muscle));
|
||||
@@ -37,11 +36,6 @@ public class MuscleMeasurementView extends FloatMeasurementView {
|
||||
return KEY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getDependencyKeys() {
|
||||
return DEPENDENCY;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean canConvertPercentageToAbsoluteWeight() {
|
||||
return true;
|
||||
|
@@ -30,7 +30,6 @@ import java.util.Date;
|
||||
|
||||
public class TimeMeasurementView extends MeasurementView {
|
||||
public static final String KEY = "time";
|
||||
private static final String[] DEPENDENCY = {};
|
||||
|
||||
private DateFormat timeFormat;
|
||||
private Date time;
|
||||
@@ -45,11 +44,6 @@ public class TimeMeasurementView extends MeasurementView {
|
||||
return KEY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getDependencyKeys() {
|
||||
return DEPENDENCY;
|
||||
}
|
||||
|
||||
private void setValue(Date newTime, boolean callListener) {
|
||||
if (!newTime.equals(time)) {
|
||||
time = newTime;
|
||||
|
@@ -26,7 +26,6 @@ import com.health.openscale.core.evaluation.EvaluationSheet;
|
||||
|
||||
public class WHRMeasurementView extends FloatMeasurementView {
|
||||
public static final String KEY = "whr";
|
||||
private static final String[] DEPENDENCY = {HipMeasurementView.KEY, WaistMeasurementView.KEY};
|
||||
|
||||
public WHRMeasurementView(Context context) {
|
||||
super(context, context.getResources().getString(R.string.label_whr), ContextCompat.getDrawable(context, R.drawable.ic_whr));
|
||||
@@ -37,11 +36,6 @@ public class WHRMeasurementView extends FloatMeasurementView {
|
||||
return KEY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getDependencyKeys() {
|
||||
return DEPENDENCY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isEditable() {
|
||||
return false;
|
||||
|
@@ -26,7 +26,6 @@ import com.health.openscale.core.evaluation.EvaluationSheet;
|
||||
|
||||
public class WHtRMeasurementView extends FloatMeasurementView {
|
||||
public static final String KEY = "whtr";
|
||||
private static final String[] DEPENDENCY = {WaistMeasurementView.KEY};
|
||||
|
||||
public WHtRMeasurementView(Context context) {
|
||||
super(context, context.getResources().getString(R.string.label_whtr), ContextCompat.getDrawable(context, R.drawable.ic_whtr));
|
||||
@@ -37,11 +36,6 @@ public class WHtRMeasurementView extends FloatMeasurementView {
|
||||
return KEY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getDependencyKeys() {
|
||||
return DEPENDENCY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isEditable() {
|
||||
return false;
|
||||
|
@@ -26,7 +26,6 @@ import com.health.openscale.core.evaluation.EvaluationSheet;
|
||||
|
||||
public class WaistMeasurementView extends FloatMeasurementView {
|
||||
public static final String KEY = "waist";
|
||||
private static final String[] DEPENDENCY = {};
|
||||
|
||||
public WaistMeasurementView(Context context) {
|
||||
super(context, context.getResources().getString(R.string.label_waist), ContextCompat.getDrawable(context, R.drawable.ic_waist));
|
||||
@@ -37,11 +36,6 @@ public class WaistMeasurementView extends FloatMeasurementView {
|
||||
return KEY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getDependencyKeys() {
|
||||
return DEPENDENCY;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected float getMeasurementValue(ScaleMeasurement measurement) {
|
||||
return measurement.getWaist();
|
||||
|
@@ -28,7 +28,6 @@ import com.health.openscale.core.evaluation.EvaluationSheet;
|
||||
|
||||
public class WaterMeasurementView extends FloatMeasurementView {
|
||||
public static final String KEY = "water";
|
||||
private static final String[] DEPENDENCY = {WeightMeasurementView.KEY};
|
||||
|
||||
public WaterMeasurementView(Context context) {
|
||||
super(context, context.getResources().getString(R.string.label_water), ContextCompat.getDrawable(context, R.drawable.ic_water));
|
||||
@@ -39,11 +38,6 @@ public class WaterMeasurementView extends FloatMeasurementView {
|
||||
return KEY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getDependencyKeys() {
|
||||
return DEPENDENCY;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean canConvertPercentageToAbsoluteWeight() {
|
||||
return true;
|
||||
|
@@ -27,7 +27,6 @@ import com.health.openscale.core.utils.Converters;
|
||||
|
||||
public class WeightMeasurementView extends FloatMeasurementView {
|
||||
public static final String KEY = "weight";
|
||||
private static final String[] DEPENDENCY = {};
|
||||
|
||||
public WeightMeasurementView(Context context) {
|
||||
super(context, context.getResources().getString(R.string.label_weight), ContextCompat.getDrawable(context, R.drawable.ic_weight));
|
||||
@@ -38,11 +37,6 @@ public class WeightMeasurementView extends FloatMeasurementView {
|
||||
return KEY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getDependencyKeys() {
|
||||
return DEPENDENCY;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected float getMeasurementValue(ScaleMeasurement measurement) {
|
||||
return measurement.getConvertedWeight(getScaleUser().getScaleUnit());
|
||||
|
Reference in New Issue
Block a user