Window.onClose

Boolean onClose ()

Description

An event-handler callback function, called when the window is about to be closed.

Called when a request is made to close the window, either by an explicit call to the?close()?function or by a user action (clicking the OS-specific close icon in the title bar). The function is called before the window actually closes; it can return false to cancel the close operation.