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

Unified Diff: chrome/browser/ui/views/extensions/extension_keybinding_registry_views.cc

Issue 9812008: Polish the keybinding implementation a bit. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 9 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/extensions/extension_keybinding_registry_views.cc
===================================================================
--- chrome/browser/ui/views/extensions/extension_keybinding_registry_views.cc (revision 127690)
+++ chrome/browser/ui/views/extensions/extension_keybinding_registry_views.cc (working copy)
@@ -28,12 +28,10 @@
const Extension* extension) {
// Add all the keybindings (except pageAction and browserAction, which are
// handled elsewhere).
- const std::vector<Extension::ExtensionKeybinding> commands =
- extension->keybindings();
+ std::vector<Extension::ExtensionKeybinding> commands;
+ extension->GetCommandByType(Extension::ExtensionKeybinding::COMMANDS,
+ &commands);
for (size_t i = 0; i < commands.size(); ++i) {
- if (ShouldIgnoreCommand(commands[i].command_name()))
- continue;
-
event_targets_[commands[i].accelerator()] =
std::make_pair(extension->id(), commands[i].command_name());
focus_manager_->RegisterAccelerator(

Powered by Google App Engine
This is Rietveld 408576698