From d6184cc1519a465d1ff46bd0783179fd9832b242 Mon Sep 17 00:00:00 2001 From: AdrianLxM Date: Thu, 7 Jun 2018 22:44:09 +0200 Subject: [PATCH] Wizard: fully undo "ok" on constraints violation Fixes https://github.com/MilosKozak/AndroidAPS/issues/1056 --- .../androidaps/plugins/Overview/Dialogs/WizardDialog.java | 1 + 1 file changed, 1 insertion(+) diff --git a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Dialogs/WizardDialog.java b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Dialogs/WizardDialog.java index 36b777733a..303ca10949 100644 --- a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Dialogs/WizardDialog.java +++ b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Dialogs/WizardDialog.java @@ -315,6 +315,7 @@ public class WizardDialog extends DialogFragment implements OnClickListener, Com confirmMessage += "
" + MainApp.gs(R.string.carbs) + ": " + "" + carbsAfterConstraints + "g" + ""; if (insulinAfterConstraints - calculatedTotalInsulin != 0 || !carbsAfterConstraints.equals(calculatedCarbs)) { + okClicked = false; AlertDialog.Builder builder = new AlertDialog.Builder(context); builder.setTitle(MainApp.gs(R.string.treatmentdeliveryerror)); builder.setMessage(MainApp.gs(R.string.constraints_violation) + "\n" + MainApp.gs(R.string.changeyourinput));