Insight: add treatment to progress event

This commit is contained in:
AdrianLxM 2018-03-11 20:56:11 +01:00 committed by GitHub
parent ccabb099f0
commit 3068089297
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -497,7 +497,10 @@ public class InsightPumpPlugin implements PluginBase, PumpInterface, Constraints
if (result.success) {
log("Success!");
Treatment t = new Treatment();
t.isSMB = detailedBolusInfo.isSMB;
final EventOverviewBolusProgress bolusingEvent = EventOverviewBolusProgress.getInstance();
bolusingEvent.t = t;
bolusingEvent.status = String.format(MainApp.sResources.getString(R.string.bolusdelivered), detailedBolusInfo.insulin);
bolusingEvent.percent = 100;
MainApp.bus().post(bolusingEvent);