From 7782802f3741ddff15ae9753ca484d13543a65cd Mon Sep 17 00:00:00 2001 From: Jason Wray Date: Thu, 10 Sep 2015 19:29:13 -0400 Subject: [PATCH] [iOS] Remove unneccessary pitch check Fix case where moving the tilted dot off-screen, changing the pitch to 0, and then moving the dot back on screen would not reset the pitch of the dot. --- platform/ios/MGLUserLocationAnnotationView.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform/ios/MGLUserLocationAnnotationView.m b/platform/ios/MGLUserLocationAnnotationView.m index 22c1d00f1..b477b1088 100644 --- a/platform/ios/MGLUserLocationAnnotationView.m +++ b/platform/ios/MGLUserLocationAnnotationView.m @@ -95,7 +95,7 @@ const CGFloat MGLUserLocationAnnotationArrowSize = MGLUserLocationAnnotationPuck - (void)updatePitch { - if (self.mapView.camera.pitch && (self.mapView.camera.pitch != _oldPitch)) + if (self.mapView.camera.pitch != _oldPitch) { CATransform3D t = CATransform3DRotate(CATransform3DIdentity, MGLRadiansFromDegrees(self.mapView.camera.pitch), 1.0, 0, 0); self.layer.sublayerTransform = t;