Index: chrome/browser/chromeos/system_key_event_listener.cc |
=================================================================== |
--- chrome/browser/chromeos/system_key_event_listener.cc (revision 123410) |
+++ chrome/browser/chromeos/system_key_event_listener.cc (working copy) |
@@ -10,6 +10,7 @@ |
#include <X11/XKBlib.h> |
#undef Status |
+#include "chrome/browser/chromeos/accessibility/accessibility_util.h" |
#include "chrome/browser/chromeos/audio/audio_handler.h" |
#include "chrome/browser/chromeos/dbus/dbus_thread_manager.h" |
#include "chrome/browser/chromeos/dbus/power_manager_client.h" |
@@ -347,9 +348,16 @@ |
if (XKeycodeToKeysym(ui::GetXDisplay(), keycode, 0) == XK_Super_L) { |
const bool shift_is_held = (state & ShiftMask); |
const bool other_mods_are_held = (state & ~(ShiftMask | LockMask)); |
- if (shift_is_held && !other_mods_are_held) |
+ |
+ // When spoken feedback is enabled, the Search key is used as an |
+ // accessibility modifier key. |
+ const bool accessibility_enabled = |
+ accessibility::IsSpokenFeedbackEnabled(); |
+ |
+ if (shift_is_held && !other_mods_are_held && !accessibility_enabled) { |
input_method_manager->GetXKeyboard()->SetCapsLockEnabled( |
!caps_lock_is_on_); |
+ } |
} |
// Only doing non-Alt/Shift/Ctrl modified keys |