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

Unified Diff: ash/system/tray/tray_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
« no previous file with comments | « ash/system/tray/tray_views.h ('k') | chrome/browser/chromeos/login/password_changed_view.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/system/tray/tray_views.cc
===================================================================
--- ash/system/tray/tray_views.cc (revision 150588)
+++ ash/system/tray/tray_views.cc (working copy)
@@ -9,6 +9,7 @@
#include "grit/ash_strings.h"
#include "grit/ui_resources.h"
#include "ui/base/accessibility/accessible_view_state.h"
+#include "ui/base/event.h"
#include "ui/base/resource/resource_bundle.h"
#include "ui/gfx/canvas.h"
#include "ui/gfx/image/image.h"
@@ -115,10 +116,13 @@
canvas->DrawRect(rect, kFocusBorderColor);
}
-bool ActionableView::OnKeyPressed(const views::KeyEvent& event) {
+bool ActionableView::OnKeyPressed(const ui::KeyEvent& event) {
if (event.key_code() == ui::VKEY_SPACE ||
event.key_code() == ui::VKEY_RETURN) {
- return PerformAction(event);
+ // TODO(beng): remove once views::Event is gone.
+ views::MouseEvent synthetic_event(
+ ui::ET_MOUSE_RELEASED, 0, 0, ui::EF_LEFT_MOUSE_BUTTON);
+ return PerformAction(synthetic_event);
}
return false;
}
« no previous file with comments | « ash/system/tray/tray_views.h ('k') | chrome/browser/chromeos/login/password_changed_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698