diff --git a/app/src/main/java/com/faltenreich/diaguard/feature/entry/edit/EntryEditFragment.java b/app/src/main/java/com/faltenreich/diaguard/feature/entry/edit/EntryEditFragment.java index 4d01221cf..c111505dc 100644 --- a/app/src/main/java/com/faltenreich/diaguard/feature/entry/edit/EntryEditFragment.java +++ b/app/src/main/java/com/faltenreich/diaguard/feature/entry/edit/EntryEditFragment.java @@ -257,6 +257,7 @@ private void initData() { private void setEntry(@NonNull Entry entry) { noteInput.setText(entry.getNote()); + // FIXME: Previous order gets ignored on Fragment recreation List measurements = entry.getMeasurementCache(); if (measurements != null && !measurements.isEmpty()) { Collections.sort(measurements, CategoryComparatorFactory.getInstance().createComparatorFromMeasurements()); @@ -557,7 +558,6 @@ private void deleteEntry() { } } - // FIXME: Adds previously deleted food when adding another one private List getFoodEaten() { for (int index = 0; index < measurementContainer.getChildCount(); index++) { View view = measurementContainer.getChildAt(index); diff --git a/app/src/main/java/com/faltenreich/diaguard/feature/food/input/FoodInputView.java b/app/src/main/java/com/faltenreich/diaguard/feature/food/input/FoodInputView.java index 1d072c6fb..4c65521a6 100644 --- a/app/src/main/java/com/faltenreich/diaguard/feature/food/input/FoodInputView.java +++ b/app/src/main/java/com/faltenreich/diaguard/feature/food/input/FoodInputView.java @@ -172,10 +172,10 @@ public Meal getMeal() { return meal; } - // FIXME: Previously cached but removed food eaten gets added obsoletely public void setMeal(Meal meal) { this.meal = meal; this.inputValueInputField.setText(meal.getValuesForUI()[0]); + // FIXME: Previously cached but removed food eaten gets added obsoletely if (meal.getFoodEatenCache().isEmpty()) { addItems(meal.getFoodEaten()); } else {