Title: [243351] trunk/Source/WebKit
Revision
243351
Author
[email protected]
Date
2019-03-21 18:03:18 -0700 (Thu, 21 Mar 2019)

Log Message

Long press gesture recognizers in WKWebView are conflicting with internal scroll view long press gesture recognizers
https://bugs.webkit.org/show_bug.cgi?id=195726
rdar://problem/48582449

Patch by James Magahern <[email protected]> on 2019-03-21
Reviewed by Megan Gardner.

We just need to add another clause to WKContentViewInteraction's
canPreventGestureRecognizer whitelist.

* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView gestureRecognizer:canPreventGestureRecognizer:]):

Modified Paths

Diff

Modified: trunk/Source/WebKit/ChangeLog (243350 => 243351)


--- trunk/Source/WebKit/ChangeLog	2019-03-22 00:49:18 UTC (rev 243350)
+++ trunk/Source/WebKit/ChangeLog	2019-03-22 01:03:18 UTC (rev 243351)
@@ -1,3 +1,17 @@
+2019-03-21  James Magahern  <[email protected]>
+
+        Long press gesture recognizers in WKWebView are conflicting with internal scroll view long press gesture recognizers
+        https://bugs.webkit.org/show_bug.cgi?id=195726
+        rdar://problem/48582449
+
+        Reviewed by Megan Gardner.
+
+        We just need to add another clause to WKContentViewInteraction's
+        canPreventGestureRecognizer whitelist. 
+
+        * UIProcess/ios/WKContentViewInteraction.mm:
+        (-[WKContentView gestureRecognizer:canPreventGestureRecognizer:]):
+
 2019-03-21  Simon Fraser  <[email protected]>
 
         [iOS WK2] Turn on async overflow scrolling by default

Modified: trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm (243350 => 243351)


--- trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm	2019-03-22 00:49:18 UTC (rev 243350)
+++ trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm	2019-03-22 01:03:18 UTC (rev 243351)
@@ -1686,6 +1686,10 @@
     return _page->editorState().postLayoutData().focusedElementRect;
 }
 
+#if USE(APPLE_INTERNAL_SDK) && __has_include(<WebKitAdditions/WKContentViewInteraction.mm>)
+#include <WebKitAdditions/WKContentViewInteraction.mm>
+#else
+
 - (BOOL)gestureRecognizer:(UIGestureRecognizer *)preventingGestureRecognizer canPreventGestureRecognizer:(UIGestureRecognizer *)preventedGestureRecognizer
 {
     // A long-press gesture can not be recognized while panning, but a pan can be recognized
@@ -1695,6 +1699,8 @@
         && ([preventedGestureRecognizer isKindOfClass:NSClassFromString(@"UIScrollViewPanGestureRecognizer")] || [preventedGestureRecognizer isKindOfClass:NSClassFromString(@"UIScrollViewPinchGestureRecognizer")]));
 }
 
+#endif
+
 - (BOOL)gestureRecognizer:(UIGestureRecognizer *)preventedGestureRecognizer canBePreventedByGestureRecognizer:(UIGestureRecognizer *)preventingGestureRecognizer {
     // Don't allow the highlight to be prevented by a selection gesture. Press-and-hold on a link should highlight the link, not select it.
     bool isForcePressGesture = NO;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to