Is it possible to override the Ctrl+D? I want to, for example console.log
or something, and not add the links to the bookmarks.
Google-chrome – Override the bookmark shortcut (Ctrl+D) function in Chrome
bookmarksgoogle-chromegoogle-chrome-extensionkeyboard shortcuts
Related Topic
- Java – Eclipse’s Ctrl+O (Show Outline) shortcut equivalent in IntelliJ IDEA
- Xcode – [Go to file…]
- Css – See :hover state in Chrome Developer Tools
- Ajax – How to manually send HTTP POST requests from Firefox or Chrome browser
- Intellij-idea – Keyboard shortcut for Jump to Previous View Location (Navigate back/forward) in IntelliJ IDEA
- Android-studio – the shortcut to Auto import all in Android Studio
- R – flex3:How to override function set label of a button
Best Answer
Shortcuts can be overridden using the
chrome.commands
API. An extension can suggest a default shortcut (eg. Ctrl+D) in the manifest file, but users are free to override this atchrome://extensions/
, as seen below:Usage
This API is still under development and only available at the Beta and Dev channels, and the Canary builds More info. It will probably available to everyone starting at Chrome 24.
If you want to test the API in Chrome 23 or lower, add the "experimental" permission to the manifest file, and use
chrome.experimental.commands
instead ofchrome.commands
. Also visitchrome://flags/
and enable "Experimental Extension APIs", or start Chrome with the--enable-experimental-extension-apis
flag.manifest.json
background.js
Documentation
chrome.commands
chrome.tabs
(methodsquery
andexecuteScript
)