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

Unified Diff: ash/root_window_controller_unittest.cc

Issue 21519002: Prevent mouse from getting stuck on second display in login (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: don't create target window if a session is already active Created 7 years, 5 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
« no previous file with comments | « ash/root_window_controller.cc ('k') | ash/test/ash_test_base.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/root_window_controller_unittest.cc
diff --git a/ash/root_window_controller_unittest.cc b/ash/root_window_controller_unittest.cc
index b27cc52ca1ad3b59c8b4a4b4de12a28e2b7e3c4d..0d40125b90f1c3551ff35a0fb527eec3958a3c3c 100644
--- a/ash/root_window_controller_unittest.cc
+++ b/ash/root_window_controller_unittest.cc
@@ -473,5 +473,24 @@ TEST_F(RootWindowControllerTest, FocusBlockedWindow) {
}
}
+typedef test::NoSessionAshTestBase NoSessionRootWindowControllerTest;
+
+// Make sure that an event handler exists for entire display area.
+TEST_F(NoSessionRootWindowControllerTest, Event) {
+ aura::RootWindow* root = Shell::GetPrimaryRootWindow();
+ const gfx::Size size = root->bounds().size();
+ aura::Window* event_target = root->GetEventHandlerForPoint(gfx::Point(0, 0));
+ EXPECT_TRUE(event_target);
+ EXPECT_EQ(event_target,
+ root->GetEventHandlerForPoint(gfx::Point(0, size.height() - 1)));
+ EXPECT_EQ(event_target,
+ root->GetEventHandlerForPoint(gfx::Point(size.width() - 1, 0)));
+ EXPECT_EQ(event_target,
+ root->GetEventHandlerForPoint(gfx::Point(0, size.height() - 1)));
+ EXPECT_EQ(event_target,
+ root->GetEventHandlerForPoint(
+ gfx::Point(size.width() - 1, size.height() - 1)));
+}
+
} // namespace test
} // namespace ash
« no previous file with comments | « ash/root_window_controller.cc ('k') | ash/test/ash_test_base.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698