Title: [287794] trunk/Source/WebKit
Revision
287794
Author
[email protected]
Date
2022-01-07 15:47:41 -0800 (Fri, 07 Jan 2022)

Log Message

[GTK] REGRESSION: Kinetic scrolling via touch-screen behaves oddly
https://bugs.webkit.org/show_bug.cgi?id=234958

Reviewed by Michael Catanzaro.

The swipe signal handler didn't take into account
Scrollbar::pixelsPerLineStep() and also incorrectly negated the
vertical velocity. Ideally, touch scrolling would use precise wheel
events, but as the rest of the code works correctly and scales by this
amount, make the one-line change that conforms with the previous code.

* UIProcess/API/gtk/WebKitWebViewBase.cpp:
(webkitWebViewBaseTouchSwipe):

Modified Paths

Diff

Modified: trunk/Source/WebKit/ChangeLog (287793 => 287794)


--- trunk/Source/WebKit/ChangeLog	2022-01-07 23:47:29 UTC (rev 287793)
+++ trunk/Source/WebKit/ChangeLog	2022-01-07 23:47:41 UTC (rev 287794)
@@ -1,3 +1,19 @@
+2022-01-07  Chris Lord  <[email protected]>
+
+        [GTK] REGRESSION: Kinetic scrolling via touch-screen behaves oddly
+        https://bugs.webkit.org/show_bug.cgi?id=234958
+
+        Reviewed by Michael Catanzaro.
+
+        The swipe signal handler didn't take into account
+        Scrollbar::pixelsPerLineStep() and also incorrectly negated the
+        vertical velocity. Ideally, touch scrolling would use precise wheel
+        events, but as the rest of the code works correctly and scales by this
+        amount, make the one-line change that conforms with the previous code.
+
+        * UIProcess/API/gtk/WebKitWebViewBase.cpp:
+        (webkitWebViewBaseTouchSwipe):
+
 2022-01-07  Patrick Angle  <[email protected]>
 
         REGRESSION(r286498): Web Inspector: Inspector^2 fails to load in release builds and crashes with an assertion in debug builds

Modified: trunk/Source/WebKit/UIProcess/API/gtk/WebKitWebViewBase.cpp (287793 => 287794)


--- trunk/Source/WebKit/UIProcess/API/gtk/WebKitWebViewBase.cpp	2022-01-07 23:47:29 UTC (rev 287793)
+++ trunk/Source/WebKit/UIProcess/API/gtk/WebKitWebViewBase.cpp	2022-01-07 23:47:41 UTC (rev 287794)
@@ -2001,7 +2001,7 @@
                 return;
         }
 
-        webkitWebViewBaseSynthesizeWheelEvent(webViewBase, event, -velocityX, -velocityY, x, y, WheelEventPhase::NoPhase, WheelEventPhase::Began);
+        webkitWebViewBaseSynthesizeWheelEvent(webViewBase, event, -velocityX / Scrollbar::pixelsPerLineStep(), velocityY / Scrollbar::pixelsPerLineStep(), x, y, WheelEventPhase::NoPhase, WheelEventPhase::Began);
     }
 }
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to