summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorMinh Nguyễn <mxn@1ec5.org>2016-01-24 11:38:10 -0800
committerMinh Nguyễn <mxn@1ec5.org>2016-01-26 17:17:25 -0800
commit87f0174967f6616229f6e7e3398f08ed283d8615 (patch)
treebf5b614a658e994c2dc0c22e95cf8e088e181ae0 /include
parent9dcaab193359f3de1a9d9750363cc547a2e69093 (diff)
downloadqtlocation-mapboxgl-87f0174967f6616229f6e7e3398f08ed283d8615.tar.gz
[ios] Various user tracking mode fixes
Setting the user tracking mode without animation now works. Previously, it kept the user dot from ever updating. Just as a zoom gesture no longer kicks the user out of user tracking mode, programmatically zooming shouldn’t either. Setting a camera with an invalid center coordinate no longer attempts to change the center coordinate but still changes any other valid properties. Made animation to new user dot vertical alignment optional.
Diffstat (limited to 'include')
-rw-r--r--include/mbgl/ios/MGLMapView.h22
1 files changed, 21 insertions, 1 deletions
diff --git a/include/mbgl/ios/MGLMapView.h b/include/mbgl/ios/MGLMapView.h
index 2d28fd3a14..c0f4cd1365 100644
--- a/include/mbgl/ios/MGLMapView.h
+++ b/include/mbgl/ios/MGLMapView.h
@@ -224,7 +224,12 @@ IB_DESIGNABLE
@property (nonatomic, readonly, nullable) MGLUserLocation *userLocation;
/**
- The mode used to track the user location.
+ The mode used to track the user location. The default value is
+ `MGLUserTrackingModeNone`.
+
+ Changing the value of this property updates the map view with an animated
+ transition. If you don’t want to animate the change, use the
+ `-setUserTrackingMode:animated:` method instead.
*/
@property (nonatomic, assign) MGLUserTrackingMode userTrackingMode;
@@ -243,10 +248,25 @@ IB_DESIGNABLE
/**
The vertical alignment of the user location annotation within the receiver. The
default value is `MGLAnnotationVerticalAlignmentCenter`.
+
+ Changing the value of this property updates the map view with an animated
+ transition. If you don’t want to animate the change, use the
+ `-setUserLocationVerticalAlignment:animated:` method instead.
*/
@property (nonatomic, assign) MGLAnnotationVerticalAlignment userLocationVerticalAlignment;
/**
+ Sets the vertical alignment of the user location annotation within the
+ receiver, with an optional transition.
+
+ @param alignment The vertical alignment of the user location annotation.
+ @param animated If `YES`, the user location annotation animates to its new
+ position within the map view. If `NO`, the user location annotation
+ instantaneously moves to its new position.
+ */
+- (void)setUserLocationVerticalAlignment:(MGLAnnotationVerticalAlignment)alignment animated:(BOOL)animated;
+
+/**
Whether the map view should display a heading calibration alert when necessary.
The default value is `YES`.
*/