Clean up prediction colors.
This commit is contained in:
parent
73d7d98354
commit
5ef7506e5f
9 changed files with 3 additions and 30 deletions
|
@ -211,7 +211,7 @@ public class BgReading implements DataPointWithLabelInterface {
|
|||
}
|
||||
int color = MainApp.sResources.getColor(R.color.inrange);
|
||||
if (isPrediction())
|
||||
color = MainApp.sResources.getColor(R.color.prediction);
|
||||
return getPredectionColor();
|
||||
else if (valueToUnits(units) < lowLine)
|
||||
color = MainApp.sResources.getColor(R.color.low);
|
||||
else if (valueToUnits(units) > highLine)
|
||||
|
@ -219,8 +219,7 @@ public class BgReading implements DataPointWithLabelInterface {
|
|||
return color;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getSecondColor() {
|
||||
private int getPredectionColor() {
|
||||
if (isIOBPrediction)
|
||||
return MainApp.sResources.getColor(R.color.iob);
|
||||
if (isCOBPrediction)
|
||||
|
|
|
@ -263,9 +263,4 @@ public class CareportalEvent implements DataPointWithLabelInterface {
|
|||
return Color.GRAY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getSecondColor() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -297,8 +297,4 @@ public class ExtendedBolus implements Interval, DataPointWithLabelInterface {
|
|||
return Color.CYAN;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getSecondColor() {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -263,11 +263,6 @@ public class ProfileSwitch implements Interval, DataPointWithLabelInterface {
|
|||
return Color.CYAN;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getSecondColor() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return "ProfileSwitch{" +
|
||||
"date=" + date +
|
||||
|
|
|
@ -164,9 +164,4 @@ public class AutosensData implements DataPointWithLabelInterface {
|
|||
return MainApp.gc(R.color.cob);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getSecondColor() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -55,5 +55,4 @@ public interface DataPointWithLabelInterface extends DataPointInterface{
|
|||
PointsWithLabelGraphSeries.Shape getShape();
|
||||
float getSize();
|
||||
int getColor();
|
||||
int getSecondColor();
|
||||
}
|
||||
|
|
|
@ -211,7 +211,6 @@ public class PointsWithLabelGraphSeries<E extends DataPointWithLabelInterface> e
|
|||
mPaint.setStyle(Paint.Style.FILL);
|
||||
mPaint.setStrokeWidth(0);
|
||||
canvas.drawCircle(endX, endY, scaledPxSize, mPaint);
|
||||
mPaint.setColor(value.getSecondColor());
|
||||
mPaint.setStyle(Paint.Style.FILL);
|
||||
mPaint.setStrokeWidth(0);
|
||||
canvas.drawCircle(endX, endY, scaledPxSize / 3, mPaint);
|
||||
|
|
|
@ -193,11 +193,6 @@ public class Treatment implements DataPointWithLabelInterface {
|
|||
return MainApp.instance().getResources().getColor(android.R.color.holo_red_light);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getSecondColor() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setY(double y) {
|
||||
yValue = y;
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<color name="bolus">#FFFFCC03</color>
|
||||
<color name="cob">#FFFB8C00</color>
|
||||
<color name="uam">#ffea00</color>
|
||||
<color name="zt">#ff9500</color>
|
||||
<color name="zt">#00ffff</color>
|
||||
<color name="ratio">#FFFFFF</color>
|
||||
<color name="devslopepos">#FFFFFF00</color>
|
||||
<color name="devslopeneg">#FFFF00FF</color>
|
||||
|
|
Loading…
Reference in a new issue