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

Unified Diff: chrome/browser/views/extensions/extension_view.cc

Issue 415001: Merge 32335... (Closed) Base URL: svn://svn.chromium.org/chrome/branches/249/src/
Patch Set: Created 11 years, 1 month 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 | « chrome/browser/views/extensions/extension_view.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/views/extensions/extension_view.cc
===================================================================
--- chrome/browser/views/extensions/extension_view.cc (revision 32528)
+++ chrome/browser/views/extensions/extension_view.cc (working copy)
@@ -22,6 +22,11 @@
container_(NULL),
is_clipped_(false) {
host_->set_view(this);
+
+ // This view needs to be focusable so it can act as the focused view for the
+ // focus manager. This is required to have SkipDefaultKeyEventProcessing
+ // called so the tab key events are forwarded to the renderer.
+ SetFocusable(true);
}
ExtensionView::~ExtensionView() {
@@ -170,6 +175,12 @@
}
}
+bool ExtensionView::SkipDefaultKeyEventProcessing(const views::KeyEvent& e) {
+ // Let the tab key event be processed by the renderer (instead of moving the
+ // focus to the next focusable view).
+ return (e.GetKeyCode() == base::VKEY_TAB);
+}
+
void ExtensionView::HandleMouseEvent() {
if (container_)
container_->OnExtensionMouseEvent(this);
« no previous file with comments | « chrome/browser/views/extensions/extension_view.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698