summaryrefslogtreecommitdiff
path: root/platform/darwin/src/MGLShapeOfflineRegion.mm
diff options
context:
space:
mode:
Diffstat (limited to 'platform/darwin/src/MGLShapeOfflineRegion.mm')
-rw-r--r--platform/darwin/src/MGLShapeOfflineRegion.mm15
1 files changed, 15 insertions, 0 deletions
diff --git a/platform/darwin/src/MGLShapeOfflineRegion.mm b/platform/darwin/src/MGLShapeOfflineRegion.mm
index e1393f1199..02ff2abfc5 100644
--- a/platform/darwin/src/MGLShapeOfflineRegion.mm
+++ b/platform/darwin/src/MGLShapeOfflineRegion.mm
@@ -12,6 +12,10 @@
#import "MGLShape_Private.h"
#import "MGLStyle.h"
+#if TARGET_OS_IPHONE || TARGET_OS_SIMULATOR
+#import "MMEConstants.h"
+#endif
+
@interface MGLShapeOfflineRegion () <MGLOfflineRegion_Private, MGLShapeOfflineRegion_Private>
@end
@@ -22,6 +26,17 @@
@synthesize styleURL = _styleURL;
+#if TARGET_OS_IPHONE || TARGET_OS_SIMULATOR
+-(NSDictionary *)offlineStartEventAttributes {
+ return @{
+ MMEEventKeyShapeForOfflineRegion: @"shaperegion",
+ MMEEventKeyMinZoomLevel: @(self.minimumZoomLevel),
+ MMEEventKeyMaxZoomLevel: @(self.maximumZoomLevel),
+ MMEEventKeyStyleURL: self.styleURL
+ };
+}
+#endif
+
+ (BOOL)supportsSecureCoding {
return YES;
}