summaryrefslogtreecommitdiff
path: root/platform/macos/app/MapDocument.m
diff options
context:
space:
mode:
authorFabian Guerra <fabian.guerra@mapbox.com>2018-02-15 11:54:51 -0500
committerFabian Guerra <fabian.guerra@mapbox.com>2018-02-15 11:54:51 -0500
commit903e7989ec3438a605bafbf5938de38cdb868e4a (patch)
treea2f8ba01fd8bf41503396605b993f9e38b77e131 /platform/macos/app/MapDocument.m
parentc83dc310aa656132638a66e65ba8aa274b5e969f (diff)
parent82de856c94bbc090ba30186011610da5e233e277 (diff)
downloadqtlocation-mapboxgl-903e7989ec3438a605bafbf5938de38cdb868e4a.tar.gz
Merge branch 'master' into release-boba
# Conflicts: # platform/android/CHANGELOG.md # platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/Mapbox.java # platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/maps/widgets/CompassView.java # platform/android/scripts/exclude-activity-gen.json # platform/ios/CHANGELOG.md # platform/ios/Mapbox-iOS-SDK-nightly-dynamic.podspec # platform/ios/Mapbox-iOS-SDK-symbols.podspec # platform/ios/Mapbox-iOS-SDK.podspec # platform/macos/CHANGELOG.md
Diffstat (limited to 'platform/macos/app/MapDocument.m')
-rw-r--r--platform/macos/app/MapDocument.m8
1 files changed, 7 insertions, 1 deletions
diff --git a/platform/macos/app/MapDocument.m b/platform/macos/app/MapDocument.m
index 602ed1aa41..7d39f93347 100644
--- a/platform/macos/app/MapDocument.m
+++ b/platform/macos/app/MapDocument.m
@@ -726,8 +726,14 @@ NS_ARRAY_OF(id <MGLAnnotation>) *MBXFlattenedShapes(NS_ARRAY_OF(id <MGLAnnotatio
[self.undoManager setActionName:@"Add Graticule"];
}
+ NSDictionary *sourceOptions = @{
+ MGLShapeSourceOptionMaximumZoomLevel:@14,
+ MGLShapeSourceOptionWrapsCoordinates: @YES,
+ MGLShapeSourceOptionClipsCoordinates: @YES,
+ };
MGLComputedShapeSource *source = [[MGLComputedShapeSource alloc] initWithIdentifier:@"graticule"
- options:@{MGLShapeSourceOptionMaximumZoomLevel:@14}];
+ options:sourceOptions];
+
source.dataSource = self;
[self.mapView.style addSource:source];
MGLLineStyleLayer *lineLayer = [[MGLLineStyleLayer alloc] initWithIdentifier:@"graticule.lines"