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

Unified Diff: ash/drag_drop/drag_drop_controller_unittest.cc

Issue 1260453006: ui: events: Add a class to hold common touch and stylus properties (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address build problems, add accessor and unit tests. Created 5 years, 4 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: ash/drag_drop/drag_drop_controller_unittest.cc
diff --git a/ash/drag_drop/drag_drop_controller_unittest.cc b/ash/drag_drop/drag_drop_controller_unittest.cc
index 20513e1f0491adb5a6abdc5d59d75657cd7e2b3d..7c7f02c1fb03fb55f401ead39144eaa80732777b 100644
--- a/ash/drag_drop/drag_drop_controller_unittest.cc
+++ b/ash/drag_drop/drag_drop_controller_unittest.cc
@@ -720,8 +720,10 @@ TEST_F(DragDropControllerTest, SyntheticEventsDuringDragDrop) {
// EventGenerator since it implicitly turns these into mouse drag events.
// The DragDropController should simply ignore these events.
gfx::Point mouse_move_location = drag_view->bounds().CenterPoint();
- ui::MouseEvent mouse_move(ui::ET_MOUSE_MOVED, mouse_move_location,
- mouse_move_location, ui::EventTimeForNow(), 0, 0);
+ ui::MouseEvent mouse_move(
+ ui::ET_MOUSE_MOVED, mouse_move_location, mouse_move_location,
+ ui::EventTimeForNow(), 0, 0,
+ ui::PointerEventDetails(ui::EventPointerType::POINTER_TYPE_MOUSE));
ui::EventDispatchDetails details = Shell::GetPrimaryRootWindow()->
GetHost()->event_processor()->OnEventFromSource(&mouse_move);
ASSERT_FALSE(details.dispatcher_destroyed);
@@ -1005,15 +1007,17 @@ TEST_F(DragDropControllerTest, DragCancelAcrossDisplays) {
GetDragImageWindow()->AddObserver(&observer);
{
- ui::MouseEvent e(ui::ET_MOUSE_DRAGGED, gfx::Point(200, 0),
- gfx::Point(200, 0), ui::EventTimeForNow(), ui::EF_NONE,
- ui::EF_NONE);
+ ui::MouseEvent e(
+ ui::ET_MOUSE_DRAGGED, gfx::Point(200, 0), gfx::Point(200, 0),
+ ui::EventTimeForNow(), ui::EF_NONE, ui::EF_NONE,
+ ui::PointerEventDetails(ui::EventPointerType::POINTER_TYPE_MOUSE));
drag_drop_controller_->DragUpdate(window, e);
}
{
- ui::MouseEvent e(ui::ET_MOUSE_DRAGGED, gfx::Point(600, 0),
- gfx::Point(600, 0), ui::EventTimeForNow(), ui::EF_NONE,
- ui::EF_NONE);
+ ui::MouseEvent e(
+ ui::ET_MOUSE_DRAGGED, gfx::Point(600, 0), gfx::Point(600, 0),
+ ui::EventTimeForNow(), ui::EF_NONE, ui::EF_NONE,
+ ui::PointerEventDetails(ui::EventPointerType::POINTER_TYPE_MOUSE));
drag_drop_controller_->DragUpdate(window, e);
}
@@ -1038,15 +1042,17 @@ TEST_F(DragDropControllerTest, DragCancelAcrossDisplays) {
GetDragImageWindow()->AddObserver(&observer);
{
- ui::MouseEvent e(ui::ET_MOUSE_DRAGGED, gfx::Point(600, 0),
- gfx::Point(600, 0), ui::EventTimeForNow(), ui::EF_NONE,
- ui::EF_NONE);
+ ui::MouseEvent e(
+ ui::ET_MOUSE_DRAGGED, gfx::Point(600, 0), gfx::Point(600, 0),
+ ui::EventTimeForNow(), ui::EF_NONE, ui::EF_NONE,
+ ui::PointerEventDetails(ui::EventPointerType::POINTER_TYPE_MOUSE));
drag_drop_controller_->DragUpdate(window, e);
}
{
- ui::MouseEvent e(ui::ET_MOUSE_DRAGGED, gfx::Point(200, 0),
- gfx::Point(200, 0), ui::EventTimeForNow(), ui::EF_NONE,
- ui::EF_NONE);
+ ui::MouseEvent e(
+ ui::ET_MOUSE_DRAGGED, gfx::Point(200, 0), gfx::Point(200, 0),
+ ui::EventTimeForNow(), ui::EF_NONE, ui::EF_NONE,
+ ui::PointerEventDetails(ui::EventPointerType::POINTER_TYPE_MOUSE));
drag_drop_controller_->DragUpdate(window, e);
}

Powered by Google App Engine
This is Rietveld 408576698