Search Support

Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

Learn More

warn on quit

  • 4 replies
  • 1 has this problem
  • آخر ردّ كتبه cor-el

more options

It's so frustrating that the keyboard shortcut for closing tabs is right beside the one to quit Firefox. I've lost countless hours because of this, and it's so easy to accidentally do. Is there a way to keep this from happening? A simple "Are you sure" confirmation dialog would be great, or I really like the Chrome "hold command-Q" to exit feature. This seemingly simple function is proving extremely difficult to accomplish.

Yes, I'm aware of session restore, but (1) It does not preserve my window arrangement. I use multiple desktops for various tasks, and they each have related browser windows. (2) I need to see webpages exactly as they were when I opened them. Sessions expire, dynamic pages are refreshed, content is removed etc. That is all lost.

I do not want to disable session restore completely. It can still be useful. But, I do not want to trigger session restore automatically every time. Manual activation is ideal.

regarding: "browser.tabs.warnOnClose" I do not want a warning for closing multiple tabs. I often have many windows open and that warning gets annoying. It also doesn't prevent me from accidentally quitting when I only have one tab open.

I tried setting browser.warnOnQuit to true, but it's ignored.

I simply want a confirmation when I use the keyboard shortcut to QUIT. That's it. No side effects. Can Firefox do this?

All Replies (4)

more options

I guess I'm alone. Back to Chrome it is.


more options

On Mac disabling key_quitApplication doesn't seem to be easy as this seems to be under control of the Mac OS.

# On OS X, dark voodoo magic invokes the quit code for this key.
# So we're not adding the attribute on OSX because of backwards/add-on compat.
# See bug 1369909 for background on this.

On Linux I run this code in the Browser Console to disable the Ctrl+Q shortcut for the current window, but this will likely have no effect on Mac

var wd = Services.wm.getMostRecentWindow("navigator:browser").window.document;
function $(e){return(wd.getElementById(e))}
function $(e){var N=$(e);if(N){N.removeAttribute("command"); N.removeAttribute("key"); N.removeAttribute("modifiers"); console.log(N)}return($(e))}


more options

Chrome managed it somehow.

Is there at least a way to assign a different shortcut key to close tab so it's not so close to the 'q'? This is an almost daily rage moment for me.


more options

Did you try the code in the Browser Console to see if it has any effect ?

To enable the command line in the Console:


اطرح سؤالا

عليك الولوج إلى حسابك للردّ على المشاركات. من فضلك اطرح سؤالًا جديدًا لو لم يكن لديك حساب بعد.