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

Unified Diff: content/renderer/input/render_widget_input_handler.cc

Issue 2813683002: Allow MainThreadEventQueue to call the RenderWidget directly. (Closed)
Patch Set: Fix style nits Created 3 years, 8 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/renderer/input/render_widget_input_handler.cc
diff --git a/content/renderer/input/render_widget_input_handler.cc b/content/renderer/input/render_widget_input_handler.cc
index cd39030add30fa2ee44c52377241b30209da95c5..047ba037ed313e62496b4a4bf3cb1d1850ee5964 100644
--- a/content/renderer/input/render_widget_input_handler.cc
+++ b/content/renderer/input/render_widget_input_handler.cc
@@ -207,7 +207,7 @@ RenderWidgetInputHandler::RenderWidgetInputHandler(
RenderWidgetInputHandler::~RenderWidgetInputHandler() {}
-void RenderWidgetInputHandler::HandleInputEvent(
+InputEventAckState RenderWidgetInputHandler::HandleInputEvent(
const blink::WebCoalescedInputEvent& coalesced_event,
const ui::LatencyInfo& latency_info,
InputEventDispatchType dispatch_type) {
@@ -393,16 +393,7 @@ void RenderWidgetInputHandler::HandleInputEvent(
TRACE_EVENT_SYNTHETIC_DELAY_END("blink.HandleInputEvent");
- if (dispatch_type == DISPATCH_TYPE_BLOCKING_NOTIFY_MAIN ||
- dispatch_type == DISPATCH_TYPE_NON_BLOCKING_NOTIFY_MAIN) {
- // |non_blocking| means it was ack'd already by the InputHandlerProxy
- // so let the delegate know the event has been handled.
- delegate_->NotifyInputEventHandled(input_event.GetType(), processed,
- ack_result);
- }
-
- if ((dispatch_type == DISPATCH_TYPE_BLOCKING ||
- dispatch_type == DISPATCH_TYPE_BLOCKING_NOTIFY_MAIN)) {
+ if (dispatch_type == DISPATCH_TYPE_BLOCKING) {
std::unique_ptr<InputEventAck> response(new InputEventAck(
InputEventAckSource::MAIN_THREAD, input_event.GetType(), ack_result,
swap_latency_info, std::move(event_overscroll),
@@ -448,6 +439,7 @@ void RenderWidgetInputHandler::HandleInputEvent(
delegate_->FocusChangeComplete();
}
#endif
+ return ack_result;
}
void RenderWidgetInputHandler::DidOverscrollFromBlink(
« no previous file with comments | « content/renderer/input/render_widget_input_handler.h ('k') | content/renderer/input/render_widget_input_handler_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698