changed customLocation to be only fingerLocation
This commit is contained in:
parent
ff2989a16e
commit
d14b2477fc
2 changed files with 3 additions and 5 deletions
|
@ -314,9 +314,7 @@ public class MapMarkersLayer extends OsmandMapLayer implements IContextMenuProvi
|
|||
|
||||
@Override
|
||||
public void onDraw(Canvas canvas, RotatedTileBox tileBox, DrawSettings nightMode) {
|
||||
Location myLoc = map.getMyApplication().getLocationProvider().getLastStaleKnownLocation();
|
||||
widgetsFactory.updateInfo(useFingerLocation ? fingerLocation : (myLoc == null
|
||||
? tileBox.getCenterLatLon() : new LatLon(myLoc.getLatitude(), myLoc.getLongitude())), tileBox.getZoom());
|
||||
widgetsFactory.updateInfo(useFingerLocation ? fingerLocation : null, tileBox.getZoom());
|
||||
OsmandSettings settings = map.getMyApplication().getSettings();
|
||||
|
||||
if (tileBox.getZoom() < 3 || !settings.USE_MAP_MARKERS.get()) {
|
||||
|
|
|
@ -192,11 +192,11 @@ public class MapMarkersWidgetsFactory {
|
|||
if (customLocation != null) {
|
||||
loc = customLocation;
|
||||
} else {
|
||||
Location l = map.getMapViewTrackingUtilities().getMyLocation();
|
||||
Location l = map.getMyApplication().getLocationProvider().getLastStaleKnownLocation();
|
||||
if (l != null) {
|
||||
loc = new LatLon(l.getLatitude(), l.getLongitude());
|
||||
} else {
|
||||
loc = null;
|
||||
loc = map.getMapLocation();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue