From dfd1e15791b877b0b3a084e403930f5824d0180c Mon Sep 17 00:00:00 2001 From: sonora Date: Wed, 20 Jul 2016 10:51:16 +0200 Subject: [PATCH] first stab at 2747 --- .../plus/views/mapwidgets/RouteInfoWidgetsFactory.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/OsmAnd/src/net/osmand/plus/views/mapwidgets/RouteInfoWidgetsFactory.java b/OsmAnd/src/net/osmand/plus/views/mapwidgets/RouteInfoWidgetsFactory.java index 4b3f8e041b..adb736f0a8 100644 --- a/OsmAnd/src/net/osmand/plus/views/mapwidgets/RouteInfoWidgetsFactory.java +++ b/OsmAnd/src/net/osmand/plus/views/mapwidgets/RouteInfoWidgetsFactory.java @@ -386,7 +386,7 @@ public class RouteInfoWidgetsFactory { @Override public boolean updateInfo(DrawSettings drawSettings) { float mx = 0; - if ((rh == null || !rh.isFollowingMode()) && trackingUtilities.isMapLinkedToLocation()) { + if ((rh == null || !rh.isFollowingMode() || rh.isDeviatedFromRoute()) && trackingUtilities.isMapLinkedToLocation()) { RouteDataObject ro = locationProvider.getLastKnownRouteSegment(); if(ro != null) { boolean direction = true; @@ -793,7 +793,7 @@ public class RouteInfoWidgetsFactory { int[] loclanes = null; int dist = 0; // TurnType primary = null; - if ((rh == null || !rh.isFollowingMode()) && trackingUtilities.isMapLinkedToLocation() + if ((rh == null || !rh.isFollowingMode() || rh.isDeviatedFromRoute()) && trackingUtilities.isMapLinkedToLocation() && settings.SHOW_LANES.get()) { RouteDataObject ro = locationProvider.getLastKnownRouteSegment(); Location lp = locationProvider.getLastKnownLocation(); @@ -1139,7 +1139,7 @@ public class RouteInfoWidgetsFactory { boolean eval = rh.isFollowingMode() || trackingUtilities.isMapLinkedToLocation(); if ((trafficWarnings || cams) && eval) { AlarmInfo alarm ; - if(rh.isFollowingMode()) { + if(rh.isFollowingMode() && !rh.isDeviatedFromRoute()) { alarm = wh.getMostImportantAlarm(settings.METRIC_SYSTEM.get(), cams); } else { RouteDataObject ro = locationProvider.getLastKnownRouteSegment();