| Index: content/browser/renderer_host/input/input_router_impl.cc
|
| diff --git a/content/browser/renderer_host/input/input_router_impl.cc b/content/browser/renderer_host/input/input_router_impl.cc
|
| index 558f5857b1e3232755d5e123fdd3140c2629b4f6..ee60cabf3957ec49dbd6a57a415e355234d93bff 100644
|
| --- a/content/browser/renderer_host/input/input_router_impl.cc
|
| +++ b/content/browser/renderer_host/input/input_router_impl.cc
|
| @@ -55,18 +55,18 @@ namespace {
|
| // conditional compilation here, we should instead use an InputRouter::Settings
|
| // construct, supplied and customized by the RenderWidgetHostView. See
|
| // crbug.com/343917.
|
| -bool GetTouchAckTimeoutDelayMs(size_t* touch_ack_timeout_delay_ms) {
|
| +bool GetTouchAckTimeoutDelay(base::TimeDelta* touch_ack_timeout_delay) {
|
| CommandLine* parsed_command_line = CommandLine::ForCurrentProcess();
|
| if (!parsed_command_line->HasSwitch(switches::kTouchAckTimeoutDelayMs))
|
| return false;
|
|
|
| std::string timeout_string = parsed_command_line->GetSwitchValueASCII(
|
| switches::kTouchAckTimeoutDelayMs);
|
| - size_t timeout_value;
|
| - if (!base::StringToSizeT(timeout_string, &timeout_value))
|
| + size_t timeout_ms;
|
| + if (!base::StringToSizeT(timeout_string, &timeout_ms))
|
| return false;
|
|
|
| - *touch_ack_timeout_delay_ms = timeout_value;
|
| + *touch_ack_timeout_delay = base::TimeDelta::FromMilliseconds(timeout_ms);
|
| return true;
|
| }
|
|
|
| @@ -146,7 +146,6 @@ InputRouterImpl::InputRouterImpl(IPC::Sender* sender,
|
| mouse_move_pending_(false),
|
| mouse_wheel_pending_(false),
|
| touch_ack_timeout_supported_(false),
|
| - touch_ack_timeout_delay_ms_(std::numeric_limits<size_t>::max()),
|
| current_view_flags_(0),
|
| current_ack_source_(ACK_SOURCE_NONE),
|
| gesture_event_queue_(new GestureEventQueue(this, this)) {
|
| @@ -156,7 +155,7 @@ InputRouterImpl::InputRouterImpl(IPC::Sender* sender,
|
| touch_event_queue_.reset(new TouchEventQueue(
|
| this, GetTouchScrollingMode(), GetTouchMoveSlopSuppressionLengthDips()));
|
| touch_ack_timeout_supported_ =
|
| - GetTouchAckTimeoutDelayMs(&touch_ack_timeout_delay_ms_);
|
| + GetTouchAckTimeoutDelay(&touch_ack_timeout_delay_);
|
| UpdateTouchAckTimeoutEnabled();
|
| }
|
|
|
| @@ -787,7 +786,7 @@ void InputRouterImpl::SimulateTouchGestureWithMouse(
|
|
|
| void InputRouterImpl::UpdateTouchAckTimeoutEnabled() {
|
| if (!touch_ack_timeout_supported_) {
|
| - touch_event_queue_->SetAckTimeoutEnabled(false, 0);
|
| + touch_event_queue_->SetAckTimeoutEnabled(false, base::TimeDelta());
|
| return;
|
| }
|
|
|
| @@ -806,7 +805,7 @@ void InputRouterImpl::UpdateTouchAckTimeoutEnabled() {
|
| !mobile_viewport &&
|
| !touch_action_none;
|
| touch_event_queue_->SetAckTimeoutEnabled(touch_ack_timeout_enabled,
|
| - touch_ack_timeout_delay_ms_);
|
| + touch_ack_timeout_delay_);
|
| }
|
|
|
| bool InputRouterImpl::IsInOverscrollGesture() const {
|
|
|