Title: [235236] trunk/Source/WebKit
Revision
235236
Author
[email protected]
Date
2018-08-23 12:51:22 -0700 (Thu, 23 Aug 2018)

Log Message

[Cocoa] First scroll gesture in pinned, non-rubber-banding WKWebView may fail to initiate back/forward swipe
https://bugs.webkit.org/show_bug.cgi?id=188894
<rdar://problem/43651434>

Reviewed by Tim Horton.

* WebProcess/WebPage/EventDispatcher.cpp:
(WebKit::EventDispatcher::wheelEvent): Set the rubber-band state on the ScrollingTree
  synchronously rather than dispatching doing that to the scrolling thread. This is safe to
  do because ScrollingTree synchrnoizes access to the rubber-band state with an internal
  mutex.

Modified Paths

Diff

Modified: trunk/Source/WebKit/ChangeLog (235235 => 235236)


--- trunk/Source/WebKit/ChangeLog	2018-08-23 19:48:16 UTC (rev 235235)
+++ trunk/Source/WebKit/ChangeLog	2018-08-23 19:51:22 UTC (rev 235236)
@@ -1,3 +1,17 @@
+2018-08-23  Dan Bernstein  <[email protected]>
+
+        [Cocoa] First scroll gesture in pinned, non-rubber-banding WKWebView may fail to initiate back/forward swipe
+        https://bugs.webkit.org/show_bug.cgi?id=188894
+        <rdar://problem/43651434>
+
+        Reviewed by Tim Horton.
+
+        * WebProcess/WebPage/EventDispatcher.cpp:
+        (WebKit::EventDispatcher::wheelEvent): Set the rubber-band state on the ScrollingTree
+          synchronously rather than dispatching doing that to the scrolling thread. This is safe to
+          do because ScrollingTree synchrnoizes access to the rubber-band state with an internal
+          mutex.
+
 2018-08-23  Youenn Fablet  <[email protected]>
 
         self.isSecureContext undefined in Service Worker

Modified: trunk/Source/WebKit/WebProcess/WebPage/EventDispatcher.cpp (235235 => 235236)


--- trunk/Source/WebKit/WebProcess/WebPage/EventDispatcher.cpp	2018-08-23 19:48:16 UTC (rev 235235)
+++ trunk/Source/WebKit/WebProcess/WebPage/EventDispatcher.cpp	2018-08-23 19:51:22 UTC (rev 235236)
@@ -119,11 +119,8 @@
         // WebCore should always know the current state and know when it changes so the
         // scrolling tree can be notified.
         // We only need to do this at the beginning of the gesture.
-        if (platformWheelEvent.phase() == PlatformWheelEventPhaseBegan) {
-            ScrollingThread::dispatch([scrollingTree, canRubberBandAtLeft, canRubberBandAtRight, canRubberBandAtTop, canRubberBandAtBottom] {
-                scrollingTree->setCanRubberBandState(canRubberBandAtLeft, canRubberBandAtRight, canRubberBandAtTop, canRubberBandAtBottom);
-            });
-        }
+        if (platformWheelEvent.phase() == PlatformWheelEventPhaseBegan)
+            scrollingTree->setCanRubberBandState(canRubberBandAtLeft, canRubberBandAtRight, canRubberBandAtTop, canRubberBandAtBottom);
 
         ScrollingTree::EventResult result = scrollingTree->tryToHandleWheelEvent(platformWheelEvent);
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to