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

Unified Diff: ui/events/blink/input_handler_proxy.cc

Issue 2869823003: [VSync Queue] Plug touch ack to gesture events and flush vsync queue if necessary (Closed)
Patch Set: Fix MSAN Use-of-uninitialized-value: Initialize GestureEventDetails Created 3 years, 6 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: ui/events/blink/input_handler_proxy.cc
diff --git a/ui/events/blink/input_handler_proxy.cc b/ui/events/blink/input_handler_proxy.cc
index c797a6852415cc092bdd5990de4fefecd063ddb6..0f26dd9f7641c7c7fd8e21dd283b3544c2f515bc 100644
--- a/ui/events/blink/input_handler_proxy.cc
+++ b/ui/events/blink/input_handler_proxy.cc
@@ -324,6 +324,17 @@ void InputHandlerProxy::HandleInputEventWithLatencyInfo(
}
if (has_ongoing_compositor_scroll_fling_pinch_) {
+ const auto& gesture_event = ToWebGestureEvent(event_with_callback->event());
+ if (gesture_event.source_device == blink::kWebGestureDeviceTouchscreen &&
+ gesture_event.is_source_touch_event_set_non_blocking) {
+ // Dispatch immediately to avoid regression in
+ // |smoothness.tough_scrolling_cases:first_gesture_scroll_update_latency|.
+ compositor_event_queue_->Queue(std::move(event_with_callback),
+ tick_clock_->NowTicks());
+ DispatchQueuedInputEvents();
+ return;
+ }
+
bool needs_animate_input = compositor_event_queue_->empty();
compositor_event_queue_->Queue(std::move(event_with_callback),
tick_clock_->NowTicks());

Powered by Google App Engine
This is Rietveld 408576698