eight04 / popup-tab

A Firefox addon, easily convert a tab into a popup and vice versa.
MIT License
16 stars 4 forks source link

Keyboard shortcut in old Firefox #6

Closed grahamperrin closed 1 year ago

grahamperrin commented 5 years ago

I'd like a tab to pop up in response to a keyboard shortcut.

Comparable (new enhancement request): Keyboard shortcut · Issue #15 · ettoolong/PopupWindow

eight04 commented 5 years ago

I think we can add a shortcut to popup/insert back the current tab/popup window.

The shortcut will be configurable after Firefox 66: https://bugzilla.mozilla.org/show_bug.cgi?id=1303384

grahamperrin commented 5 years ago

Thanks:

image

I sped through https://github.com/eight04/popup-tab/pull/7/files but (sorry) I can't tell which shortcut you have chosen.

eight04 commented 5 years ago

You have to use Firefox 66+ to set the shortcut.

grahamperrin commented 5 years ago

Ah, thanks for clarification.

I imagined a developer-set preset, effective in 65.0, user-configurable in 66+

Waterfox 56.2.7.1 here, but I don't expect support for this browser.

eight04 commented 5 years ago

I'm not familiar with Waterfox. If commands.update is supported, then it is possible to create a configurable shortcut. Otherwise, we can only define a default.

a developer-set preset

Any suggestion?

grahamperrin commented 5 years ago

Thanks. Waterfox 56.0 was based on Firefox 56.0.2.

I thought first of Control-Shift-U but https://redd.it/abrv4b reminds me, it's already a standard shortcut for Unicode character composition.


Control-Alt-U maybe?

I have quite a few extensions, at a glance it's uncommon to use Control-Alt:

image

– which might mean, it's a good choice.

On the other hand, maybe there's a good reason (unknown to me on FreeBSD) for avoiding Control-Alt combinations.

I reckon, go for it. Control-Alt-U

FWIW:

grahamperrin commented 5 years ago

https://developer.mozilla.org/docs/Mozilla/Add-ons/WebExtensions/API/commands/update#Browser_compatibility shows 60 for Firefox so let's assume that commands.update will not be supported by any 56.x version of Waterfox.

eight04 commented 5 years ago

Waterfox 56.2.7.1 image

eight04 commented 5 years ago

Waterfox doesn't allow us to use Alt as the second modifier:

secondary modifier (optional). If supplied, this must be either "Shift" or (for Firefox ≥ 63) any one of "Ctrl", "Alt", "Command" and "MacCtrl", which has not been used as the main modifier.

https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/manifest.json/commands#Key_combinations

grahamperrin commented 5 years ago

image

Does that look right?

On FreeBSD-CURRENT here. And I'm almost completely lost in consoles in browsers :-)

grahamperrin commented 5 years ago

OK so your GitHub ID is eight04, like 804, so maybe this:

Control-Shift-8

image

eight04 commented 5 years ago

Can you use keyconfig to change a hotkey defined by a webextension?

I guess I will choose Ctrl+J (Join popup/Jump out window).

grahamperrin commented 5 years ago

Can you use keyconfig to change a hotkey defined by a webextension?

In my experience, not reliably (not understandably).

Ctrl+J

Re: https://support.mozilla.org/kb/keyboard-shortcuts-perform-firefox-tasks-quickly#w_tools that's for downloads, and (for me) is already in conflict with something else:

image

eight04 commented 5 years ago

image It seems that we can change the hotkey using keyconfig. However, I don't know what will happen if there are multiple hotkeys defined by multiple extensions. The name looks pretty weird.

grahamperrin commented 5 years ago

Not Control-Shift-U, please, for the reason given at https://github.com/eight04/popup-tab/issues/6#issuecomment-462374183

eight04 commented 5 years ago

Maybe we should not set a default key at all since an unchangeable hotkey is a bad idea. We can revisit this issue after FF66 enters the release channel.

For Waterfox users, here is a custom build that set Ctrl+Shift+8 as the default. You can use the keyconfig addon to change it to anything you like.

After FF66 hits the release channel, I will probably use Ctrl+Shift+O as the default and push the change to AMO, then you can drop the custom build. popup_tab-0.2.0.zip

grahamperrin commented 5 years ago

Thanks for the build, I'll test.

Not Control-Shift-O, please; it's in conflict with a browser default in the screenshot at https://github.com/eight04/popup-tab/issues/6#issuecomment-462701355 above.

Here we have a problem with Mozilla's documentation https://support.mozilla.org/kb/keyboard-shortcuts-perform-firefox-tasks-quickly – the same default exists (but is not documented) in Firefox 65.0 in safe mode.

eight04 commented 5 years ago

That command had been moved to Ctrl+Shift+B.

grahamperrin commented 5 years ago

Mozilla bug 1527337 - FreeBSD users are being shown Windows content instead of Linux

grahamperrin commented 5 years ago

Ctrl+Shift+B

– has been documented for a long time, but truly it's non-effective in Firefox 65.0 on Linux and Firefox 65.0 on FreeBSD-CURRENT.

Please: is this shortcut effective in your Firefox? If so: which version, on which OS? Clarified: bug 1527337 is a Tier-3 Knowledge Base content issue.

For the purposes of this #6 we should avoid both (a) the documented shortcuts that are presented to users of Windows; and (b) the documented shortcuts that are presented to users of Linux. Use the Editing Tools menu at https://support.mozilla.org/kb/keyboard-shortcuts-perform-firefox-tasks-quickly to disclose customisation for the document (without editing).

grahamperrin commented 5 years ago

… For Waterfox users, here is a custom build that set Ctrl+Shift+8 as the default. …

Confirmed good with:

Thanks! Five gold stars on their way to the reviews area …

eight04 commented 5 years ago

Yes, I'm using Windows 7. Both Waterfox and Firefox Dev 66.0b7 use Ctrl+Shift+B to open bookmark manager.

grahamperrin commented 5 years ago

Thanks again.

There was a subliminal reason for me suggesting Control-Shift-8 (number 8) … a comparable shortcut with F8 (function key 8) features strongly in KWin:

image

Effect:

image

– an overview of popped-up and other windows.

(More obscurely: I learnt to use function keys in that area of the keyboard back in 2003, when Apple introduced Exposé.)

grahamperrin commented 1 year ago

I stopped using Waterfox some time ago (only because there's no longer a third party port to FreeBSD.

Without looking in detail at what's above: is there any reason to keep this issue open?

If not, please close – thank you.