From 29688e2cd8291f0352ac00d24bf54024501eb92f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Minh=20Nguye=CC=82=CC=83n?= Date: Sun, 24 Jan 2016 22:21:41 -0800 Subject: [ios] Disable implicit animation of user dot bounds ref #1125 --- CHANGELOG.md | 1 + platform/ios/src/MGLUserLocationAnnotationView.m | 10 ++++++++++ 2 files changed, 11 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8473923779..bb09b09b92 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -60,6 +60,7 @@ Known issues: - Updated documentation to reflect the requirement that you must embed the framework in the “Embedded Binaries” section in Xcode. ([#4011](https://github.com/mapbox/mapbox-gl-native/issues/4011)) - Telemetry location gathering now only occurs when the device is in motion (https://github.com/mapbox/mapbox-gl-native/pull/4115) - Polygons and polylines now default to using the map view’s tint color. ([#4028](https://github.com/mapbox/mapbox-gl-native/pull/4028)) +- The user dot no longer lags when panning the map. ([#3683](https://github.com/mapbox/mapbox-gl-native/pull/3683)) - The Improve This Map tool now uses the same zoom level that is currently being shown in the map view. ([#4068](https://github.com/mapbox/mapbox-gl-native/pull/4068)) - Fixed a formatting issue in the documentation for `MGLCoordinateBoundsIsEmpty()`. ([#3958](https://github.com/mapbox/mapbox-gl-native/pull/3958)) diff --git a/platform/ios/src/MGLUserLocationAnnotationView.m b/platform/ios/src/MGLUserLocationAnnotationView.m index b59f4586b3..a7ca352bc0 100644 --- a/platform/ios/src/MGLUserLocationAnnotationView.m +++ b/platform/ios/src/MGLUserLocationAnnotationView.m @@ -507,4 +507,14 @@ const CGFloat MGLUserLocationAnnotationArrowSize = MGLUserLocationAnnotationPuck return ovalPath; } +- (id)actionForLayer:(CALayer *)layer forKey:(NSString *)event +{ + // Allow mbgl to drive animation of this view’s bounds. + if ([event isEqualToString:@"bounds"]) + { + return [NSNull null]; + } + return [super actionForLayer:layer forKey:event]; +} + @end -- cgit v1.2.1