UIStoryboard load from app delegate

前端 未结 4 1318
情歌与酒
情歌与酒 2021-01-11 13:24

I am trying to load a UIStoryboard from the app delegate .m in this way:

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDi         


        
4条回答
  •  迷失自我
    2021-01-11 13:43

    It doesn't work this way now.

    In the build settings plist there is add an entry for Main Storyboard (or something like that). The all you need in the applicationDidFinishLoading is return YES;

    If you start a new project with storyboards ticked you can see the exact entry.

    When that's in there you don't need to load the initial view as it takes it from the storyboard file (Is Initial View flag).

    HTH

提交回复
热议问题