summaryrefslogtreecommitdiffstats
path: root/ui/aura/event.cc
diff options
context:
space:
mode:
authoryusukes@chromium.org <yusukes@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-01-05 04:09:23 +0000
committeryusukes@chromium.org <yusukes@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-01-05 04:09:23 +0000
commit273bf9e24c8268d80d89b35b3f8de678be5723e6 (patch)
tree68b95599229c80f980a7702706c07231b73bb0b6 /ui/aura/event.cc
parent6ff45e6c846d665cb8b5dfcdebbef55a91e9cd6e (diff)
downloadchromium_src-273bf9e24c8268d80d89b35b3f8de678be5723e6.zip
chromium_src-273bf9e24c8268d80d89b35b3f8de678be5723e6.tar.gz
chromium_src-273bf9e24c8268d80d89b35b3f8de678be5723e6.tar.bz2
Do not use ui::GetCharacterFromXEvent when Control is pressed.
The function does not take into account the modifier. BUG=107837 TEST=see the bug Review URL: http://codereview.chromium.org/8968011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@116451 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui/aura/event.cc')
-rw-r--r--ui/aura/event.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/ui/aura/event.cc b/ui/aura/event.cc
index bdd4764..18687d1 100644
--- a/ui/aura/event.cc
+++ b/ui/aura/event.cc
@@ -1,4 +1,4 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -229,7 +229,9 @@ uint16 KeyEvent::GetCharacter() const {
DCHECK(native_event()->type == KeyPress ||
native_event()->type == KeyRelease);
- uint16 ch = ui::GetCharacterFromXEvent(native_event());
+ uint16 ch = 0;
+ if (!IsControlDown())
+ ch = ui::GetCharacterFromXEvent(native_event());
return ch ? ch : ui::GetCharacterFromKeyCode(key_code_, flags());
#else
NOTIMPLEMENTED();