We can create the window in the same method
- (void) applicationWillFinishLaunching: (NSNotification *)not;where we created the menu. This method contains initialization code to be run before the application is launched.
But, we can't order front (ie, make visible) windows before NSApp has become active (which happens when the application is `launched'), so that ordering front our window in applicationWillFinishLaunching: would not work, because this method is called before the application finished launching.
To get around this problem, we implement in our application delegate also another method, called:
- (void) applicationDidFinishLaunching: (NSNotification *)not;This method (if implemented by the application's delegate) is invoked by the NSApp just after it finished launching. We order front our window in this method.