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

Unified Diff: ash/accelerators/accelerator_controller_unittest.cc

Issue 11578044: Enable Search-key modifiers for extended key shortcuts. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: nit Created 8 years 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/accelerators/accelerator_controller.cc ('k') | ash/accelerators/accelerator_table.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/accelerators/accelerator_controller_unittest.cc
diff --git a/ash/accelerators/accelerator_controller_unittest.cc b/ash/accelerators/accelerator_controller_unittest.cc
index 1c5b9bb64e07474cbeaa85608333667cc51319ac..fd1afea520ff635428e6f88bf212c31cc805c0da 100644
--- a/ash/accelerators/accelerator_controller_unittest.cc
+++ b/ash/accelerators/accelerator_controller_unittest.cc
@@ -890,57 +890,13 @@ TEST_F(AcceleratorControllerTest, GlobalAccelerators) {
#endif
}
-TEST_F(AcceleratorControllerTest,
- GlobalAcceleratorsToggleAppListWithoutSearchAsModifier) {
- ShellDelegate* delegate = ash::Shell::GetInstance()->delegate();
-
- EXPECT_FALSE(ash::Shell::GetInstance()->GetAppListTargetVisibility());
-
- // When Search is not acting as a modifier, pressing Search should toggle
- // the AppList
- EXPECT_TRUE(ProcessWithContext(
- ui::Accelerator(ui::VKEY_LWIN, ui::EF_NONE)));
- EXPECT_FALSE(ProcessWithContext(
- ReleaseAccelerator(ui::VKEY_LWIN, ui::EF_NONE)));
- EXPECT_TRUE(ash::Shell::GetInstance()->GetAppListTargetVisibility());
-
- // When spoken feedback is on, the AppList should not toggle.
- delegate->ToggleSpokenFeedback(A11Y_NOTIFICATION_NONE);
- EXPECT_FALSE(ProcessWithContext(
- ui::Accelerator(ui::VKEY_LWIN, ui::EF_NONE)));
- EXPECT_FALSE(ProcessWithContext(
- ReleaseAccelerator(ui::VKEY_LWIN, ui::EF_NONE)));
- delegate->ToggleSpokenFeedback(A11Y_NOTIFICATION_NONE);
- EXPECT_TRUE(ash::Shell::GetInstance()->GetAppListTargetVisibility());
-
- EXPECT_TRUE(ProcessWithContext(
- ui::Accelerator(ui::VKEY_LWIN, ui::EF_NONE)));
- EXPECT_FALSE(ProcessWithContext(
- ReleaseAccelerator(ui::VKEY_LWIN, ui::EF_NONE)));
- EXPECT_FALSE(ash::Shell::GetInstance()->GetAppListTargetVisibility());
-
- // When spoken feedback is on, the AppList should not toggle.
- delegate->ToggleSpokenFeedback(A11Y_NOTIFICATION_NONE);
- EXPECT_FALSE(ProcessWithContext(
- ui::Accelerator(ui::VKEY_LWIN, ui::EF_NONE)));
- EXPECT_FALSE(ProcessWithContext(
- ReleaseAccelerator(ui::VKEY_LWIN, ui::EF_NONE)));
- delegate->ToggleSpokenFeedback(A11Y_NOTIFICATION_NONE);
- EXPECT_FALSE(ash::Shell::GetInstance()->GetAppListTargetVisibility());
-}
-
-TEST_F(AcceleratorControllerTest,
- GlobalAcceleratorsToggleAppListWithSearchAsModifier) {
+TEST_F(AcceleratorControllerTest, GlobalAcceleratorsToggleAppList) {
test::TestShellDelegate* delegate =
reinterpret_cast<test::TestShellDelegate*>(
ash::Shell::GetInstance()->delegate());
- delegate->set_is_search_key_acting_as_function_key(true);
-
EXPECT_FALSE(ash::Shell::GetInstance()->GetAppListTargetVisibility());
- // When Search is acting as a modifier for accessing extended keyboard
- // shortcuts, then the press event should not open the AppList, and the
- // release should instead.
+ // The press event should not open the AppList, the release should instead.
EXPECT_FALSE(ProcessWithContext(
ui::Accelerator(ui::VKEY_LWIN, ui::EF_NONE)));
EXPECT_TRUE(ProcessWithContext(
« no previous file with comments | « ash/accelerators/accelerator_controller.cc ('k') | ash/accelerators/accelerator_table.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698