Merge pull request #7108 from osmandapp/issue_6933
fix for #6933 - Routing details: "Walk {time}" string inverted in the…
This commit is contained in:
commit
f4914cba3c
1 changed files with 3 additions and 3 deletions
|
@ -797,13 +797,13 @@ public class RouteDetailsFragment extends ContextMenuFragment implements PublicT
|
||||||
if (walkTime < 60) {
|
if (walkTime < 60) {
|
||||||
walkTime = 60;
|
walkTime = 60;
|
||||||
}
|
}
|
||||||
SpannableStringBuilder spannable = new SpannableStringBuilder("~");
|
SpannableStringBuilder spannable = new SpannableStringBuilder(getString(R.string.shared_string_walk)).append(" ");
|
||||||
spannable.setSpan(new ForegroundColorSpan(getSecondaryColor()), 0, spannable.length(), Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
spannable.setSpan(new ForegroundColorSpan(getSecondaryColor()), 0, spannable.length(), Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||||
int startIndex = spannable.length();
|
int startIndex = spannable.length();
|
||||||
spannable.append(OsmAndFormatter.getFormattedDuration(walkTime, app)).append(" ");
|
spannable.append("~").append(OsmAndFormatter.getFormattedDuration(walkTime, app));
|
||||||
spannable.setSpan(new CustomTypefaceSpan(typeface), startIndex, spannable.length(), Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
spannable.setSpan(new CustomTypefaceSpan(typeface), startIndex, spannable.length(), Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||||
startIndex = spannable.length();
|
startIndex = spannable.length();
|
||||||
spannable.append(getString(R.string.shared_string_walk)).append(", ").append(OsmAndFormatter.getFormattedDistance((float) walkDist, app));
|
spannable.append(", ").append(OsmAndFormatter.getFormattedDistance((float) walkDist, app));
|
||||||
spannable.setSpan(new ForegroundColorSpan(getSecondaryColor()), startIndex, spannable.length(), Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
spannable.setSpan(new ForegroundColorSpan(getSecondaryColor()), startIndex, spannable.length(), Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||||
|
|
||||||
buildWalkRow(infoContainer, spannable, imagesContainer, new OnClickListener() {
|
buildWalkRow(infoContainer, spannable, imagesContainer, new OnClickListener() {
|
||||||
|
|
Loading…
Reference in a new issue