Reputation: 809
I am building my own app (but I'm a beginner) and I want to know if there are tutorials about "launch screens" in Xcode6. I also want to know if it is possible to test the internet connexion before displaying the storyboard. Thanks for your answers ! :)
Upvotes: 0
Views: 5205
Reputation: 1412
I am adding here the steps in short for creating the LaunchScreen through xib instead of using storyboard for iOS 8. This could be useful for persons like me, searching for how to create Launch Screen in iOS 8.
1) create a new "LaunchScreen xib" from new file --> user interface --> launch screen ( keep auto layout ON ).
2) Add an image view in the xib --> view (main view).
3) set splash image to it ( the image should not be in assets file ).
4) set image as "Aspect Fit" ( if required ).
5) you may also change the "view" (super view) background color as close to background color of image.
6) select the image view, click from menu - editor - pin - bottom space to super view.
7) this will show red error mark near "view" ( super view of image view ).
8) click on the error mark, you will see approximate two auto layout errors.
9) on clicking on the error you will find menu with auto fix the layout errors.
10) on fixing the errors, you will find total four "Constraints" with "vertical" and "horizontal" space between superview and image.
11) now you may test them in different devices or simulators.
Regards.
Upvotes: 0
Reputation: 78
I think this will help:
http://oleb.net/blog/2014/08/replacing-launch-images-with-storyboards/
Also, I would recommend not making the display of your storyboard wait until after you test the internet connection, as this could make the launch of your app slow.
If you are using a Storyboard by declaring it in your plist file as is typically done, then this is the order in which events occur:
Therefore the storyboard and initial view controller will have already been instantiated by the time application:didFinishLaunchWithOptions:. If you really needed to do the connection test before the storyboard was loaded then you could not declare the storyboard in your plist and you could load the Storyboard programatically in your application:didFinishLaunchWithOptions: method after you have done your test. I would not recommend this however.
Upvotes: 4