[Webkit-unassigned] [Bug 18341] New: Safari/Win: window.onunload not fired when the last browser window is being closed

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Apr 7 06:35:13 PDT 2008


http://bugs.webkit.org/show_bug.cgi?id=18341

           Summary: Safari/Win: window.onunload not fired when the last
                    browser window is being closed
           Product: WebKit
           Version: 525.x (Safari 3.1)
          Platform: PC
        OS/Version: Windows Vista
            Status: UNCONFIRMED
          Severity: Critical
          Priority: P2
         Component: HTML DOM
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: petr.zdrahal at sap.com


We expected that the handler attached to "window.onunload" gets invoked anytime
when a document gets unloaded - means for any of following cases you should get
same and consistent behavior.

(A) Close last browser window
(B) Close window, but still have another opened
(C) Refresh window
(D) Reload window/ put another URL in address bar

Wrong behavior with Safari 3.1. (525.31.3) [WinXP/SP2]
------------------------------------------------------
Safari-for-Windows doesn't cover the case (A). When the LAST browser window is
being closed, the handler attached to "window.onuload" is not called. Using
attached sample, you will not get any alert or window opened for the case (A)
at all. The cases (B,C,D) are handled properly. 

Expected behavior
-----------------
MSIE, Firefox or even Safari for Mac 3.1 behaves correctly,
in all cases (A,B,C,C) new window and popup gets displayed.

Note:  Even the scenario may look strange for you - we use the 
window.onuload to perform reasonable actions (to notify backend servers 
about to close backend sessions when the user left the browser), so it 
is not about just annoying popups/windows, but have strong real and valid 
usecase. I put the severity to Critical as it is almost a blocker for our apps.

Can be related to:
* http://bugs.webkit.org/show_bug.cgi?id=12469


-- 
Configure bugmail: http://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list