Closed Bug 1734357 Opened 3 years ago Closed 3 years ago

(Win+Linux) Alt+F4 expected functionality in regards to browser.tabs.warnOnClose

Categories

(Firefox :: General, task)

Firefox 94
task

Tracking

()

RESOLVED FIXED

People

(Reporter: aflorinescu, Unassigned)

References

Details

Following up with https://bugzilla.mozilla.org/show_bug.cgi?id=1732446#c3, I've realized what was actually rubbing me wrong in regards to Alt+F4.
Alt+F4 to my understanding is generally defined as close imediately and I would read that as bypass any confirmations.

Although Alt+F4 is defined for Linux here to generate warning on default Fx94 configs (browser.tabs.warnOnClose on false) it doesn't. The behavior for Windows is not specified in the said document, but currently Fx94, no warning will be fired for Alt+F4.
I believe both for Windows and Linux, the current behavior with default settings(browser.tabs.warnOnClose on false) is the correct one : do not warn.

Switching the (browser.tabs.warnOnClose on true), Alt+F4 will generate close warning, which I personally wouldn't expect it to do, since it should close imediately, regardless of the state of the browser.tabs.warnOnClose value, but given that we would probably like to keep the same before functionality for the users that wanted the warn ...

Please note that the behavior of Alt+F4 before bug 1732445 would've warned with browser.tabs.warnOnClose on true.

To summarize the above into something a bit more actionable:

Fx94+

  • browser.tabs.warnOnClose - false(default)
    • Linux - Alt+F4 - no warn
    • Windows - Alt+F4 - no warn

Fx94+

  • browser.tabs.warnOnClose - true
    • Linux - Alt+F4 - warn
    • Windows - Alt+F4 - warn

Acounting for comment 0, could you confirm that the above is the correct behavior?

Flags: needinfo?(rtestard)
Flags: needinfo?(mhowell)
Flags: needinfo?(gijskruitbosch+bugs)

The linked document from comment #0 looks like it's a copy of an earlier document, and we changed the desired behaviour a bunch of times in the end. This document seems to only have been edited by QA, and I'm not sure to what degree it reflects the final outcomes.

The desired behaviour is to have 2 possible reasons to show a warning:

  1. the user used an easy-to-mis-hit quit shortcut (ctrl-q, cmd-q - right next to ctrl-tab/cmd-tab to switch tabs or applications, as well as ctr/cmd-w to close a single tab)
  2. the user is closing a window/app with more than 1 tab open

1 only affects Linux and macOS by default, because on Windows ctrl-shift-q is not as easy to mis-hit, so that warning is only enabled on Linux/macOS, and only affects using ctrl-q/cmd-q -- not alt-f4
2 is disabled by default, but can be turned on (this is browser.tabs.warnOnClose) and will cause a warning to show up whenever you close more than 1 tab at once, no matter what means you're using to close those tabs (shortcut, close button, close button from the OS app switcher, menu entry, etc. etc.).

(In reply to Adrian Florinescu [:aflorinescu] from comment #0)

Alt+F4 to my understanding is generally defined as close imediately and I would read that as bypass any confirmations.

We don't understand Alt-F4 this way - though as noted it isn't affected by the shortcut protection dialog the way ctrl/cmd-q is.

Although Alt+F4 is defined for Linux here to generate warning on default Fx94 configs (browser.tabs.warnOnClose on false) it doesn't.

The document is not correct, that field should be "NO" for alt-f4 on both windows and linux in the default config.

Switching the (browser.tabs.warnOnClose on true), Alt+F4 will generate close warning, which I personally wouldn't expect it to do, since it should close imediately, regardless of the state of the browser.tabs.warnOnClose value, but given that we would probably like to keep the same before functionality for the users that wanted the warn ...

Right, the current behaviour when users have explicitly enabled browser.tabs.warnOnClose (warning when using alt-f4 to close) is expected. If people don't want that, don't enable the warning. :-)

Does that answer your question?

Flags: needinfo?(rtestard)
Flags: needinfo?(mhowell)
Flags: needinfo?(gijskruitbosch+bugs)
Flags: needinfo?(adrian.florinescu)

Yes, thank you!

Status: NEW → RESOLVED
Closed: 3 years ago
Flags: needinfo?(adrian.florinescu)
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.