Changed estimated arrival text to emphasize arrival at *destination*
This commit is contained in:
parent
05c6c2298a
commit
5f04b943ea
@ -44,4 +44,5 @@
|
||||
<string name="set_alarm">Set alarm</string>
|
||||
<string name="leaving">Leaving</string>
|
||||
<string name="departed">Departed</string>
|
||||
<string name="arrives_at_destination">Arrive @ dest. ~</string>
|
||||
</resources>
|
@ -77,10 +77,12 @@ public class DepartureArrayAdapter extends ArrayAdapter<Departure> {
|
||||
.findViewById(R.id.trainLengthText);
|
||||
initTextSwitcher(textSwitcher);
|
||||
|
||||
final String arrivesAtDestinationPrefix = getContext().getString(
|
||||
R.string.arrives_at_destination);
|
||||
final String estimatedArrivalTimeText = departure
|
||||
.getEstimatedArrivalTimeText(getContext());
|
||||
if (!StringUtils.isBlank(estimatedArrivalTimeText)) {
|
||||
textSwitcher.setCurrentText("Est. arrival "
|
||||
textSwitcher.setCurrentText(arrivesAtDestinationPrefix
|
||||
+ estimatedArrivalTimeText);
|
||||
} else {
|
||||
textSwitcher.setCurrentText(departure.getTrainLengthText());
|
||||
@ -96,7 +98,8 @@ public class DepartureArrayAdapter extends ArrayAdapter<Departure> {
|
||||
if (StringUtils.isBlank(estimatedArrivalTimeText)) {
|
||||
return "";
|
||||
} else {
|
||||
return "Est. arrival " + estimatedArrivalTimeText;
|
||||
return arrivesAtDestinationPrefix
|
||||
+ estimatedArrivalTimeText;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user