mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-26 12:23:58 +01:00
Enhancement :- Explore Map information
This commit is contained in:
parent
abf1c76b04
commit
efdff5e9c5
1 changed files with 11 additions and 2 deletions
|
|
@ -717,8 +717,17 @@ public class ExploreMapFragment extends CommonsDaggerSupportFragment
|
|||
authorUser = Html.fromHtml(authorUser, Html.FROM_HTML_MODE_LEGACY).toString();
|
||||
}
|
||||
|
||||
OverlayItem item = new OverlayItem(nearbyBaseMarker.getPlace().name,
|
||||
authorUser, point);
|
||||
String title = nearbyBaseMarker.getPlace().name;
|
||||
if (title.startsWith("File:")) {
|
||||
title = title.substring(5);
|
||||
}
|
||||
title = title.replaceAll("(?i)\\.(jpg|jpeg|png|svg)$", "");
|
||||
title = title.replace("_", " ");
|
||||
if (title.length() >43) {
|
||||
title = title.substring(0, 40) + "...";
|
||||
}
|
||||
|
||||
OverlayItem item = new OverlayItem(title, authorUser, point);
|
||||
item.setMarker(d);
|
||||
items.add(item);
|
||||
ItemizedOverlayWithFocus overlay = new ItemizedOverlayWithFocus(items,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue