LoopPlugin: fix 'waiting for pump' display for SMB.

This commit is contained in:
Johannes Mockenhaupt 2018-03-19 12:07:28 +01:00
parent d1f1db859b
commit 706bb913e9
No known key found for this signature in database
GPG key ID: 9E1EA6AF7BBBB0D1

View file

@ -333,7 +333,10 @@ public class LoopPlugin implements PluginBase {
if (result.isChangeRequested()) {
final PumpEnactResult waiting = new PumpEnactResult();
waiting.queued = true;
lastRun.tbrSetByPump = waiting;
if (resultAfterConstraints.tempBasalRequested)
lastRun.tbrSetByPump = waiting;
if (resultAfterConstraints.bolusRequested)
lastRun.smbSetByPump = waiting;
MainApp.bus().post(new EventLoopUpdateGui());
FabricPrivacy.getInstance().logCustom(new CustomEvent("APSRequest"));
MainApp.getConfigBuilder().applyTBRRequest(resultAfterConstraints, profile, new Callback() {