Search code examples
macoscocoaappkitxcode-storyboard

How does Application scene gets connected to Window scene in OSX application?


I examine the storyboard of an OSX application and do not find anything that connects the application scene to the window scene. How does the app know which window controller to load at start?

enter image description here


Solution

  • The Storyboard Entry Point item in your screenshot tells the storyboard to load that window controller at the start.

    If you have multiple window controllers, use the attributes inspector to specify the window controller to load when the application starts. Select the window controller you want to load initially, open the attributes inspector, and select the Is Initial Controller checkbox. Selecting the checkbox adds the Storyboard Entry Point item to the window controller.

    enter image description here