Add global keyboard shortcut support to commands API
Categories
(WebExtensions :: General, defect, P3)
Tracking
(Not tracked)
People
(Reporter: srpen6, Unassigned)
References
(Blocks 1 open bug)
Details
(Whiteboard: [commands])
User Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:56.0) Gecko/20100101 Firefox/56.0 Build ID: 20170926190823 Steps to reproduce: "global" property is currently only supported with Chrome and Opera: http://developer.mozilla.org/Add-ons/WebExtensions/manifest.json/commands#Browser_compatibility That means until Firefox implements `global` WebExtension keyboard shortcuts will only work if the browser has focus: http://developer.chrome.com/apps/commands#scope This is very bad. Currently "global" is supported with whatever WebExtensions are replacing, see this example Add-on: http://addons.mozilla.org/firefox/addon/media-keys So the soon approaching Firefox 57 is going to kill this feature if it is not implemented soon.
Updated•7 years ago
|
Updated•7 years ago
|
Updated•7 years ago
|
Reporter | ||
Comment 1•7 years ago
|
||
why was this marked "wontfix" Firefox 56 supports it through XUL or whatever, as well as Chrome and Opera If you want to push people to Chrome, you are sure doing a good job
Comment 2•7 years ago
|
||
(In reply to Steven Penny from comment #1) > why was this marked "wontfix" It's marked as wontfix for Firefox 57, since we're only accepting critical uplifts for that release at this point.
Comment hidden (off-topic) |
Comment hidden (off-topic) |
Reporter | ||
Comment 5•7 years ago
|
||
Until this issue is fixed by Mozilla, people can use Chromium [1] with the Streamkeys extension [2]. [1] http://github.com/henrypp/chromium [2] http://www.streamkeys.com
Comment 6•6 years ago
|
||
Apparently, media keys on macOS act as "global hot keys". The Chromium source cites this blog post as the source for their implementation: https://weblog.rogueamoeba.com/2007/09/29/ Please consider this for this issue.
Updated•6 years ago
|
Updated•6 years ago
|
Comment 7•6 years ago
|
||
Bulk move of bugs per https://bugzilla.mozilla.org/show_bug.cgi?id=1483958
Reporter | ||
Updated•5 years ago
|
Updated•5 years ago
|
Reporter | ||
Comment 8•5 years ago
|
||
Its been 2 years, I am tired of waiting. I will pay $100 to anyone who can fix
this, or can help me to fix it. I know a little Rust/C++/C.
Please, Chrome has had this for years. I already switched to Chrome on mobile,
I would really rather not for desktop as well.
Reporter | ||
Comment 9•5 years ago
|
||
$200 to anyone who can fix this.
Comment 10•5 years ago
|
||
I am willing to give this bug a try, especially since it intersects with another bug I planned on working.
Both bugs involve handling of Global Hotkeys using some platform specific native code.
My knowledge about that part is however limited, so are the following assumptions correct?:
According to https://dxr.mozilla.org/mozilla-central/source/toolkit/components/extensions/ExtensionShortcuts.jsm#377 this involves the creation of a <key>, so the whole WebExtensions are mainly creating an internal XUL which is then executed?
This is where I am stuck:
- I don't know where <key> is handled, is it here?
- According to the Documentation,
The key element defines a window-global keyboard shortcut and must be placed inside a keyset element.
, so that means we would need to change the specification of XUL so that key isn't necessarily window-global and/or that an attributeglobal="true"
is allowed? This makes the fix more complicated/official, if I understand that correct?
Thanks in Advance
Updated•5 years ago
|
Reporter | ||
Comment 11•5 years ago
|
||
Updated•4 years ago
|
Comment 12•4 years ago
|
||
Any update on this? I'm a heavy Firefox user on desktop and mobile (Android). That media keys extension is so helpful while doing work and listening to music. The alternative is to switch to Chrome for music playback (music.youtube.com)
Comment 13•4 years ago
|
||
The feature has now been released with Firefox 81 (dev edition). I didn't tested every cases possible but it works natively on Windows 10, tested on Youtube, Netflix, Prime Video. It works as global media keys and use the native Windows API (so as any nativemusic/video player, you can pause a media content from Firefox while playing a video game on your main screen just by pressing the play pause key).
But, the purpose of this issue was to add an API to allow webextensions to use it (I don't know if it has been done). I'm not sure it would even that be that useful now, as the main purpose of the API (at least for me) was to allow what now works natively.
Anyway good job everyone !
Comment 14•3 years ago
|
||
please fix this
Updated•2 years ago
|
Comment 15•2 years ago
|
||
The severity field for this bug is relatively low, S3. However, the bug has 24 votes and 53 CCs.
:robwu, could you consider increasing the bug severity?
For more information, please visit auto_nag documentation.
Comment 16•2 years ago
|
||
The last needinfo from me was triggered in error by recent activity on the bug. I'm clearing the needinfo since this is a very old bug and I don't know if it's still relevant.
Comment 17•3 months ago
|
||
This is a feature request rather than a defect, but it sure would still be nice to have this. It's sadly another case of "sorry, please use chrome to use this feature" for us.
Description
•