Recently, when I tried to add a "beforeunload" event listener to my webpage to display a confirmation button when exiting, I found that although I could click the cancel button to prevent leaving the ...
Is there a way to catch (in JavaScript) clicking on the window Close button? Ideally, I would expect this to emit beforeunload and unload events, but it doesn't seem to. This is on Gtk (Fedora Linux) ...