[routing] Small fix

This commit is contained in:
Александр Зацепин 2017-11-17 20:13:01 +03:00 committed by Daria Volvenkova
parent 85d774e9c6
commit efb58fa6e6

View file

@ -248,6 +248,8 @@ void FillTransitStyleForRendering(vector<RouteSegment> const & segments, Transit
{
auto const time = static_cast<int>(ceil(s.GetTimeFromBeginningSec() - prevTime));
auto const distance = s.GetDistFromBeginningMeters() - prevDistance;
prevDistance = s.GetDistFromBeginningMeters();
prevTime = s.GetTimeFromBeginningSec();
if (!s.HasTransitInfo())
{
@ -383,9 +385,6 @@ void FillTransitStyleForRendering(vector<RouteSegment> const & segments, Transit
pendingEntrance = true;
}
}
prevDistance = s.GetDistFromBeginningMeters();
prevTime = s.GetTimeFromBeginningSec();
}
routeInfo.m_totalDistInMeters = prevDistance;