Bolus command: ensure the progress dialog is always closed.
This commit is contained in:
parent
454cb49ec5
commit
34861960ea
|
@ -406,6 +406,9 @@ public class ComboPlugin implements PluginBase, PumpInterface {
|
|||
case STOPPED:
|
||||
event.status = MainApp.sResources.getString(R.string.bolusstopped);
|
||||
break;
|
||||
default:
|
||||
// no state, just percent below
|
||||
break;
|
||||
}
|
||||
event.percent = percent;
|
||||
MainApp.bus().post(event);
|
||||
|
|
|
@ -208,6 +208,8 @@ public class BolusCommand extends BaseCommand {
|
|||
.history(new PumpHistory().bolusHistory(boluses));
|
||||
} catch (CommandException e) {
|
||||
return e.toCommandResult();
|
||||
} finally {
|
||||
bolusProgressReporter.report(null, 100, 0);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue