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

Side by Side Diff: ui/events/blink/input_handler_proxy.cc

Issue 2931703002: Don't fade in overlay scrollbar when user interacting the content under scrollbar. (Closed)
Patch Set: Created 3 years, 6 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
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 "ui/events/blink/input_handler_proxy.h" 5 #include "ui/events/blink/input_handler_proxy.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 10
(...skipping 501 matching lines...) Expand 10 before | Expand all | Expand 10 after
512 input_handler_->MouseUp(); 512 input_handler_->MouseUp();
513 } 513 }
514 return DID_NOT_HANDLE; 514 return DID_NOT_HANDLE;
515 } 515 }
516 case WebInputEvent::kMouseMove: { 516 case WebInputEvent::kMouseMove: {
517 const WebMouseEvent& mouse_event = 517 const WebMouseEvent& mouse_event =
518 static_cast<const WebMouseEvent&>(event); 518 static_cast<const WebMouseEvent&>(event);
519 // TODO(davemoore): This should never happen, but bug #326635 showed some 519 // TODO(davemoore): This should never happen, but bug #326635 showed some
520 // surprising crashes. 520 // surprising crashes.
521 CHECK(input_handler_); 521 CHECK(input_handler_);
522 bool is_mouse_down =
523 mouse_event.button == blink::WebMouseEvent::Button::kLeft;
522 input_handler_->MouseMoveAt(gfx::Point(mouse_event.PositionInWidget().x, 524 input_handler_->MouseMoveAt(gfx::Point(mouse_event.PositionInWidget().x,
523 mouse_event.PositionInWidget().y)); 525 mouse_event.PositionInWidget().y),
526 is_mouse_down);
524 return DID_NOT_HANDLE; 527 return DID_NOT_HANDLE;
525 } 528 }
526 case WebInputEvent::kMouseLeave: { 529 case WebInputEvent::kMouseLeave: {
527 CHECK(input_handler_); 530 CHECK(input_handler_);
528 input_handler_->MouseLeave(); 531 input_handler_->MouseLeave();
529 return DID_NOT_HANDLE; 532 return DID_NOT_HANDLE;
530 } 533 }
531 534
532 default: 535 default:
533 if (WebInputEvent::IsKeyboardEventType(event.GetType())) { 536 if (WebInputEvent::IsKeyboardEventType(event.GetType())) {
(...skipping 1127 matching lines...) Expand 10 before | Expand all | Expand 10 after
1661 scroll_elasticity_controller_->GetWeakPtr(), gesture_event, 1664 scroll_elasticity_controller_->GetWeakPtr(), gesture_event,
1662 scroll_result)); 1665 scroll_result));
1663 } 1666 }
1664 1667
1665 void InputHandlerProxy::SetTickClockForTesting( 1668 void InputHandlerProxy::SetTickClockForTesting(
1666 std::unique_ptr<base::TickClock> tick_clock) { 1669 std::unique_ptr<base::TickClock> tick_clock) {
1667 tick_clock_ = std::move(tick_clock); 1670 tick_clock_ = std::move(tick_clock);
1668 } 1671 }
1669 1672
1670 } // namespace ui 1673 } // namespace ui
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698