| Index: content/browser/renderer_host/input/touch_event_queue.cc
|
| diff --git a/content/browser/renderer_host/input/touch_event_queue.cc b/content/browser/renderer_host/input/touch_event_queue.cc
|
| index 14118d0e0c0d9f22d5d14afbf2450433a9315481..fb6cfcdfb7ab4a65964f9886f3042a436b03f4ee 100644
|
| --- a/content/browser/renderer_host/input/touch_event_queue.cc
|
| +++ b/content/browser/renderer_host/input/touch_event_queue.cc
|
| @@ -508,9 +508,14 @@ bool TouchEventQueue::IsPendingAckTouchStart() const {
|
| void TouchEventQueue::SetAckTimeoutEnabled(bool enabled,
|
| size_t ack_timeout_delay_ms) {
|
| if (!enabled) {
|
| - // Avoid resetting |timeout_handler_|, as an outstanding timeout may
|
| - // be active and must be completed for ack handling consistency.
|
| ack_timeout_enabled_ = false;
|
| + if (touch_filtering_state_ == FORWARD_TOUCHES_UNTIL_TIMEOUT)
|
| + touch_filtering_state_ = FORWARD_ALL_TOUCHES;
|
| + // Only reset the |timeout_handler_| if the timer is running and has not yet
|
| + // timed out. This ensures that an already timed out sequence is properly
|
| + // flushed by the handler.
|
| + if (timeout_handler_ && timeout_handler_->IsTimeoutTimerRunning())
|
| + timeout_handler_->Reset();
|
| return;
|
| }
|
|
|
|
|