summaryrefslogtreecommitdiff
path: root/platform/ios/src/MGLMapView.mm
diff options
context:
space:
mode:
Diffstat (limited to 'platform/ios/src/MGLMapView.mm')
-rw-r--r--platform/ios/src/MGLMapView.mm10
1 files changed, 7 insertions, 3 deletions
diff --git a/platform/ios/src/MGLMapView.mm b/platform/ios/src/MGLMapView.mm
index 18a69a34cd..6b47dc05f7 100644
--- a/platform/ios/src/MGLMapView.mm
+++ b/platform/ios/src/MGLMapView.mm
@@ -1476,10 +1476,12 @@ public:
double zoom = log2(newScale);
MGLMapCamera *toCamera = [self cameraByZoomingToZoomLevel:zoom aroundAnchorPoint:centerPoint];
- if ([self _shouldChangeFromCamera:oldCamera toCamera:toCamera])
+ if ( ! [self _shouldChangeFromCamera:oldCamera toCamera:toCamera])
{
drift = NO;
- } else {
+ }
+ else
+ {
if (drift)
{
_mbglMap->setZoom(zoom, mbgl::ScreenCoordinate { centerPoint.x, centerPoint.y }, MGLDurationFromTimeInterval(duration));
@@ -1730,7 +1732,9 @@ public:
{
[weakSelf unrotateIfNeededForGesture];
}];
- } else {
+ }
+ else
+ {
[self unrotateIfNeededForGesture];
}
}