Merge branch 'pull/2185' into dev
This commit is contained in:
commit
f537c0090a
4 changed files with 6 additions and 3 deletions
|
@ -100,8 +100,8 @@ public class CareportalEvent implements DataPointWithLabelInterface, Interval {
|
||||||
String hours = " " + MainApp.gs(R.string.hours) + " ";
|
String hours = " " + MainApp.gs(R.string.hours) + " ";
|
||||||
|
|
||||||
if (useShortText) {
|
if (useShortText) {
|
||||||
days = "d";
|
days = MainApp.gs(R.string.shortday);
|
||||||
hours = "h";
|
hours = MainApp.gs(R.string.shorthour);
|
||||||
}
|
}
|
||||||
|
|
||||||
return diff.get(TimeUnit.DAYS) + days + diff.get(TimeUnit.HOURS) + hours;
|
return diff.get(TimeUnit.DAYS) + days + diff.get(TimeUnit.HOURS) + hours;
|
||||||
|
|
|
@ -185,7 +185,7 @@ public class DateUtil {
|
||||||
long remainingTimeMinutes = timeInMillis / (1000 * 60);
|
long remainingTimeMinutes = timeInMillis / (1000 * 60);
|
||||||
long remainingTimeHours = remainingTimeMinutes / 60;
|
long remainingTimeHours = remainingTimeMinutes / 60;
|
||||||
remainingTimeMinutes = remainingTimeMinutes % 60;
|
remainingTimeMinutes = remainingTimeMinutes % 60;
|
||||||
return "(" + ((remainingTimeHours > 0) ? (remainingTimeHours + "h ") : "") + remainingTimeMinutes + "')";
|
return "(" + ((remainingTimeHours > 0) ? (remainingTimeHours + MainApp.gs(R.string.shorthour) + " ") : "") + remainingTimeMinutes + "')";
|
||||||
}
|
}
|
||||||
|
|
||||||
public static String sinceString(long timestamp) {
|
public static String sinceString(long timestamp) {
|
||||||
|
|
|
@ -778,6 +778,7 @@
|
||||||
<string name="shortgramm">g</string>
|
<string name="shortgramm">g</string>
|
||||||
<string name="shortminute">m</string>
|
<string name="shortminute">m</string>
|
||||||
<string name="shorthour">h</string>
|
<string name="shorthour">h</string>
|
||||||
|
<string name="shortday">d</string>
|
||||||
<string name="none"><![CDATA[<none>]]></string>
|
<string name="none"><![CDATA[<none>]]></string>
|
||||||
<string name="shortkilojoul">kJ</string>
|
<string name="shortkilojoul">kJ</string>
|
||||||
<string name="shortenergy">En</string>
|
<string name="shortenergy">En</string>
|
||||||
|
|
|
@ -107,6 +107,8 @@ public class AAPSMocker {
|
||||||
when(MainApp.gs(R.string.configbuilder_insulin)).thenReturn("Insulin");
|
when(MainApp.gs(R.string.configbuilder_insulin)).thenReturn("Insulin");
|
||||||
when(MainApp.gs(R.string.bolusdelivering)).thenReturn("Delivering 0.0U");
|
when(MainApp.gs(R.string.bolusdelivering)).thenReturn("Delivering 0.0U");
|
||||||
when(MainApp.gs(R.string.profile_per_unit)).thenReturn("/U");
|
when(MainApp.gs(R.string.profile_per_unit)).thenReturn("/U");
|
||||||
|
when(MainApp.gs(R.string.shortday)).thenReturn("d");
|
||||||
|
when(MainApp.gs(R.string.shorthour)).thenReturn("h");
|
||||||
when(MainApp.gs(R.string.profile_carbs_per_unit)).thenReturn("g/U");
|
when(MainApp.gs(R.string.profile_carbs_per_unit)).thenReturn("g/U");
|
||||||
when(MainApp.gs(R.string.profile_ins_units_per_hour)).thenReturn("U/h");
|
when(MainApp.gs(R.string.profile_ins_units_per_hour)).thenReturn("U/h");
|
||||||
when(MainApp.gs(R.string.sms_wrongcode)).thenReturn("Wrong code. Command cancelled.");
|
when(MainApp.gs(R.string.sms_wrongcode)).thenReturn("Wrong code. Command cancelled.");
|
||||||
|
|
Loading…
Reference in a new issue