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

Unified Diff: ui/aura/root_window.cc

Issue 9835032: aura: Make RootWindow::DispatchKeyEvent drop unknown keys. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 9 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/aura/root_window.h ('k') | ui/aura/root_window_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/aura/root_window.cc
diff --git a/ui/aura/root_window.cc b/ui/aura/root_window.cc
index 1e8a6b5b0d1786a34edbc9293065295aa30f3ac1..0251169b09affb9b92796b5251c4467014227778 100644
--- a/ui/aura/root_window.cc
+++ b/ui/aura/root_window.cc
@@ -194,6 +194,8 @@ bool RootWindow::DispatchMouseEvent(MouseEvent* event) {
bool RootWindow::DispatchKeyEvent(KeyEvent* event) {
DispatchHeldMouseMove();
KeyEvent translated_event(*event);
+ if (translated_event.key_code() == ui::VKEY_UNKNOWN)
+ return false;
return ProcessKeyEvent(focused_window_, &translated_event);
}
« no previous file with comments | « ui/aura/root_window.h ('k') | ui/aura/root_window_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698