diff options
author | Daria Volvenkova <d.volvenkova@corp.mail.ru> | 2016-05-23 19:35:55 +0300 |
---|---|---|
committer | Daria Volvenkova <d.volvenkova@corp.mail.ru> | 2016-05-23 19:35:55 +0300 |
commit | 783e35005d9aa727007fe20eefa830d8fa03cd7c (patch) | |
tree | 257093ab81e6e73055969842782bb7e7e9aa52e7 /drape_frontend/animation | |
parent | 45558e737deb5bf029f1269d2c2255785a480f50 (diff) |
Fixed the arrow position recovering after a routing deactivation.
Diffstat (limited to 'drape_frontend/animation')
-rw-r--r-- | drape_frontend/animation/animation.cpp | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/drape_frontend/animation/animation.cpp b/drape_frontend/animation/animation.cpp index 75f9c7f246..5bf4d09cff 100644 --- a/drape_frontend/animation/animation.cpp +++ b/drape_frontend/animation/animation.cpp @@ -5,8 +5,19 @@ namespace df bool Animation::CouldBeBlendedWith(Animation const & animation) const { - return (GetType() != animation.GetType()) && - m_couldBeBlended && animation.m_couldBeBlended; + bool hasSameObject = false; + TAnimObjects const & objects = animation.GetObjects(); + for (auto const & object : objects) + { + if (HasObject(object)) + { + hasSameObject = true; + break; + } + } + + return !hasSameObject || ((GetType() != animation.GetType()) && + m_couldBeBlended && animation.m_couldBeBlended); } } // namespace df |