Disable the stupid feature with browser closing by ctrl+q
Hi! Does anybody know how to disable browser closing by ctrl+q shortcut? It is too close to ctrl+w and sometimes I close the whole browser instead of one tab. Moreover it is really useless and stupid feature since I have alt+f4. Why I need another shortcut which do the same stuff? And why developers ignore this issue which was reported on several forums? I tried install extension which disable it but it doesn't work for me.
Okulungisiwe ngu James
All Replies (3)
Web Extensions can't disable this command AFAIK.
I use this bookmaklet to copy the code to the clipboard and paste it in the Browser Console when the command line history in the Browser Console doesn't bring it up as the first choice(s). If necessary you can clear the history via this command: clearHistory()
Hi jenamax, I'm aware of two ways to prevent immediate browser closure with the Exit/Quit shortcut. Note that I use Windows, in case your defaults are different on Linux.
(1) "Warn on close"
If quitting would close more than one tab, then Firefox can display a dialog for confirmation:<center></center>
If you don't see that, you might double-check this setting:
(a) In a new tab, type or paste about:config in the address bar and press Enter/Return. Click the button accepting the risk.
(b) In the search box in the page, type or paste CLOSE and pause while the list is filtered
(c) If the browser.tabs.warnOnClose preference is bolded and has a value of false, double-click it to restore the default value of true
(2) At least one tab has a beforeunload event handler set
You may occasionally have been saved by, or perhaps more often annoyed by, this warning:<center></center>
When you exit, any tab with such an event handler should be focused and require you to respond to the question. (Assuming you have not set dom.disable_beforeunload to true in about:config.)
I created an extension to leverage that behavior which you can use to create such a tab. It's probably more useful for private windows, which Firefox may close without warning, but you need to make sure to enable the extension to run in private windows for that to work. If you want to take a look: https://addons.mozilla.org/firefox/addon/prevent-closing-window/
Only works on Windows and MacOS. Doesn't work on Linux until this bug is addressed. https://bugzilla.mozilla.org/show_bug.cgi?id=1325692
Okulungisiwe ngu cor-el