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

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

Issue 140253005: Add touch scrolling modes experimental flags (DEPRECATED) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Update for eager GR Created 6 years, 11 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/gesture_event_queue.cc
diff --git a/content/browser/renderer_host/input/gesture_event_queue.cc b/content/browser/renderer_host/input/gesture_event_queue.cc
index 6333de09646b4921801840f7026e742ee3888241..2265ef08c2bc7d3d119ec273f1877075a054db35 100644
--- a/content/browser/renderer_host/input/gesture_event_queue.cc
+++ b/content/browser/renderer_host/input/gesture_event_queue.cc
@@ -72,7 +72,6 @@ void GestureEventQueue::OnTouchEventAck(InputEventAckState ack_state) {
}
GestureSequence& sequence = Head();
- sequence.UpdateState(ack_state);
// Dispatch the packet corresponding to the ack'ed touch, as well as any
// additional timeout-based packets queued before the ack was received.
@@ -86,10 +85,16 @@ void GestureEventQueue::OnTouchEventAck(InputEventAckState ack_state) {
// given ack.
if (touch_packet_for_current_ack_handled)
break;
+ if (!packet.is_independent())
+ sequence.UpdateState(ack_state);
touch_packet_for_current_ack_handled = true;
}
- if (!sequence.IsGesturePrevented())
+ // In addition to the global filtering state, independent packets may be
+ // suppressed individually by their local touch ack state.
+ if (!sequence.IsGesturePrevented() &&
+ !(packet.is_independent() &&
+ ack_state == INPUT_EVENT_ACK_STATE_CONSUMED))
SendPacket(packet);
sequence.Pop();

Powered by Google App Engine
This is Rietveld 408576698