Determines whether the system should close the document and its associated window.
- macOS 10.0+
The window controller that is closed.
The delegate to which the selector message is sent.
The selector of the message sent to the delegate.
Object passed with the callback to provide any additional context information.
If the window controller is the document's last one, or is marked as causing the document to close, this method calls the method in the
should parameter with the result of
can. In all other cases, this method calls
true. This method is called automatically by
NSWindow for any window that has a window controller and a document associated with it.
NSWindow calls this method prior to sending its
window message. Pass the
context object with the callback.
should callback method should have the following signature: