[ios] Fix slow switching from GuideView to MapView, when before GuideView was swtiched during a long redraw. Kudos to Sergey!

This commit is contained in:
Yury Melnichek 2011-04-07 22:01:46 +02:00 committed by Alex Zolotarev
parent 6ed4c80926
commit 37b8a70625

View file

@ -396,8 +396,18 @@ NSInteger compareAddress(UITouch * l, UITouch * r, void * context)
{
if (m_framework)
{
if (!m_framework->SetUpdatesEnabled(true))
m_framework->Invalidate();
LOG(LINFO, ("Invalidate: [self.view drawView]"));
[(EAGLView *)self.view drawView];
LOG(LINFO, ("Invalidate: m_framework->SetUpdatesEnabled(true)"));
m_framework->SetUpdatesEnabled(true);
LOG(LINFO, ("Invalidate: done."));
// The code below causes very long response time when switching from GuideView to MapView,
// if before there was a long redraw on MapView to GuideView switch.
//
// if (!m_framework->SetUpdatesEnabled(true))
// m_framework->Invalidate();
// LOG(LINFO, ("Invalidate done."));
}
}