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

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

Issue 367173003: [Android] Implementation of overscroll effect for Android L (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Code review Created 6 years, 4 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
« no previous file with comments | « content/content_common.gypi ('k') | content/renderer/input/input_handler_proxy.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/input/input_event_filter.cc
diff --git a/content/renderer/input/input_event_filter.cc b/content/renderer/input/input_event_filter.cc
index fa31658a74bcaeab9f63aae77d9c4c1f00208f1a..5017cb4b5f074d1dbb228fc9e3fc85698d990868 100644
--- a/content/renderer/input/input_event_filter.cc
+++ b/content/renderer/input/input_event_filter.cc
@@ -164,12 +164,14 @@ void InputEventFilter::ForwardToHandler(const IPC::Message& message) {
bool is_keyboard_shortcut = params.c;
DCHECK(event);
+ const bool send_ack = !WebInputEventTraits::IgnoresAckDisposition(*event);
+
// Intercept |DidOverscroll| notifications, bundling any triggered overscroll
// response with the input event ack.
scoped_ptr<DidOverscrollParams> overscroll_params;
base::AutoReset<scoped_ptr<DidOverscrollParams>*>
- auto_reset_current_overscroll_params(&current_overscroll_params_,
- &overscroll_params);
+ auto_reset_current_overscroll_params(
+ &current_overscroll_params_, send_ack ? &overscroll_params : NULL);
InputEventAckState ack_state = handler_.Run(routing_id, event, &latency_info);
@@ -188,7 +190,7 @@ void InputEventFilter::ForwardToHandler(const IPC::Message& message) {
return;
}
- if (WebInputEventTraits::IgnoresAckDisposition(*event))
+ if (!send_ack)
return;
InputHostMsg_HandleInputEvent_ACK_Params ack;
« no previous file with comments | « content/content_common.gypi ('k') | content/renderer/input/input_handler_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698