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

Unified Diff: ui/views/touchui/touch_selection_controller_impl_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: ui/views/touchui/touch_selection_controller_impl_unittest.cc
diff --git a/ui/views/touchui/touch_selection_controller_impl_unittest.cc b/ui/views/touchui/touch_selection_controller_impl_unittest.cc
index b9df2ec3b32a83aae4a2ab32c8722e4915b46da4..7a56d9479c8f85bbcb13ffa6f507ec3efbacef63 100644
--- a/ui/views/touchui/touch_selection_controller_impl_unittest.cc
+++ b/ui/views/touchui/touch_selection_controller_impl_unittest.cc
@@ -732,8 +732,10 @@ TEST_F(TouchSelectionControllerImplTest, HandlesStackAboveParent) {
// end touch editing.
StartTouchEditing();
gfx::Point test_point = GetCursorHandleDragPoint();
- ui::MouseEvent test_event1(ui::ET_MOUSE_MOVED, test_point, test_point,
- ui::EventTimeForNow(), ui::EF_NONE, ui::EF_NONE);
+ ui::MouseEvent test_event1(
+ ui::ET_MOUSE_MOVED, test_point, test_point, ui::EventTimeForNow(),
+ ui::EF_NONE, ui::EF_NONE,
+ ui::PointerEventDetails(ui::EventPointerType::POINTER_TYPE_MOUSE));
EXPECT_EQ(GetCursorHandleNativeView(),
targeter->FindTargetForEvent(root, &test_event1));
EndTouchEditing();
@@ -745,15 +747,19 @@ TEST_F(TouchSelectionControllerImplTest, HandlesStackAboveParent) {
// Start touch editing (in the first window) and check that the handle is not
// above the second window.
StartTouchEditing();
- ui::MouseEvent test_event2(ui::ET_MOUSE_MOVED, test_point, test_point,
- ui::EventTimeForNow(), ui::EF_NONE, ui::EF_NONE);
+ ui::MouseEvent test_event2(
+ ui::ET_MOUSE_MOVED, test_point, test_point, ui::EventTimeForNow(),
+ ui::EF_NONE, ui::EF_NONE,
+ ui::PointerEventDetails(ui::EventPointerType::POINTER_TYPE_MOUSE));
EXPECT_EQ(window2, targeter->FindTargetForEvent(root, &test_event2));
// Move the first window to top and check that the handle is kept above the
// first window.
window1->GetRootWindow()->StackChildAtTop(window1);
- ui::MouseEvent test_event3(ui::ET_MOUSE_MOVED, test_point, test_point,
- ui::EventTimeForNow(), ui::EF_NONE, ui::EF_NONE);
+ ui::MouseEvent test_event3(
+ ui::ET_MOUSE_MOVED, test_point, test_point, ui::EventTimeForNow(),
+ ui::EF_NONE, ui::EF_NONE,
+ ui::PointerEventDetails(ui::EventPointerType::POINTER_TYPE_MOUSE));
EXPECT_EQ(GetCursorHandleNativeView(),
targeter->FindTargetForEvent(root, &test_event3));
}

Powered by Google App Engine
This is Rietveld 408576698