Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how does LaunchScreen.storyboard redirect to Main.storyboard

I'm newbie of iOS developer, and I know that is very simple question but I really can't understand reason.

when I build SingleViewApplication, Xcode auto generate LaunchScreen.storyboard and Main.storyboard,

but I can't find any code like [self.navigationController pushViewController:] which may choose that what view controller enter stack as last one of top-level view,

I only find ViewController.{h,m} as first and see no logic that change view from LaunchScreen.storyboard to Main.storyboard.

could anyone help? thanks..

like image 801
E_Jovi Avatar asked Oct 19 '22 18:10

E_Jovi


2 Answers

Main.storyboard file and LaunchScreen is define in your project property. you can find it by click on project in xcode and then in below target you can find this two name you can choose your own by selecting dropdown given beside label.

and other redirecting to LaunchScreen to Main.storyboard you can refer info.plist file in your project and also AppDelegate.h and AppDelegate.m

like image 59
Tejas Patel Avatar answered Oct 21 '22 16:10

Tejas Patel


Most probably the iOS first looks for LaunchScreen.storyboard file and shows it for some time and when it is done with it, it looks for Main.storyboard.

These names are hardwired in the plist as mentioned by Tejas in his answer and you can change these.

like image 31
Ankit Srivastava Avatar answered Oct 21 '22 15:10

Ankit Srivastava