summaryrefslogtreecommitdiff
path: root/platform/ios/src/MGLAnnotationView.mm
diff options
context:
space:
mode:
authorJason Wray <friedbunny@users.noreply.github.com>2016-07-27 23:32:21 -0700
committerGitHub <noreply@github.com>2016-07-27 23:32:21 -0700
commitbc845b96b0d945cc0feea9177017d661f56a5f06 (patch)
treef067d28dc0d4251f481de25249d5ea7e7751a9d0 /platform/ios/src/MGLAnnotationView.mm
parent850b2e29889091684b088ad64741aa469a8db628 (diff)
downloadqtlocation-mapboxgl-bc845b96b0d945cc0feea9177017d661f56a5f06.tar.gz
[ios] Limit annotation view pan gesture check to own recognizer (#5813)
Allows non-dragging pans that are initiated on views to pan the underlying map. Annotation views each have long press and pan gesture recognizers. If a view is not draggable or not in a positive dragging state, the pan gesture recognizer should not begin. This commit makes the criteria for rejecting pans more strict — only `_panGestureRecognizer` should be rejected, not the entire `UIPanGestureRecognizer` class.
Diffstat (limited to 'platform/ios/src/MGLAnnotationView.mm')
-rw-r--r--platform/ios/src/MGLAnnotationView.mm2
1 files changed, 1 insertions, 1 deletions
diff --git a/platform/ios/src/MGLAnnotationView.mm b/platform/ios/src/MGLAnnotationView.mm
index f8591f036b..7064ccbd76 100644
--- a/platform/ios/src/MGLAnnotationView.mm
+++ b/platform/ios/src/MGLAnnotationView.mm
@@ -235,7 +235,7 @@
{
BOOL isDragging = self.dragState == MGLAnnotationViewDragStateDragging;
- if ([gestureRecognizer isKindOfClass:UIPanGestureRecognizer.class] && !(isDragging))
+ if (gestureRecognizer == _panGestureRecognizer && !(isDragging))
{
return NO;
}