Returns a window controller initialized with a given window.
- macOS 10.0+
The window object to manage; can be
A newly initialized window controller.
This method is the designated initializer for
This initializer is useful when a window has been loaded but no window controller is assigned. The default initialization turns on cascading, sets the
should property to
false, and sets the window frame autosave name to an empty string. As a side effect, the created window controller is added as an observer of the
wills posted by that window object (which is handled by a private method). If you make the window controller a delegate of the window, you can implement NSWindow’s windowShouldClose: delegate method.