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

Side by Side Diff: content/renderer/input/input_handler_proxy.cc

Issue 124283003: Reenable overlay scrollbars (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add CHECK() call 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/renderer/input/input_handler_proxy.h" 5 #include "content/renderer/input/input_handler_proxy.h"
6 6
7 #include "base/debug/trace_event.h" 7 #include "base/debug/trace_event.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/metrics/histogram.h" 9 #include "base/metrics/histogram.h"
10 #include "content/renderer/input/input_handler_proxy_client.h" 10 #include "content/renderer/input/input_handler_proxy_client.h"
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
222 for (size_t i = 0; i < touch_event.touchesLength; ++i) { 222 for (size_t i = 0; i < touch_event.touchesLength; ++i) {
223 if (touch_event.touches[i].state != WebTouchPoint::StatePressed) 223 if (touch_event.touches[i].state != WebTouchPoint::StatePressed)
224 continue; 224 continue;
225 if (input_handler_->HaveTouchEventHandlersAt(touch_event.touches[i] 225 if (input_handler_->HaveTouchEventHandlersAt(touch_event.touches[i]
226 .position)) 226 .position))
227 return DID_NOT_HANDLE; 227 return DID_NOT_HANDLE;
228 } 228 }
229 return DROP_EVENT; 229 return DROP_EVENT;
230 } else if (WebInputEvent::isKeyboardEventType(event.type)) { 230 } else if (WebInputEvent::isKeyboardEventType(event.type)) {
231 CancelCurrentFling(); 231 CancelCurrentFling();
232 } else if (event.type == WebInputEvent::MouseMove) {
233 const WebMouseEvent& mouse_event =
234 *static_cast<const WebMouseEvent*>(&event);
235 // TODO(tony): Ignore when mouse buttons are down?
236 // TODO(davemoore): This should never happen, but bug #326635 showed some
237 // surprising crashes.
238 CHECK(input_handler_);
239 input_handler_->MouseMoveAt(gfx::Point(mouse_event.x, mouse_event.y));
232 } 240 }
233 241
234 return DID_NOT_HANDLE; 242 return DID_NOT_HANDLE;
235 } 243 }
236 244
237 InputHandlerProxy::EventDisposition 245 InputHandlerProxy::EventDisposition
238 InputHandlerProxy::HandleGestureFling( 246 InputHandlerProxy::HandleGestureFling(
239 const WebGestureEvent& gesture_event) { 247 const WebGestureEvent& gesture_event) {
240 cc::InputHandler::ScrollStatus scroll_status; 248 cc::InputHandler::ScrollStatus scroll_status;
241 249
(...skipping 225 matching lines...) Expand 10 before | Expand all | Expand 10 after
467 TRACE_EVENT2("renderer", 475 TRACE_EVENT2("renderer",
468 "InputHandlerProxy::notifyCurrentFlingVelocity", 476 "InputHandlerProxy::notifyCurrentFlingVelocity",
469 "vx", 477 "vx",
470 velocity.width, 478 velocity.width,
471 "vy", 479 "vy",
472 velocity.height); 480 velocity.height);
473 input_handler_->NotifyCurrentFlingVelocity(ToClientScrollIncrement(velocity)); 481 input_handler_->NotifyCurrentFlingVelocity(ToClientScrollIncrement(velocity));
474 } 482 }
475 483
476 } // namespace content 484 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698