OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "ash/accelerators/accelerator_table.h" | 5 #include "ash/accelerators/accelerator_table.h" |
6 | 6 |
7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
8 | 8 |
9 namespace ash { | 9 namespace ash { |
10 | 10 |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 { true, ui::VKEY_M, ui::EF_SHIFT_DOWN | ui::EF_ALT_DOWN, | 68 { true, ui::VKEY_M, ui::EF_SHIFT_DOWN | ui::EF_ALT_DOWN, |
69 OPEN_FILE_MANAGER }, | 69 OPEN_FILE_MANAGER }, |
70 { true, ui::VKEY_T, ui::EF_CONTROL_DOWN | ui::EF_ALT_DOWN, OPEN_CROSH }, | 70 { true, ui::VKEY_T, ui::EF_CONTROL_DOWN | ui::EF_ALT_DOWN, OPEN_CROSH }, |
71 { true, ui::VKEY_G, ui::EF_SHIFT_DOWN | ui::EF_CONTROL_DOWN | ui::EF_ALT_DOWN, | 71 { true, ui::VKEY_G, ui::EF_SHIFT_DOWN | ui::EF_CONTROL_DOWN | ui::EF_ALT_DOWN, |
72 DISABLE_GPU_WATCHDOG }, | 72 DISABLE_GPU_WATCHDOG }, |
73 #endif // defined(OS_CHROMEOS) | 73 #endif // defined(OS_CHROMEOS) |
74 { true, ui::VKEY_I, ui::EF_SHIFT_DOWN | ui::EF_ALT_DOWN, OPEN_FEEDBACK_PAGE }, | 74 { true, ui::VKEY_I, ui::EF_SHIFT_DOWN | ui::EF_ALT_DOWN, OPEN_FEEDBACK_PAGE }, |
75 #if !defined(OS_WIN) | 75 #if !defined(OS_WIN) |
76 { true, ui::VKEY_Q, ui::EF_SHIFT_DOWN | ui::EF_CONTROL_DOWN, EXIT }, | 76 { true, ui::VKEY_Q, ui::EF_SHIFT_DOWN | ui::EF_CONTROL_DOWN, EXIT }, |
77 #endif | 77 #endif |
78 { true, ui::VKEY_Z, ui::EF_CONTROL_DOWN | ui::EF_ALT_DOWN, | |
79 TOGGLE_SPOKEN_FEEDBACK }, | |
80 { true, ui::VKEY_I, ui::EF_CONTROL_DOWN | ui::EF_ALT_DOWN, | 78 { true, ui::VKEY_I, ui::EF_CONTROL_DOWN | ui::EF_ALT_DOWN, |
81 TOUCH_HUD_MODE_CHANGE }, | 79 TOUCH_HUD_MODE_CHANGE }, |
82 { true, ui::VKEY_I, ui::EF_CONTROL_DOWN | ui::EF_ALT_DOWN | ui::EF_SHIFT_DOWN, | 80 { true, ui::VKEY_I, ui::EF_CONTROL_DOWN | ui::EF_ALT_DOWN | ui::EF_SHIFT_DOWN, |
83 TOUCH_HUD_CLEAR }, | 81 TOUCH_HUD_CLEAR }, |
84 | 82 |
85 { true, ui::VKEY_N, ui::EF_SHIFT_DOWN | ui::EF_CONTROL_DOWN, | 83 { true, ui::VKEY_N, ui::EF_SHIFT_DOWN | ui::EF_CONTROL_DOWN, |
86 NEW_INCOGNITO_WINDOW }, | 84 NEW_INCOGNITO_WINDOW }, |
87 { true, ui::VKEY_N, ui::EF_CONTROL_DOWN, NEW_WINDOW }, | 85 { true, ui::VKEY_N, ui::EF_CONTROL_DOWN, NEW_WINDOW }, |
88 { true, ui::VKEY_T, ui::EF_CONTROL_DOWN, NEW_TAB }, | 86 { true, ui::VKEY_T, ui::EF_CONTROL_DOWN, NEW_TAB }, |
89 { true, ui::VKEY_OEM_MINUS, | 87 { true, ui::VKEY_OEM_MINUS, |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
152 // Media Player shortcuts. | 150 // Media Player shortcuts. |
153 { true, ui::VKEY_MEDIA_NEXT_TRACK, ui::EF_NONE, MEDIA_NEXT_TRACK}, | 151 { true, ui::VKEY_MEDIA_NEXT_TRACK, ui::EF_NONE, MEDIA_NEXT_TRACK}, |
154 { true, ui::VKEY_MEDIA_PLAY_PAUSE, ui::EF_NONE, MEDIA_PLAY_PAUSE}, | 152 { true, ui::VKEY_MEDIA_PLAY_PAUSE, ui::EF_NONE, MEDIA_PLAY_PAUSE}, |
155 { true, ui::VKEY_MEDIA_PREV_TRACK, ui::EF_NONE, MEDIA_PREV_TRACK}, | 153 { true, ui::VKEY_MEDIA_PREV_TRACK, ui::EF_NONE, MEDIA_PREV_TRACK}, |
156 | 154 |
157 // Debugging shortcuts that need to be available to end-users in | 155 // Debugging shortcuts that need to be available to end-users in |
158 // release builds. | 156 // release builds. |
159 { true, ui::VKEY_U, ui::EF_CONTROL_DOWN | ui::EF_ALT_DOWN | ui::EF_SHIFT_DOWN, | 157 { true, ui::VKEY_U, ui::EF_CONTROL_DOWN | ui::EF_ALT_DOWN | ui::EF_SHIFT_DOWN, |
160 PRINT_UI_HIERARCHIES }, | 158 PRINT_UI_HIERARCHIES }, |
161 | 159 |
| 160 // Accessibility: Spoken feedback shortcuts. The first one is to toggle |
| 161 // spoken feedback on or off. The others are only valid when |
| 162 // spoken feedback is enabled. |
| 163 { true, ui::VKEY_Z, ui::EF_CONTROL_DOWN | ui::EF_ALT_DOWN, |
| 164 TOGGLE_SPOKEN_FEEDBACK }, |
| 165 { true, ui::VKEY_CONTROL, ui::EF_CONTROL_DOWN, SILENCE_SPOKEN_FEEDBACK}, |
| 166 { false, ui::VKEY_HOME, ui::EF_SHIFT_DOWN, ACCESSIBLE_FOCUS_PREVIOUS}, |
| 167 { false, ui::VKEY_PRIOR, ui::EF_SHIFT_DOWN, ACCESSIBLE_FOCUS_PREVIOUS}, |
| 168 { false, ui::VKEY_END, ui::EF_SHIFT_DOWN, ACCESSIBLE_FOCUS_NEXT}, |
| 169 { false, ui::VKEY_NEXT, ui::EF_SHIFT_DOWN, ACCESSIBLE_FOCUS_NEXT}, |
| 170 |
162 // TODO(yusukes): Handle VKEY_MEDIA_STOP, and | 171 // TODO(yusukes): Handle VKEY_MEDIA_STOP, and |
163 // VKEY_MEDIA_LAUNCH_MAIL. | 172 // VKEY_MEDIA_LAUNCH_MAIL. |
164 }; | 173 }; |
165 | 174 |
166 const size_t kAcceleratorDataLength = arraysize(kAcceleratorData); | 175 const size_t kAcceleratorDataLength = arraysize(kAcceleratorData); |
167 | 176 |
168 #if !defined(NDEBUG) | 177 #if !defined(NDEBUG) |
169 const AcceleratorData kDesktopAcceleratorData[] = { | 178 const AcceleratorData kDesktopAcceleratorData[] = { |
170 #if defined(OS_CHROMEOS) | 179 #if defined(OS_CHROMEOS) |
171 // Extra shortcut for debug build to control magnifier on linux desktop. | 180 // Extra shortcut for debug build to control magnifier on linux desktop. |
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
371 #if defined(OS_CHROMEOS) | 380 #if defined(OS_CHROMEOS) |
372 CYCLE_DISPLAY_MODE, | 381 CYCLE_DISPLAY_MODE, |
373 DISABLE_GPU_WATCHDOG, | 382 DISABLE_GPU_WATCHDOG, |
374 #endif // defined(OS_CHROMEOS) | 383 #endif // defined(OS_CHROMEOS) |
375 }; | 384 }; |
376 | 385 |
377 const size_t kActionsAllowedInAppModeLength = | 386 const size_t kActionsAllowedInAppModeLength = |
378 arraysize(kActionsAllowedInAppMode); | 387 arraysize(kActionsAllowedInAppMode); |
379 | 388 |
380 } // namespace ash | 389 } // namespace ash |
OLD | NEW |