From 7694eebe8837f45540687aea65301a83243d74f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Minh=20Nguye=CC=82=CC=83n?= Date: Mon, 1 Feb 2016 20:48:28 -0800 Subject: [ios] Renamed -showAnnotations:withEdgeInsets:animated: Renamed -showAnnotations:withEdgeInsets:animated: to -showAnnotations:edgePadding:animated: for consistency with other methods. Reworded documentation comments to avoid hard-coding too many specifics that are prone to getting outdated. --- include/mbgl/ios/MGLMapView.h | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) (limited to 'include') diff --git a/include/mbgl/ios/MGLMapView.h b/include/mbgl/ios/MGLMapView.h index 5a94ab2f44..dc03c13f7b 100644 --- a/include/mbgl/ios/MGLMapView.h +++ b/include/mbgl/ios/MGLMapView.h @@ -597,11 +597,10 @@ IB_DESIGNABLE /** Sets the visible region so that the map displays the specified annotations. - Calling this method updates the value in the visibleCoordinateBounds property - and potentially other properties to reflect the new map region. Defaults to - insetting the annotation bounds by 100,100,100,100, or if map is smaller than - 200x200 in either dimension, sets the insets to 20% of that dimmension on - either side. + Calling this method updates the value in the `visibleCoordinateBounds` property + and potentially other properties to reflect the new map region. A small amount + of padding is reserved around the edges of the map view. To specify a different + amount of padding, use the `-showAnnotations:edgePadding:animated:` method. @param annotations The annotations that you want to be visible in the map. @param animated `YES` if you want the map region change to be animated, or `NO` @@ -611,18 +610,18 @@ IB_DESIGNABLE /** Sets the visible region so that the map displays the specified annotations with - custom insets. + the specified amount of padding on each side. Calling this method updates the value in the visibleCoordinateBounds property - and potentially other properties to reflect the new map region. It allows for - the customization of the UIEdgeInsets that determine the resultant viewport. + and potentially other properties to reflect the new map region. @param annotations The annotations that you want to be visible in the map. - @param edgeInsets Custom edge insets to contain the the annotations within. + @param insets The minimum padding (in screen points) around the edges of the + map view to keep clear of annotations. @param animated `YES` if you want the map region change to be animated, or `NO` if you want the map to display the new region immediately without animations. */ -- (void)showAnnotations:(NS_ARRAY_OF(id ) *)annotations withEdgeInsets:(UIEdgeInsets)edgeInsets animated:(BOOL)animated; +- (void)showAnnotations:(NS_ARRAY_OF(id ) *)annotations edgePadding:(UIEdgeInsets)insets animated:(BOOL)animated; /** A camera representing the current viewpoint of the map. -- cgit v1.2.1