From d766882c913b272cc2db478d7640a317d838ebad Mon Sep 17 00:00:00 2001 From: "jcampan@chromium.org" Date: Mon, 28 Sep 2009 21:18:58 +0000 Subject: Changing the KeyboardEvent to use a KeyboardCode instead of a w_char. Led to several places where I had to switch from VK_ to VKEY_. Also cleaned-up the table view OnKeyDown method. Since TableView is a NativeControl it can use the NativeControl::OnKeyDown directly. BUG=None TEST=Make sure short-cuts works as expected, especially in the omnibox. Review URL: http://codereview.chromium.org/248010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@27412 0039d316-1c4b-4281-b951-d872f2087c98 --- views/controls/combobox/combobox.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'views/controls/combobox') diff --git a/views/controls/combobox/combobox.cc b/views/controls/combobox/combobox.cc index 5c5596f..e184dcb 100644 --- a/views/controls/combobox/combobox.cc +++ b/views/controls/combobox/combobox.cc @@ -69,10 +69,10 @@ void Combobox::SetEnabled(bool flag) { native_wrapper_->UpdateEnabled(); } -// VK_ESCAPE should be handled by this view when the drop down list is active. +// VKEY_ESCAPE should be handled by this view when the drop down list is active. // In other words, the list should be closed instead of the dialog. bool Combobox::SkipDefaultKeyEventProcessing(const KeyEvent& e) { - if (e.GetCharacter() != base::VKEY_ESCAPE || + if (e.GetKeyCode() != base::VKEY_ESCAPE || e.IsShiftDown() || e.IsControlDown() || e.IsAltDown()) { return false; } -- cgit v1.1