From 010a2f3fd836834533e32a2ad8b1021b93a3ba0b Mon Sep 17 00:00:00 2001 From: swissalpine Date: Fri, 4 May 2018 10:04:45 +0200 Subject: [PATCH 1/3] Make deviation bars transparent --- .../androidaps/plugins/Overview/graphData/GraphData.java | 6 +++--- app/src/main/res/values/colors.xml | 4 ++++ 2 files changed, 7 insertions(+), 3 deletions(-) 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 177e7f9642..837a24d8aa 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 @@ -437,9 +437,9 @@ public class GraphData { AutosensData autosensData = IobCobCalculatorPlugin.getPlugin().getAutosensData(time); if (autosensData != null) { int color = Color.BLACK; // "=" - if (autosensData.pastSensitivity.equals("C")) color = Color.GRAY; - if (autosensData.pastSensitivity.equals("+")) color = Color.GREEN; - if (autosensData.pastSensitivity.equals("-")) color = Color.RED; + if (autosensData.pastSensitivity.equals("C")) color = MainApp.gc(R.color.deviationgrey); + if (autosensData.pastSensitivity.equals("+")) color = MainApp.gc(R.color.deviationgreen); + if (autosensData.pastSensitivity.equals("-")) color = MainApp.gc(R.color.deviationred); devArray.add(new DeviationDataPoint(time, autosensData.deviation, color, devScale)); maxDevValueFound = Math.max(maxDevValueFound, Math.abs(autosensData.deviation)); } diff --git a/app/src/main/res/values/colors.xml b/app/src/main/res/values/colors.xml index a5e65e2eda..02d39fe91c 100644 --- a/app/src/main/res/values/colors.xml +++ b/app/src/main/res/values/colors.xml @@ -64,4 +64,8 @@ #ff827c #009705 + #FF666666 + #7200FF00 + #72FF0000 + From 7312bf061adf5cb975f30703a24143a19f57f0e4 Mon Sep 17 00:00:00 2001 From: swissalpine Date: Fri, 4 May 2018 12:30:28 +0200 Subject: [PATCH 2/3] Update colors.xml --- app/src/main/res/values/colors.xml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/src/main/res/values/colors.xml b/app/src/main/res/values/colors.xml index 02d39fe91c..954184de6a 100644 --- a/app/src/main/res/values/colors.xml +++ b/app/src/main/res/values/colors.xml @@ -64,8 +64,9 @@ #ff827c #009705 - #FF666666 + #c8666666 #7200FF00 #72FF0000 + #72000000 From 10b67a0c11e3160dc70533e8007e048fe38f3b3c Mon Sep 17 00:00:00 2001 From: swissalpine Date: Fri, 4 May 2018 12:31:11 +0200 Subject: [PATCH 3/3] Update GraphData.java --- .../androidaps/plugins/Overview/graphData/GraphData.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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 837a24d8aa..8023e86ac0 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 @@ -436,7 +436,7 @@ public class GraphData { for (long time = fromTime; time <= toTime; time += 5 * 60 * 1000L) { AutosensData autosensData = IobCobCalculatorPlugin.getPlugin().getAutosensData(time); if (autosensData != null) { - int color = Color.BLACK; // "=" + int color = MainApp.gc(R.color.deviationblack); // "=" if (autosensData.pastSensitivity.equals("C")) color = MainApp.gc(R.color.deviationgrey); if (autosensData.pastSensitivity.equals("+")) color = MainApp.gc(R.color.deviationgreen); if (autosensData.pastSensitivity.equals("-")) color = MainApp.gc(R.color.deviationred);