Merge remote-tracking branch 'origin/master'

This commit is contained in:
Weblate 2018-03-12 13:49:32 +01:00
commit d471b47c43
2 changed files with 11 additions and 28 deletions

View file

@ -1296,28 +1296,6 @@
<string name="shared_string_my_tracks">Всі треки</string>
<string name="shared_string_my_favorites">Мої закладки</string>
<string name="shared_string_my_places">Мої місця</string>
<<<<<<< HEAD
<<<<<<< HEAD
=======
=======
>>>>>>> origin/master
<string name="osmo_user_joined">Користувач %1$s приєднався до групи %2$s</string>
<string name="osmo_user_left">Користувач %1$s покинув групу %2$s</string>
<string name="osmo_show_group_notifications">Показувати сповіщення групи</string>
@ -1334,10 +1312,6 @@
<string name="osmo_use_server_name">Зареєстроване ім’я</string>
<string name="osmo_connect_to_my_nickname">Прізвисько</string>
<string name="osmo_user_name">Користувач</string>
<<<<<<< HEAD
>>>>>>> weblate/master
=======
>>>>>>> origin/master
<string name="rendering_value_pink_name">рожевий</string>

View file

@ -106,6 +106,8 @@ public class MapMarkersLayer extends OsmandMapLayer implements IContextMenuProvi
private boolean inPlanRouteMode;
private boolean defaultAppMode = true;
private List<Amenity> amenities = new ArrayList<>();
public MapMarkersLayer(MapActivity map) {
this.map = map;
}
@ -515,7 +517,7 @@ public class MapMarkersLayer extends OsmandMapLayer implements IContextMenuProvi
if (tileBox.getZoom() < 3 || !map.getMyApplication().getSettings().USE_MAP_MARKERS.get()) {
return;
}
amenities.clear();
OsmandApplication app = map.getMyApplication();
int r = getDefaultRadiusPoi(tileBox);
boolean selectMarkerOnSingleTap = app.getSettings().SELECT_MARKER_ON_SINGLE_TAP.get();
@ -535,7 +537,12 @@ public class MapMarkersLayer extends OsmandMapLayer implements IContextMenuProvi
continue;
}
Amenity mapObj = getMapObjectByMarker(marker);
o.add(mapObj == null ? marker : mapObj);
if (mapObj != null) {
amenities.add(mapObj);
o.add(mapObj);
} else {
o.add(marker);
}
}
}
}
@ -568,6 +575,8 @@ public class MapMarkersLayer extends OsmandMapLayer implements IContextMenuProvi
public LatLon getObjectLocation(Object o) {
if (o instanceof MapMarker) {
return ((MapMarker) o).point;
} else if (o instanceof Amenity && amenities.contains(o)) {
return ((Amenity) o).getLocation();
}
return null;
}