Migrate user-defined shortcuts from _execute_browser_action to _execute_action
Categories
(WebExtensions :: General, defect, P2)
Tracking
(firefox127 fixed)
Tracking | Status | |
---|---|---|
firefox127 | --- | fixed |
People
(Reporter: robwu, Assigned: willdurand)
References
(Blocks 1 open bug)
Details
(Keywords: dev-doc-complete, Whiteboard: [wecg][addons-jira])
Attachments
(1 file)
In MV3, the browser_action
API has been renamed to the action
API (bug 1706398). In Chrome, the action
API supersedes even the page_action
API (under consideration in bug 1687756).
As part of the rename, the "_execute_browser_action" keyword has been renamed to "_execute_action". Firefox supports this in the commands
API *. Users can customize the shortcut registration via UI in about:addons
, which is persisted, keyed by the shortcut ID. If extension authors are forced to migrate to _execute_action
, then the key changes, and users would lose their customized shortcut.
To avoid the loss of user customizations, we should consider migrating the _execute_browser_action
shortcut to _execute_action
(or somehow use it as a fallback), at https://searchfox.org/mozilla-central/rev/2d1097c27f31cb15f7588b043d691cda9710d14b/toolkit/components/extensions/ExtensionShortcuts.jsm#292-301.
To avoid the fallback from unexpectedly popping up, we should clear both _execute_browser_action
and _execute_action
when the shortcut is reset (resetCommand implementation).
* command
is also supported in the menus
/ contextMenus
API. I'm not concerned about the menu registrations, because these do not persist beyond extension updates nor browser updates.
Reporter | ||
Updated•2 years ago
|
Updated•2 years ago
|
Assignee | ||
Comment 1•7 months ago
|
||
Updated•7 months ago
|
Reporter | ||
Comment 4•5 months ago
|
||
Should be added to the changelog of Firefox 127 for developers.
Content changes are ready for review
Description
•