Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(108)

Unified Diff: content/browser/renderer_host/input/mouse_wheel_event_queue.cc

Issue 2158423002: Wheel scroll latching enabled behind flag. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Scroll latching unit test added. Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/browser/renderer_host/input/mouse_wheel_event_queue.cc
diff --git a/content/browser/renderer_host/input/mouse_wheel_event_queue.cc b/content/browser/renderer_host/input/mouse_wheel_event_queue.cc
index d1d3bc22276279290e8cde1271e27591b76b26e3..60d187dc628995eb5a972fbfcfd563615d768e1d 100644
--- a/content/browser/renderer_host/input/mouse_wheel_event_queue.cc
+++ b/content/browser/renderer_host/input/mouse_wheel_event_queue.cc
@@ -34,13 +34,15 @@ class QueuedWebMouseWheelEvent : public MouseWheelEventWithLatencyInfo {
};
MouseWheelEventQueue::MouseWheelEventQueue(MouseWheelEventQueueClient* client,
- int64_t scroll_transaction_ms)
+ bool enable_scroll_latching)
: client_(client),
needs_scroll_begin_(true),
needs_scroll_end_(false),
- scroll_transaction_ms_(scroll_transaction_ms),
+ enable_scroll_latching_(enable_scroll_latching),
scrolling_device_(blink::WebGestureDeviceUninitialized) {
DCHECK(client);
+ scroll_transaction_ms_ =
+ enable_scroll_latching_ ? kDefaultWheelScrollLatchingTransactionMs : 0;
}
MouseWheelEventQueue::~MouseWheelEventQueue() {

Powered by Google App Engine
This is Rietveld 408576698