diff --git a/OsmAnd/src/net/osmand/plus/routing/RoutingHelper.java b/OsmAnd/src/net/osmand/plus/routing/RoutingHelper.java index 7f79fb4765..8c3110401d 100644 --- a/OsmAnd/src/net/osmand/plus/routing/RoutingHelper.java +++ b/OsmAnd/src/net/osmand/plus/routing/RoutingHelper.java @@ -454,7 +454,9 @@ public class RoutingHelper { } // 2. check if intermediate found - if(route.getIntermediatePointsToPass() > 0 && route.getDistanceToNextIntermediate(lastFixedLocation) < POSITION_TOLERANCE * 2) { + if(route.getIntermediatePointsToPass() > 0 + && route.getDistanceToNextIntermediate(lastFixedLocation) < POSITION_TOLERANCE * 2 + && !isRoutePlanningMode) { showMessage(app.getString(R.string.arrived_at_intermediate_point)); route.passIntermediatePoint(); TargetPointsHelper targets = app.getTargetPointsHelper(); @@ -485,7 +487,9 @@ public class RoutingHelper { // 3. check if destination found Location lastPoint = routeNodes.get(routeNodes.size() - 1); - if (currentRoute > routeNodes.size() - 3 && currentLocation.distanceTo(lastPoint) < (((float)settings.getApplicationMode().getArrivalDistance()) * settings.ARRIVAL_DISTANCE_FACTOR.get())) { + if (currentRoute > routeNodes.size() - 3 + && currentLocation.distanceTo(lastPoint) < (((float)settings.getApplicationMode().getArrivalDistance()) * settings.ARRIVAL_DISTANCE_FACTOR.get()) + && !isRoutePlanningMode) { showMessage(app.getString(R.string.arrived_at_destination)); TargetPointsHelper targets = app.getTargetPointsHelper(); TargetPoint tp = targets.getPointToNavigate(); diff --git a/OsmAnd/src/net/osmand/plus/views/controls/SwipeDismissListViewTouchListener.java b/OsmAnd/src/net/osmand/plus/views/controls/SwipeDismissListViewTouchListener.java index 5da7ffa495..8aa5c84d42 100644 --- a/OsmAnd/src/net/osmand/plus/views/controls/SwipeDismissListViewTouchListener.java +++ b/OsmAnd/src/net/osmand/plus/views/controls/SwipeDismissListViewTouchListener.java @@ -460,10 +460,10 @@ public class SwipeDismissListViewTouchListener implements View.OnTouchListener { undoable.discard(); } mUndoActions.clear(); - if (mCallbacks != null) { - mCallbacks.onHidePopup(); - } if (mUndoPopup.isShowing()) { + if (mCallbacks != null) { + mCallbacks.onHidePopup(); + } mUndoPopup.dismiss(); } }