summaryrefslogtreecommitdiff
path: root/platform/ios/src/MGLMapView.h
diff options
context:
space:
mode:
authorAsheem Mamoowala <asheem.mamoowala@mapbox.com>2017-10-09 11:50:48 -0700
committerAsheem Mamoowala <asheem.mamoowala@mapbox.com>2017-10-09 13:58:11 -0700
commit24bd336b88b4f2dae25277efeeb36a96061139a3 (patch)
treec1b3a95eb86753be703a33532e00aa682c5a100b /platform/ios/src/MGLMapView.h
parentdf20b0cbecb25b8bc6812c4a558fc0f0e6cfb7ed (diff)
downloadqtlocation-mapboxgl-24bd336b88b4f2dae25277efeeb36a96061139a3.tar.gz
[android][ios][macOS] Implement bindings for `Map::cameraForGeometry`. On macOS, also added -[MGLMapView setCamera: withDuration: animationTimingFunction: edgePadding: completionHandler:] for parity with iOS
Diffstat (limited to 'platform/ios/src/MGLMapView.h')
-rw-r--r--platform/ios/src/MGLMapView.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/platform/ios/src/MGLMapView.h b/platform/ios/src/MGLMapView.h
index a1347cc09c..e2c070a54f 100644
--- a/platform/ios/src/MGLMapView.h
+++ b/platform/ios/src/MGLMapView.h
@@ -890,6 +890,20 @@ MGL_EXPORT IB_DESIGNABLE
- (MGLMapCamera *)cameraThatFitsCoordinateBounds:(MGLCoordinateBounds)bounds edgePadding:(UIEdgeInsets)insets;
/**
+ Returns the camera that best fits the given shape, with the specified direction,
+ optionally with some additional padding on each side.
+
+ @param shape The shape to fit to the receiver’s viewport.
+ @param direction The direction of the viewport, measured in degrees clockwise from true north.
+ @param insets The minimum padding (in screen points) that would be visible
+ around the returned camera object if it were set as the receiver’s camera.
+ @return A camera object centered on the shape's center with zoom level as high
+ (close to the ground) as possible while still including the entire shape. The
+ camera object uses the current pitch.
+ */
+- (MGLMapCamera *)cameraThatFitsShape:(MGLShape *)shape direction:(CLLocationDirection)direction edgePadding:(UIEdgeInsets)insets;
+
+/**
Returns the point in this view’s coordinate system on which to "anchor" in
response to a user-initiated gesture.