summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulian Rex <julian.rex@mapbox.com>2019-03-31 16:19:15 -0400
committerJulian Rex <julian.rex@mapbox.com>2019-03-31 16:19:15 -0400
commit13a770fdf4ad029bb82cbaf0279918b070fd4f36 (patch)
treed19ad263919b93b7635108524e07e7d55d7b9aeb
parent2cfdd1a2f7042650538d24058fc28ad092739073 (diff)
downloadqtlocation-mapboxgl-upstream/jrex/gli-1125-presents-with-transaction.tar.gz
[ios] Wrap presentsWithTransaction with #ifdef.upstream/jrex/gli-1125-presents-with-transaction
-rw-r--r--platform/ios/src/MGLMapView.mm2
1 files changed, 2 insertions, 0 deletions
diff --git a/platform/ios/src/MGLMapView.mm b/platform/ios/src/MGLMapView.mm
index c94cf477ef..99fdd49b02 100644
--- a/platform/ios/src/MGLMapView.mm
+++ b/platform/ios/src/MGLMapView.mm
@@ -701,8 +701,10 @@ public:
_glView.layer.opaque = _opaque;
_glView.delegate = self;
+#ifdef MGL_EAGLLAYER_PRESENTS_WITH_TRANSACTION
CAEAGLLayer *eaglLayer = MGL_OBJC_DYNAMIC_CAST(_glView.layer, CAEAGLLayer);
eaglLayer.presentsWithTransaction = YES;
+#endif
[_glView bindDrawable];
[self insertSubview:_glView atIndex:0];