[whatwg] prompts, alerts and showModalDialog during beforeunload/unload events

timeless timeless at gmail.com
Wed Mar 10 01:02:03 PST 2010

On Mon, Feb 15, 2010 at 3:37 PM, Mike Hearn <mike at plan99.net> wrote:
> Browsers could solve the editor use case by treating "close tab" as
> "hide tab" for a minute or two before actually shutting down the page.

Firefox today has undo close tab. And people have joked for years
about undo quit application (I think we might have it too).

The problem with "hiding" is that if a web page is running scripts, or
retaining network connections, the web server might be expecting
certain behaviors.

If I'm playing a network "game", or using a network "irc" client, then
when i close my window, my link to the game/server/channel closes,
which means my server timers stop and people don't expect to be able
to contact me. If for 2 minutes my irc client is still "open", then
people will expect that i can receive messages, or the game will let
me die because I'm not interacting with it.

More information about the whatwg mailing list