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

Unified Diff: chrome/browser/ui/views/omnibox/omnibox_view_views.cc

Issue 10825254: Remove views::KeyEvent, replacing uses of it with ui::KeyEvent. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 4 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
Index: chrome/browser/ui/views/omnibox/omnibox_view_views.cc
===================================================================
--- chrome/browser/ui/views/omnibox/omnibox_view_views.cc (revision 150588)
+++ chrome/browser/ui/views/omnibox/omnibox_view_views.cc (working copy)
@@ -35,6 +35,7 @@
#include "ui/base/clipboard/scoped_clipboard_writer.h"
#include "ui/base/dragdrop/drag_drop_types.h"
#include "ui/base/dragdrop/os_exchange_data.h"
+#include "ui/base/event.h"
#include "ui/base/ime/text_input_client.h"
#include "ui/base/ime/text_input_type.h"
#include "ui/base/l10n/l10n_util.h"
@@ -88,12 +89,12 @@
omnibox_view_->HandleFocusOut();
}
- virtual bool OnKeyPressed(const views::KeyEvent& event) OVERRIDE {
+ virtual bool OnKeyPressed(const ui::KeyEvent& event) OVERRIDE {
bool handled = views::Textfield::OnKeyPressed(event);
return omnibox_view_->HandleAfterKeyEvent(event, handled) || handled;
}
- virtual bool OnKeyReleased(const views::KeyEvent& event) OVERRIDE {
+ virtual bool OnKeyReleased(const ui::KeyEvent& event) OVERRIDE {
return omnibox_view_->HandleKeyReleaseEvent(event);
}
@@ -305,7 +306,7 @@
return textfield_->font().GetStringWidth(GetText().substr(start));
}
-bool OmniboxViewViews::HandleAfterKeyEvent(const views::KeyEvent& event,
+bool OmniboxViewViews::HandleAfterKeyEvent(const ui::KeyEvent& event,
bool handled) {
if (event.key_code() == ui::VKEY_RETURN) {
bool alt_held = event.IsAltDown();
@@ -368,7 +369,7 @@
return handled;
}
-bool OmniboxViewViews::HandleKeyReleaseEvent(const views::KeyEvent& event) {
+bool OmniboxViewViews::HandleKeyReleaseEvent(const ui::KeyEvent& event) {
// Omnibox2 can switch its contents while pressing a control key. To switch
// the contents of omnibox2, we notify the OmniboxEditModel class when the
// control-key state is changed.
@@ -723,7 +724,7 @@
}
bool OmniboxViewViews::HandleKeyEvent(views::Textfield* textfield,
- const views::KeyEvent& event) {
+ const ui::KeyEvent& event) {
delete_at_end_pressed_ = false;
if (event.key_code() == ui::VKEY_BACK) {
« no previous file with comments | « chrome/browser/ui/views/omnibox/omnibox_view_views.h ('k') | chrome/browser/ui/views/omnibox/omnibox_view_win.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698