Title: [241900] trunk/Source
Revision
241900
Author
[email protected]
Date
2019-02-21 13:43:43 -0800 (Thu, 21 Feb 2019)

Log Message

Move UIWebTouchEventsGestureRecognizer.activeTouchesByIdentifier to SPI
https://bugs.webkit.org/show_bug.cgi?id=194531
<rdar://problem/47714562>

Patch by Antoine Quint <[email protected]> on 2019-02-21
Reviewed by Tim Horton.

Follow-up commit to ensure this SPI is only called on newer versions of iOS.

Source/WebKit:

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

Source/WTF:

* wtf/Platform.h:

Modified Paths

Diff

Modified: trunk/Source/WTF/ChangeLog (241899 => 241900)


--- trunk/Source/WTF/ChangeLog	2019-02-21 21:34:26 UTC (rev 241899)
+++ trunk/Source/WTF/ChangeLog	2019-02-21 21:43:43 UTC (rev 241900)
@@ -1,3 +1,15 @@
+2019-02-21  Antoine Quint  <[email protected]>
+
+        Move UIWebTouchEventsGestureRecognizer.activeTouchesByIdentifier to SPI
+        https://bugs.webkit.org/show_bug.cgi?id=194531
+        <rdar://problem/47714562>
+
+        Reviewed by Tim Horton.
+
+        Follow-up commit to ensure this SPI is only called on newer versions of iOS.
+
+        * wtf/Platform.h:
+
 2019-02-21  Dean Jackson  <[email protected]>
 
         Rotation animations sometimes use the wrong origin (affects apple.com)

Modified: trunk/Source/WTF/wtf/Platform.h (241899 => 241900)


--- trunk/Source/WTF/wtf/Platform.h	2019-02-21 21:34:26 UTC (rev 241899)
+++ trunk/Source/WTF/wtf/Platform.h	2019-02-21 21:43:43 UTC (rev 241900)
@@ -1512,3 +1512,7 @@
 #elif PLATFORM(IOS_FAMILY)
 #define ENABLE_MONOSPACE_FONT_EXCEPTION (__IPHONE_OS_VERSION_MIN_REQUIRED < 130000)
 #endif
+
+#if PLATFORM(IOS_FAMILY) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 130000
+#define HAVE_UI_WEB_TOUCH_EVENTS_GESTURE_RECOGNIZER_WITH_ACTIVE_TOUCHES_BY_ID 1
+#endif

Modified: trunk/Source/WebKit/ChangeLog (241899 => 241900)


--- trunk/Source/WebKit/ChangeLog	2019-02-21 21:34:26 UTC (rev 241899)
+++ trunk/Source/WebKit/ChangeLog	2019-02-21 21:43:43 UTC (rev 241900)
@@ -1,3 +1,16 @@
+2019-02-21  Antoine Quint  <[email protected]>
+
+        Move UIWebTouchEventsGestureRecognizer.activeTouchesByIdentifier to SPI
+        https://bugs.webkit.org/show_bug.cgi?id=194531
+        <rdar://problem/47714562>
+
+        Reviewed by Tim Horton.
+
+        Follow-up commit to ensure this SPI is only called on newer versions of iOS.
+
+        * UIProcess/ios/WKContentViewInteraction.mm:
+        (-[WKContentView cancelPointersForGestureRecognizer:]):
+
 2019-02-21  Tim Horton  <[email protected]>
 
         Crash under RemoteLayerTreePropertyApplier::applyProperties when reattaching to old process

Modified: trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm (241899 => 241900)


--- trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm	2019-02-21 21:34:26 UTC (rev 241899)
+++ trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm	2019-02-21 21:43:43 UTC (rev 241900)
@@ -1188,10 +1188,8 @@
 #if ENABLE(POINTER_EVENTS)
 - (void)cancelPointersForGestureRecognizer:(UIGestureRecognizer *)gestureRecognizer
 {
+#if HAVE(UI_WEB_TOUCH_EVENTS_GESTURE_RECOGNIZER_WITH_ACTIVE_TOUCHES_BY_ID)
     // FIXME: <rdar://problem/48035706>
-    if (![_touchEventGestureRecognizer respondsToSelector:@selector(activeTouchesByIdentifier)])
-        return;
-
     NSMapTable<NSNumber *, UITouch *> *activeTouches = [_touchEventGestureRecognizer activeTouchesByIdentifier];
     for (NSNumber *touchIdentifier in activeTouches) {
         UITouch *touch = [activeTouches objectForKey:touchIdentifier];
@@ -1198,6 +1196,7 @@
         if ([touch.gestureRecognizers containsObject:gestureRecognizer])
             _page->cancelPointer([touchIdentifier unsignedIntValue], WebCore::roundedIntPoint([touch locationInView:self]));
     }
+#endif
 }
 #endif
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to