From fcb248e550a58bad59a55e82fbc14a877406b116 Mon Sep 17 00:00:00 2001 From: Alexey Kulish Date: Fri, 25 May 2018 19:40:16 +0300 Subject: [PATCH] Try to fix animation while driving --- .../osmand/plus/views/AnimateDraggingMapThread.java | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/OsmAnd/src/net/osmand/plus/views/AnimateDraggingMapThread.java b/OsmAnd/src/net/osmand/plus/views/AnimateDraggingMapThread.java index 2a64976dee..748306bc36 100644 --- a/OsmAnd/src/net/osmand/plus/views/AnimateDraggingMapThread.java +++ b/OsmAnd/src/net/osmand/plus/views/AnimateDraggingMapThread.java @@ -162,17 +162,16 @@ public class AnimateDraggingMapThread { setTargetValues(zoom, finalLat, finalLon); boolean animateZoom = finalZoom != null && (zoom != startZoom || startZoomFP != 0); boolean animateRotation = rotation != startRotaton; - if (animateZoom) { - animatingZoomInThread(startZoom, startZoomFP, zoom, zoomFP, NAV_ANIMATION_TIME, notifyListener); - } - if (animateRotation) { animatingRotateInThread(rotation, 500f, notifyListener); } - - if (!stopped){ + if (!stopped) { animatingMoveInThread(mMoveX, mMoveY, NAV_ANIMATION_TIME, notifyListener, null); } + if (!stopped && animateZoom) { + animatingZoomInThread(startZoom, startZoomFP, zoom, 0, NAV_ANIMATION_TIME, notifyListener); + } + pendingRotateAnimation(); } }); }