Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Run loop fix.

Reviewed by me.
  • Loading branch information...
commit bbc93296100bd9af8400cb56c24d050d69419ede 1 parent 575f9a6
@tolmasky tolmasky authored
Showing with 8 additions and 2 deletions.
  1. +8 −2 MKMapView.j
View
10 MKMapView.j
@@ -155,9 +155,11 @@
centerCoordinate = [self centerCoordinate];
if (!CLLocationCoordinate2DEqualToCLLocationCoordinate2D(centerCoordinate, newCenterCoordinate))
+ {
[self setCenterCoordinate:newCenterCoordinate];
- [[CPRunLoop currentRunLoop] limitDateForMode:CPDefaultRunLoopMode];
+ [[CPRunLoop currentRunLoop] limitDateForMode:CPDefaultRunLoopMode];
+ }
}
var updateZoomLevel = function()
@@ -166,9 +168,11 @@
zoomLevel = [self zoomLevel];
if (newZoomLevel !== zoomLevel)
+ {
[self setZoomLevel:newZoomLevel];
- [[CPRunLoop currentRunLoop] limitDateForMode:CPDefaultRunLoopMode];
+ [[CPRunLoop currentRunLoop] limitDateForMode:CPDefaultRunLoopMode];
+ }
}
google.maps.Event.addListener(m_map, "moveend", updateCenterCoordinate);
@@ -299,6 +303,8 @@
[self setCenterCoordinate:CLLocationCoordinate2DFromLatLng(aLatLng)];
[self setZoomLevel:7];
+
+ [[CPRunLoop currentRunLoop] limitDateForMode:CPDefaultRunLoopMode];
});
}
Please sign in to comment.
Something went wrong with that request. Please try again.