From a8fd30d0e04c13fdfa72a1a3c5df1ace2be505d7 Mon Sep 17 00:00:00 2001 From: "r.kuznetsov" Date: Tue, 31 May 2016 17:18:39 +0300 Subject: [PATCH] Fixed scaling on location update in routing --- drape_frontend/user_event_stream.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/drape_frontend/user_event_stream.cpp b/drape_frontend/user_event_stream.cpp index 17e6f5c084..fa604ff323 100644 --- a/drape_frontend/user_event_stream.cpp +++ b/drape_frontend/user_event_stream.cpp @@ -323,15 +323,14 @@ bool UserEventStream::SetScale(m2::PointD const & pxScaleCenter, double factor, if (isAnim) { auto const & followAnim = m_animationSystem.FindAnimation(Animation::MapFollow); - if (followAnim != nullptr) + if (followAnim != nullptr && followAnim->HasScale()) { // Scaling is not possible if current follow animation does pixel offset. if (followAnim->HasPixelOffset()) return false; - + // Reset follow animation with scaling if we apply scale explicitly. - if (followAnim->HasScale()) - ResetAnimations(Animation::MapFollow); + ResetAnimations(Animation::MapFollow); } m2::PointD glbScaleCenter = m_navigator.PtoG(m_navigator.P3dtoP(scaleCenter));