Index: ash/wm/window_manager_unittest.cc |
diff --git a/ash/wm/window_manager_unittest.cc b/ash/wm/window_manager_unittest.cc |
index b99bbb841bd58effd0fd5f40d0d4f4d425ea3843..b7ceac174e17dea01b8ca03e7962b825d0258697 100644 |
--- a/ash/wm/window_manager_unittest.cc |
+++ b/ash/wm/window_manager_unittest.cc |
@@ -598,6 +598,10 @@ TEST_F(WindowManagerTest, UpdateCursorVisibility) { |
ui::ET_TOUCH_PRESSED, gfx::Point(0, 0), 0, getTime()); |
ui::TouchEvent touch_pressed2( |
ui::ET_TOUCH_PRESSED, gfx::Point(0, 0), 1, getTime()); |
+ ui::TouchEvent touch_released1( |
+ ui::ET_TOUCH_RELEASED, gfx::Point(0, 0), 0, getTime()); |
+ ui::TouchEvent touch_released2( |
+ ui::ET_TOUCH_RELEASED, gfx::Point(0, 0), 1, getTime()); |
root_window->AsRootWindowHostDelegate()->OnHostMouseEvent(&mouse_moved); |
EXPECT_TRUE(cursor_manager->cursor_visible()); |
@@ -605,6 +609,8 @@ TEST_F(WindowManagerTest, UpdateCursorVisibility) { |
EXPECT_FALSE(cursor_manager->cursor_visible()); |
root_window->AsRootWindowHostDelegate()->OnHostMouseEvent(&mouse_moved); |
EXPECT_TRUE(cursor_manager->cursor_visible()); |
+ root_window->AsRootWindowHostDelegate()->OnHostTouchEvent(&touch_released1); |
+ EXPECT_TRUE(cursor_manager->cursor_visible()); |
// If someone else made cursor invisible keep it invisible even after it |
// received mouse events. |
@@ -615,6 +621,8 @@ TEST_F(WindowManagerTest, UpdateCursorVisibility) { |
EXPECT_FALSE(cursor_manager->cursor_visible()); |
root_window->AsRootWindowHostDelegate()->OnHostMouseEvent(&mouse_moved); |
EXPECT_FALSE(cursor_manager->cursor_visible()); |
+ root_window->AsRootWindowHostDelegate()->OnHostTouchEvent(&touch_released2); |
+ EXPECT_FALSE(cursor_manager->cursor_visible()); |
// Back to normal. |
cursor_manager->ShowCursor(true); |
@@ -624,6 +632,8 @@ TEST_F(WindowManagerTest, UpdateCursorVisibility) { |
EXPECT_FALSE(cursor_manager->cursor_visible()); |
root_window->AsRootWindowHostDelegate()->OnHostMouseEvent(&mouse_moved); |
EXPECT_TRUE(cursor_manager->cursor_visible()); |
+ root_window->AsRootWindowHostDelegate()->OnHostTouchEvent(&touch_released2); |
+ EXPECT_TRUE(cursor_manager->cursor_visible()); |
} |
} // namespace ash |