summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason Wray <jason@mapbox.com>2017-09-28 16:47:54 -0400
committerJason Wray <jason@mapbox.com>2017-09-28 17:01:31 -0400
commitb9cf4a750302d79f8b8473dfedd522a69821e34f (patch)
tree04dda838fc3464f6c99617de6d8d9de44d743607
parent64c75b442c4d387e4867757abf49462c561e5955 (diff)
downloadqtlocation-mapboxgl-b9cf4a750302d79f8b8473dfedd522a69821e34f.tar.gz
[ios] Expose -showAttribution publicly as an IBAction
-rw-r--r--platform/ios/CHANGELOG.md1
-rw-r--r--platform/ios/src/MGLMapView.h12
2 files changed, 12 insertions, 1 deletions
diff --git a/platform/ios/CHANGELOG.md b/platform/ios/CHANGELOG.md
index 8dd1c5d8c7..813cdba083 100644
--- a/platform/ios/CHANGELOG.md
+++ b/platform/ios/CHANGELOG.md
@@ -33,6 +33,7 @@ Mapbox welcomes participation and contributions from everyone. Please read [CONT
* Fixed an issue that could cause line label rendering glitches when the line geometry is projected to a point behind the plane of the camera. ([#9865](https://github.com/mapbox/mapbox-gl-native/pull/9865))
* Fixed an issue that could cause a crash when using `-[MGLMapView flyToCamera:completionHandler:]` and related methods with zoom levels at or near the maximum value. ([#9381](https://github.com/mapbox/mapbox-gl-native/pull/9381))
+* Added `-[MGLMapView showAttribution]` to allow custom attribution buttons to show the default attribution interface. ([#10085](https://github.com/mapbox/mapbox-gl-native/pull/10085))
## 3.6.4 - September 25, 2017
diff --git a/platform/ios/src/MGLMapView.h b/platform/ios/src/MGLMapView.h
index 528606fd4e..5779576b86 100644
--- a/platform/ios/src/MGLMapView.h
+++ b/platform/ios/src/MGLMapView.h
@@ -251,7 +251,8 @@ MGL_EXPORT IB_DESIGNABLE
/**
A view showing legally required copyright notices and telemetry settings,
- positioned at the bottom-right of the map view.
+ positioned at the bottom-right of the map view. Tapping on this button will
+ call `-showAttribution`.
@note The Mapbox terms of service, which governs the use of Mapbox-hosted
vector tiles and styles,
@@ -272,6 +273,15 @@ MGL_EXPORT IB_DESIGNABLE
@property (nonatomic, readonly) UIButton *attributionButton;
/**
+ Show the attribution and telemetry action sheet.
+
+ This method is called when the user taps on `attributionButton`. This method is
+ made available so that it can be assigned to custom attribution button
+ implementations.
+ */
+- (IBAction)showAttribution;
+
+/**
Support for style classes has been removed. This property always returns an empty array.
*/
@property (nonatomic) NS_ARRAY_OF(NSString *) *styleClasses __attribute__((deprecated("This property is non-functional.")));