summaryrefslogtreecommitdiffstats
path: root/views/controls
diff options
context:
space:
mode:
authoroshima@chromium.org <oshima@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-09 18:18:03 +0000
committeroshima@chromium.org <oshima@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-09 18:18:03 +0000
commit8ecb6aa0a92d5426c2c98c23e0e3f3c4f06972c5 (patch)
treee83e304b786fbccba8b218a05b9ed4410c40731b /views/controls
parent79e3744bbbb0867f4e356eab96703d425b3fad40 (diff)
downloadchromium_src-8ecb6aa0a92d5426c2c98c23e0e3f3c4f06972c5.zip
chromium_src-8ecb6aa0a92d5426c2c98c23e0e3f3c4f06972c5.tar.gz
chromium_src-8ecb6aa0a92d5426c2c98c23e0e3f3c4f06972c5.tar.bz2
Convert gdk keycode to match base::KeyboardCode.
Review URL: http://codereview.chromium.org/268026 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28568 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'views/controls')
-rw-r--r--views/controls/textfield/textfield.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/views/controls/textfield/textfield.cc b/views/controls/textfield/textfield.cc
index e22da4d..e906337 100644
--- a/views/controls/textfield/textfield.cc
+++ b/views/controls/textfield/textfield.cc
@@ -14,6 +14,9 @@
#include "base/win_util.h"
#endif
+#if defined(OS_LINUX)
+#include "base/keyboard_code_conversion_gtk.h"
+#endif
#include "base/keyboard_codes.h"
#include "base/string_util.h"
#include "views/controls/textfield/native_textfield_wrapper.h"
@@ -291,7 +294,8 @@ base::KeyboardCode Textfield::Keystroke::GetKeyboardCode() const {
#if defined(OS_WIN)
return static_cast<base::KeyboardCode>(key_);
#else
- return static_cast<base::KeyboardCode>(event_.keyval);
+ return static_cast<base::KeyboardCode>(
+ base::WindowsKeyCodeForGdkKeyCode(event_.keyval));
#endif
}