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

Unified Diff: ui/chromeos/events/event_rewriter_chromeos.cc

Issue 2763483002: Fix Caps Lock bug (Closed)
Patch Set: Failure due to file directory change, apply the fix Created 3 years, 8 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 | « ui/base/ime/input_method_chromeos.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/chromeos/events/event_rewriter_chromeos.cc
diff --git a/ui/chromeos/events/event_rewriter_chromeos.cc b/ui/chromeos/events/event_rewriter_chromeos.cc
index 65c908087e5530874e019ec5c3e80a280164b3b4..5366c6001ea2fc68e3f2d187b5b9d4e83babdce4 100644
--- a/ui/chromeos/events/event_rewriter_chromeos.cc
+++ b/ui/chromeos/events/event_rewriter_chromeos.cc
@@ -804,24 +804,9 @@ bool EventRewriterChromeOS::RewriteModifierKeys(const ui::KeyEvent& key_event,
used_modifier_latches_ |= pressed_modifier_latches_;
latched_modifier_latches_ = ui::EF_NONE;
}
- // Toggle Caps Lock if the remapped key is ui::VKEY_CAPITAL.
- if (state->key_code == ui::VKEY_CAPITAL
- // ... except on linux Chrome OS, where InputMethodChromeOS handles it.
- && (base::SysInfo::IsRunningOnChromeOS() || ime_keyboard_for_testing_)
-#if defined(USE_X11)
- // ... but for X11, do nothing if the original key is ui::VKEY_CAPITAL
- // (i.e. a Caps Lock key on an external keyboard is pressed) since X
- // handles that itself.
- && incoming.key_code != ui::VKEY_CAPITAL
-#endif
- ) {
- ::chromeos::input_method::ImeKeyboard* ime_keyboard =
- ime_keyboard_for_testing_
- ? ime_keyboard_for_testing_
- : ::chromeos::input_method::InputMethodManager::Get()
- ->GetImeKeyboard();
- ime_keyboard->SetCapsLockEnabled(!ime_keyboard->CapsLockIsEnabled());
- }
+ // The handling of Caps Lock toggling is now moved to accelerator
+ // controller.
+ // (see https://bugs.chromium.org/p/chromium/issues/detail?id=700705).
}
return exact_event;
}
« no previous file with comments | « ui/base/ime/input_method_chromeos.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698