summaryrefslogtreecommitdiffstats
path: root/ash/drag_drop/drag_drop_tracker_unittest.cc
diff options
context:
space:
mode:
authormazda@chromium.org <mazda@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-09-20 07:15:21 +0000
committermazda@chromium.org <mazda@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-09-20 07:15:21 +0000
commitb702d054bc37c5b1ef65e18798ba8597d904aaa9 (patch)
treecdf92d7436fff2c2e6dcf376140ab9d394d7f4fe /ash/drag_drop/drag_drop_tracker_unittest.cc
parent002db8e3dc0de4a5bd9bb647e8e241a528253d14 (diff)
downloadchromium_src-b702d054bc37c5b1ef65e18798ba8597d904aaa9.zip
chromium_src-b702d054bc37c5b1ef65e18798ba8597d904aaa9.tar.gz
chromium_src-b702d054bc37c5b1ef65e18798ba8597d904aaa9.tar.bz2
Convert native mouse locations to the locations in screen coordinate in RootWindowHostLinux.
Once this CL is landed, event handlers do not need to be aware of native screen coordinates even when passive grab is taken. All the conversions can be done only by way of screen coordinate. This CL depends on http://codereview.chromium.org/10911342/. BUG=148686,148761,146435,146072 Review URL: https://chromiumcodereview.appspot.com/10948020 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@157720 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ash/drag_drop/drag_drop_tracker_unittest.cc')
-rw-r--r--ash/drag_drop/drag_drop_tracker_unittest.cc12
1 files changed, 6 insertions, 6 deletions
diff --git a/ash/drag_drop/drag_drop_tracker_unittest.cc b/ash/drag_drop/drag_drop_tracker_unittest.cc
index a090696..4175c6b 100644
--- a/ash/drag_drop/drag_drop_tracker_unittest.cc
+++ b/ash/drag_drop/drag_drop_tracker_unittest.cc
@@ -89,7 +89,7 @@ TEST_F(DragDropTrackerTest, MAYBE_GetTarget) {
// Start tracking from the RootWindow0 and check the point on RootWindow1 that
// |window1| covers.
- EXPECT_EQ(window1.get(), GetTarget(root_windows[0], gfx::Point(150, 350)));
+ EXPECT_EQ(window1.get(), GetTarget(root_windows[0], gfx::Point(350, 150)));
// Start tracking from the RootWindow0 and check the point on RootWindow1 that
// neither |window0| nor |window1| covers.
@@ -98,7 +98,7 @@ TEST_F(DragDropTrackerTest, MAYBE_GetTarget) {
// Start tracking from the RootWindow1 and check the point on RootWindow0 that
// |window0| covers.
- EXPECT_EQ(window0.get(), GetTarget(root_windows[1], gfx::Point(50, -150)));
+ EXPECT_EQ(window0.get(), GetTarget(root_windows[1], gfx::Point(-150, 50)));
// Start tracking from the RootWindow1 and check the point on RootWindow0 that
// neither |window0| nor |window1| covers.
@@ -154,8 +154,8 @@ TEST_F(DragDropTrackerTest, MAYBE_ConvertMouseEvent) {
// Start tracking from the RootWindow0 and converts the mouse event into
// |window1|'s coodinates.
ui::MouseEvent original01(ui::ET_MOUSE_DRAGGED,
- gfx::Point(150, 350),
- gfx::Point(150, 350),
+ gfx::Point(350, 150),
+ gfx::Point(350, 150),
ui::EF_NONE);
scoped_ptr<ui::MouseEvent> converted01(ConvertMouseEvent(root_windows[0],
window1.get(),
@@ -168,8 +168,8 @@ TEST_F(DragDropTrackerTest, MAYBE_ConvertMouseEvent) {
// Start tracking from the RootWindow1 and converts the mouse event into
// |window0|'s coodinates.
ui::MouseEvent original10(ui::ET_MOUSE_DRAGGED,
- gfx::Point(50, -150),
- gfx::Point(50, -150),
+ gfx::Point(-150, 50),
+ gfx::Point(-150, 50),
ui::EF_NONE);
scoped_ptr<ui::MouseEvent> converted10(ConvertMouseEvent(root_windows[1],
window0.get(),