diff options
author | finnur@chromium.org <finnur@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-08-03 08:32:52 +0000 |
---|---|---|
committer | finnur@chromium.org <finnur@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-08-03 08:32:52 +0000 |
commit | d179cdd59e946b26a3e26846d4dc8441ff8d743c (patch) | |
tree | 98349bbc79a4c794137b8113d1488df121c1d205 /chrome/browser/extensions/extension_keybinding_registry.cc | |
parent | 077aa3cc463815e45e5a4cef7377b3a9ab260e19 (diff) | |
download | chromium_src-d179cdd59e946b26a3e26846d4dc8441ff8d743c.zip chromium_src-d179cdd59e946b26a3e26846d4dc8441ff8d743c.tar.gz chromium_src-d179cdd59e946b26a3e26846d4dc8441ff8d743c.tar.bz2 |
Implement Keybinding (Extension Commands) for script badges. With this change you can assign a shortcut to activate a visible script badge. Currently, the script badge will just show a synthesized popup, but once they become more fleshed out we can have a developer specified popup (or maybe an event, but that's not decided yet).
BUG=139809, 140016
TEST=Specify a Commands section in the manifest of a script badge extension and watch it get activated on pressing the shortcut.
Review URL: https://chromiumcodereview.appspot.com/10834106
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@149817 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/extensions/extension_keybinding_registry.cc')
-rw-r--r-- | chrome/browser/extensions/extension_keybinding_registry.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/chrome/browser/extensions/extension_keybinding_registry.cc b/chrome/browser/extensions/extension_keybinding_registry.cc index 0ac0257..1d6001e 100644 --- a/chrome/browser/extensions/extension_keybinding_registry.cc +++ b/chrome/browser/extensions/extension_keybinding_registry.cc @@ -41,8 +41,9 @@ void ExtensionKeybindingRegistry::Init() { bool ExtensionKeybindingRegistry::ShouldIgnoreCommand( const std::string& command) const { - return command == extension_manifest_values::kPageActionKeybindingEvent || - command == extension_manifest_values::kBrowserActionKeybindingEvent; + return command == extension_manifest_values::kPageActionCommandEvent || + command == extension_manifest_values::kBrowserActionCommandEvent || + command == extension_manifest_values::kScriptBadgeCommandEvent; } void ExtensionKeybindingRegistry::Observe( |