Remove launch screen if device version in iOS 8 - ios

I have an application which works for iOS 7 and 8 and I'm using auto layout so it will be ok on all iPhones. For iOS 7 I need the launch screen file but for iOS 8 I want to hide it.
How can I remove it specifically for iOS 8?
Thanks in advance :)

The launch screen is processed and displayed by iOS before anything else happens. You can't do anything programmatically to affect the launch screen as your code won't run until after the launch screen has been displayed.
So the only thing you can do is take advantage of the xib launch screen support introduced with iOS8, to provide two different launch screens: one for iOS8+ (the xib) and one for iOS7 and lower (the png).

In the HIG it says the following...
In iOS 8 and later, you can create a XIB or storyboard file instead of
a static launch image...
..
If you also need to support earlier versions of iOS, you can continue to supply static launch images in addition to a launch file.

Related

Launch screen is not being presented for iOS 9

I am having issues displaying an image as a launch screen. I have added some images that will walk you through what I have done.
My recommendation is to not use Launch Image and use the Launch Screen instead, since you can use auto layout and support any screen size, including iPad multitasking, or new devices released in the future.
However, if you really want to use the Launch Image, seems like iOS9 requires different launch images for each device orientation. That might be your issue.
iOS 9 enforces the UILaunchImages requirement; apps can no longer
declare the same launch image to support different interface
orientations.
https://developer.apple.com/library/prerelease/ios/releasenotes/General/RN-iOSSDK-9.0

In iOS 9 splash screen shows black and multi colours?

while open the old version project in to ios 9 the splash screen was shows in black screen and it displays the images in multi colors,please anyone help me for find the issue?
There is a change in Xcode7 iOS 9 onwards. They have modified Launchscreen(Black screen we will get).If you change deployment target means you can see the previous launch screen.
Only empty view controller is present so we have make changes on it.
I have solved the problem.
I am using Xcode 7 and my iPhone 6 is upgraded to IOS9. I was using Launchscreen.storyboard and was getting Black LaunchScreen.
I solved it by following steps:
1. I removed Launch screen interface file base name from info.plist
2. Under General Tab,in Launch ScreenImage use assets Catalogs, I set
images for iOS 8,iOS 7 and iOS 6 iPhone portrait.
My app is now running successfully with LaunchScreen.
I had the black launch screen issue with the new iOS 9 project I built using Unity (5.2). To fix that I added the image that I want to show as the launch image to the LaunchScreen-iPad.xib file's Image view.

Xcode/iOS Simulator not showing the app on fullscreen

I had this problem after I updated my Xcode to version 7.0.1
when I run the app on the simulator the bottom part of the app is not showing!.
this is screenshot of the simulator:
https://www.dropbox.com/s/e8cn14mxl7zgk58/Screenshot%202015-10-06%2009.49.25.png?dl=0
You are running your app from xcode 7. You can try it with simulator of iOS 9.0 SDK. That might work for you.
or otherwise check with your launch images. whether you have added launch screen for iPhone 6 or not in image assets.
I've had this problem when i didn't provide the correct launch screens for iPhone 5 (In your case iPhone 6). Check that, and if you can, i recommend using a xib for launch screen.
Sometimes It happens due to unordered items in Document Outline.
Make sure,It should follow this sequence in document outline.
1) View Controller Scene --> Top layout guide --> Bottom Layout guide --> View --> Navigation item.
2) First Responder
3) Exit

Is it mandatory to use Launch Screen File to support iPhone 6/6Plus?

I have only Default-568h#2x.png and Default-568h#3x.png in my bundle. When I execute the application in iPhone 6 and 6 Plus the app automatically does some scaling and displays the app utilising full screen size.
But when i use some .xib file as "Launch Screen File", the app stops scaling and does not displays for full screen, has various UI issues.
Is it mandatory to have launch file, if I need to support iOS 8 / iPhone 6 / iPhone Plus?
Is there any chance for the app to get rejected if the app does not use LAUNCH FILE?
Please let me know your comments.
You can use your storyboard for your launch screen now.
http://oleb.net/blog/2014/08/replacing-launch-images-with-storyboards/
NO.
LaunchScreen xib is a quick way to detect main screen.
Depending upon the main screen, OS runs your app and determines screen width and height.
Another approach is just to add launch images for iPhone 6 and 6 Plus instead of LaunchScreen file.
NOTE: Apple is motivating to use LaunchScreen, because it is a one file launch image. It can also be used for pads as well. Single file multi purpose.

iPhone 6 - app does not fill screen

Most of my apps scale up when run on an iPhone 6, but for some reason one of my apps looks like this:
What would cause it to not just scale up and fill the screen?
EDIT: Here are some repro steps:
Create a new project (Single View). Turn off size classes and just use iPhone.
Make the background orange.
Add a yellow UIView subview at (20,20,280,200).
In Xcode you get this:
Now simulate on iPhone 6. You get this:
Why doesn't it just scale up and look normal?
Not sure why this is getting downvoted. It's a legitimate question. And here's the legitimate answer:
Remove the "Launch Screen File" in Projects > General. Xcode 5 did not have this so older apps scale up automatically. Apps created with Xcode 6 get a default Launch Screen file created.
Removing it will make your app scale up on iPhone 6.
I have got the same problem and I managed to solve it by adding constraints to my ViewController in the storyboard.
Make sure that you clicked the ViewController of your scene. They yellow button in the this screenshot.
Click Editor-> Resolve Auto Layout issues -> Add Missing Constraints
Now you will find that the background image is scaled up to fill iPhone 6 or iPhone 6 plus.
Note that this solution works for me even if I did not provide any launch screen file.
I had the same issue. Searching for an answer, most of them mention the launch image. To me, what did the trick, was that I first enabled launch image for iOS8.0 and later in Xcode, which requires the native resolution sizes for 4.7" and 5.5". Adding these sizes didn't help, but when I re-disabled them, it started working!
If you do have any launch image, you will need launch images for all appropriate sizes. I was doing a minor update to an app, and it was not showing correctly on the iPhone 6 simulator. I created four launch images (.png files). Since the app should still run on iOS 7, I apparently could not use an asset catalog. I gave the images the correct names, and all is good.
Image sizes and names may be found here:
Sizes and Naming of Launch Image for iPhone app in iOS8

Resources