Hide extra description and remove unnecessary changes
This commit is contained in:
parent
a5610b7352
commit
5acf6e27f7
2 changed files with 8 additions and 5 deletions
|
@ -525,9 +525,7 @@ public class MapActivityActions implements DialogProvider {
|
||||||
TargetPointsHelper tg = mapActivity.getMyApplication().getTargetPointsHelper();
|
TargetPointsHelper tg = mapActivity.getMyApplication().getTargetPointsHelper();
|
||||||
tg.clearStartPoint(false);
|
tg.clearStartPoint(false);
|
||||||
Location finishLoc = ps.get(ps.size() - 1);
|
Location finishLoc = ps.get(ps.size() - 1);
|
||||||
PointDescription point = new PointDescription(PointDescription.POINT_TYPE_LOCATION, result.path, "");
|
tg.navigateToPoint(new LatLon(finishLoc.getLatitude(), finishLoc.getLongitude()), false, -1);
|
||||||
point.setName(PointDescription.getSearchAddressStr(mapActivity));
|
|
||||||
tg.navigateToPoint(new LatLon(finishLoc.getLatitude(), finishLoc.getLongitude()), false, -1, point);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1760,8 +1760,13 @@ public class MapRouteInfoMenu implements IRouteInformationListener, CardListener
|
||||||
if (routeParams != null) {
|
if (routeParams != null) {
|
||||||
TargetPoint target = app.getTargetPointsHelper().getPointToNavigate();
|
TargetPoint target = app.getTargetPointsHelper().getPointToNavigate();
|
||||||
if (target != null) {
|
if (target != null) {
|
||||||
PointDescription pointDescription = target.getOriginalPointDescription();
|
List<Location> points = routeParams.getPoints(app);
|
||||||
return pointDescription != null && routeParams.getFile().path.equals(pointDescription.getTypeName());
|
if (!Algorithms.isEmpty(points)) {
|
||||||
|
Location loc = points.get(points.size() - 1);
|
||||||
|
LatLon latLon = new LatLon(loc.getLatitude(), loc.getLongitude());
|
||||||
|
LatLon targetLatLon = new LatLon(target.getLatitude(), target.getLongitude());
|
||||||
|
return latLon.equals(targetLatLon);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue