diff --git a/app/src/main/java/info/nightscout/androidaps/plugins/IobCobCalculator/AutosensData.java b/app/src/main/java/info/nightscout/androidaps/plugins/IobCobCalculator/AutosensData.java index ea0ce7d4cb..6a651a5a79 100644 --- a/app/src/main/java/info/nightscout/androidaps/plugins/IobCobCalculator/AutosensData.java +++ b/app/src/main/java/info/nightscout/androidaps/plugins/IobCobCalculator/AutosensData.java @@ -28,6 +28,10 @@ import info.nightscout.utils.SP; public class AutosensData implements DataPointWithLabelInterface { private static Logger log = LoggerFactory.getLogger(AutosensData.class); + public void setChartTime(long chartTime) { + this.chartTime = chartTime; + } + static class CarbsInPast { long time = 0L; double carbs = 0d; @@ -52,6 +56,7 @@ public class AutosensData implements DataPointWithLabelInterface { } public long time = 0L; + long chartTime; public String pastSensitivity = ""; public double deviation = 0d; boolean nonCarbsDeviation = false; @@ -121,7 +126,7 @@ public class AutosensData implements DataPointWithLabelInterface { @Override public double getX() { - return time; + return chartTime; } @Override diff --git a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/graphData/GraphData.java b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/graphData/GraphData.java index 1bf59db4de..e3752a3861 100644 --- a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/graphData/GraphData.java +++ b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/graphData/GraphData.java @@ -385,6 +385,7 @@ public class GraphData { } if (autosensData.failoverToMinAbsorbtionRate) { autosensData.setScale(cobScale); + autosensData.setChartTime(time); minFailoverActiveList.add(autosensData); } }