Startscreen in iPad shows 2 splash-screens - iphone

I have the problem that starting my app on iPad shows me 2 splash-screens. First one is correct iPad-splash. Second seems to be the splash of iPhone app (replaces the first one after about 500ms).
The devices-option in build settings is set to "universal".
Filenames for the images are:
Default-Landscape~ipad.png
Default-Portrait~ipad.png
Default#2x.png
Default.png
(in that order, not sure if that matters)
has anyone an idea why this happens?
Thx in advance.
max

Simply add a Default~ipad.png file to your project for a iPad specific splash. The Default.png is meant for iPhone. For more info, see also the good blog entry Icons and launch images for iPhone and iPad apps.

Related

App launches in full screen in simulator, but not on device

This is an Xcode 6 Swift project. When choosing iPhone 5 or 5s in the simulator, the app launches at full screen height. However, when running the app on an actual device (an iPhone 5s), the screen is only iPhone 4 in height (i.e. black bars appear at the top and bottom of the screen).
The strange thing is that I've re-created this project from another test project - and in the original project I didn't have this problem.
I've performed a text-compare on the storyboard xml files for each, and both are mostly identical. I've also looked at the Build Settings for each, and can't see any obvious differences. Finally, the json files specified in the "Images.xcassets" directory for each are the same.
Managed to fix the problem. In the General settings for the target, under "App Icons and Launch Images" I clicked the "Use Asset Catalog" button and followed the options.
Place the Launch screen images for both iphone 5 and iphone 4 . Put the size of the default-568#2x image as 640 x 1136 .
May be you missed this size of splash screen in your project.
For me it was fixed after adding the images with all sizes
For me, this was because I'd saved the file in photoshop format, but with a PNG extension. The emulator loaded the file, but the actual device couldn't. Wasted 3 hours messing with asset catalogs before I figured it out!
Blog post on subject

Black screen instead of launch image on iPad

I am developing an iPhone app for iOS 6.1 and 7 (using Xcode 5). I have a problem with iPad launch images.
On iPad 7.0 and 7.0.2, the launch image is not showing up(in 6.1 works!): I get black screen while app is loading.
I don't face this issue with iPhone 6.1 and 7.0.2, although I set all launch images required for iPad and iPad retina (landscape and portrait) and I use Asset Catalog.
What am I missing?
Recently I faced same issue with my App designed only for iPhone , I had the problem where the launch images would not appear in iPad (On iPad ios >= 7.0.x the launch image is not showing up I get black screen while app is loading (in iPad ios < 7.0.x it works fine )).
I don't face this issue of launch image with iPhone worked fine in all iOS versions.
Solution: Is to update to asset catalog to manage your app's images and target only iOS 6 and Prior.
Steps :
Step 1:
Step 2:
Step 3: on the top right corner click on the 'Attribute Inspector' icon. Here you can set the Target OS for the Launch Images.
Uncheck the iOS 7 check boxes for iPhone, Now you should be able to see the launch images for iPad on iOS >= 7.0.x.
If you have the same situation like mine, that's solution:
My app is landscape only, iOs7 only, ipad\iphone (XCode 5).
Problem: black launch on iphone (and simulator), normal launch in ipad.
Solution: go to Images.xcassets - Launch Images - select it. Uncheck at right all "iOs7 and later" boxes. Check "iOs6 and prior" boxes and fill empty spaces with images.
Strange, but works.
Per Apple's documentation (link); an empty iPad specific storyboard may be the answer. I've also seen issues where the initial view controller is not set within a storyboard causes a black screen. A variant of this issue might be an incorrect setting in the app plist.
Technical Q&A QA1780
Why does my app launch to a black screen on iPad?
Q: Why does my app launch to a black screen on iPad?
A: Apps that have been designed only for iPhone may launch to a blank screen when run on an iPad. This is caused by the presence of an empty iPad specific storyboard in the app bundle as well as an iPad specific UIMainStoryboardFile key in the app's Information Property List (Info.plist) file. Both are automatically created by the various Xcode template projects if the Universal option is selected.
...
In Xcode
Look for a file named MainStoryboard_iPad.storyboard in the file navigator. If this file is present, remove it from your project.
In your app's Information Property List
Look for a key named Main storyboard file base name (iPad) or UIMainStoryboardFile~ipad. If this key is present, remove it. You should also remove any other key suffixed with (iPad) or ~ipad.
Finally, test your app on an iPad or in the iPad simulator and verify that it behaves as expected.
I requested Apple support and it turned out that it's a bug. They asked me to report it and I did. Here is the report id : 15340531.
Now it's up to them.
Using LaunchScreen.storyboard
I was having a similar problem until I found the following settings in the General Project Settings.
Set your Main Interface to your main storyboard file. Mine is called Main.storyboard.
Set your Launch Screen File to your launch screen storyboard file. Mine is called LaunchScreen.storyboard. (This is what I had originally ommited.)
After that the launch screen loaded first and then the main story board loaded shortly later.
Try set the image again make sure that resolution of the splash screen is according to the iOS 7 guidelines
I know this sounds stupid. I've had bugs like that when I saved a file in psd-format with a jpg extension. Just 1 wrong click while saving your launch image.
After having tried several solutions found here, I suspected that the iPhone was trying to launch in Landscape orientation, and thus not finding any corresponding launch image. Indeed, the simulator was starting in Landscape for a reason I was not understanding.
Finally, after reading Apple documentation, I found that it's probably the order of keys in "Supported interface orientations" of the info.plist file that was not adequate. The Portrait was the last item. When it's the first item, the app launch in Portrait mode and find the image.
Remove previously installed app from the device or simulator, Then relaunch the app after clean.
I had the problem where the launch images would no appear in iPhone (3.5 or 4 inch) in iOS 7, but the iPad had no problems with iOS 7.
Long story short is I disabled the asset catalog for the launch images only. So I'm adding the launch images the old fashioned way. That seems to have solved the problem.
I will have to do more testing tomorrow, but it seems the problem is solved (at least in my case).
in Xcode 5 , make sure thay you add all needed images mentioned in your app target.
I am assuming that when you are using Asset Catalog, you have ensured that you have the Images.xcassets target membership added correctly. I am mentioning this since if you have multiple targets, looks like you have to add them manually (and you have not provided any screenshots so one can be sure).
Now that you have not really provided a screenshot of the "LaunchImage" overview of Images.xcassets folder in your project, I can only guess the probable reason. Looking at the fact that the launch images work fine for iPhone (6.1 & 7.0.2 and iPad (6.1) and do not work only for iPad (7.0 and upwards), I think you could perhaps look at as to whether the dimension of the images for iPad Portrait and iPad Landscape are proper for iOS7. Specifically, you should see your launch images and not empty rectangles as seen in the attached pic-
This can happen due to the fact that you still have the iPad launch images for iOS7 created excluding the status bar area. Prior to iOS7, the iPad launch images were created to exclude the status bar area, but it's a must on iOS7 that all the launch images must include the status bar area. Please go through the section "Things Every App Must Do" in Apple iOS7 UI transition Guide (https://developer.apple.com/library/ios/documentation/userexperience/conceptual/TransitionGuide/TransitionGuide.pdf).
The following screenshot should explain what I am talking about-
e.g. you can see that iPad Landscape Retina image dimension for iOS6.1 and previous is 2048x1496 (excluding 40 px for status bar) but the dimension for the same image for iOS7.0 and upwards is expected to be 2048x1536 (including the 40px for status bar). So, if you have not changed your images accordingly, you will see black screen for images on iPad 7.0 and upwards. On iPhones, you will not face this issue since iPhone launch images always cover the status bar, be it iOS6.0 and iOS7.0- so the new UI requirement is already met for iPhone launch images.
I found this answer which worked for our app (iPhone only, but used on iPad): https://stackoverflow.com/a/19448782/1258419
To summarize from that answer:
How to do it. Go to the asset catalog. And on the top right corner click on the 'Attribute Inspector' icon. Here you can set the Target OS for the Launch Images. Uncheck the iOS 7 check boxes for iPhone. Now you should be able to see the launch images for these devices.
I encountered a similar problem in landscape, my iOS 7 launch image wasn’t displayed while the iOS 6 did. Mine was the iPhone Retina 3.5” launch image.
Since I have another app in portrait that didn’t share this issue, I did 2 things:
In info.plist, under “Supported interface orientations”, I added the
2 portrait modes as well, and put them before the landscape, like
this:
Item 0: Portrait (top home button)
Item 1: Portrait (bottom home button)
Item 2: Landscape (right home button)
Item 3: Landscape (left home button)
Implemented this method in the View Controller:
-(NSUInteger)supportedInterfaceOrientations{
return UIInterfaceOrientationMaskLandscape;
}
This works with or without the Asset Catalog.
This is an update for iOS 8.
I got the same problem when I tried to add a LaunchImage to my iOS 8 app.
Apple enables developers to use a xib, whose default name is LaunchScreen.xib, to render the launch view as of iOS 8. I believe developers can use either LaunchImage or LaunchScreen.xib. Unfortunately, I couldn't find any document describing how to deal with LaunchImage after LaunchScreen.xib was introduced. I always got a black screen when I tried to use LaunchImage as the launch view.
My solution is:
Don't think about LaunchImage. Use LaunchScreen.xib. (You have to keep an empty LaunchImage in your Asset Catalog though. I believe it's a bug.)
Drag an UIImageView to the xib and make the UIImageView full screen. Remember to take the size classes and constraints into account.
Set an image whose resolution is enough for iPhone 6 plus to the UIImageView.
Check your all images and see if it is properly placed in the Asset and properly named and sized.
Also check which orientations your are allowing and accordingly add images to the asset.
I had the same problem.
I had to make a workaround: used the Default image for all iOS versions and DELETED the UILaunchImageFile key from info.plist.
I cannot use different launch images for iOS 7 and previous versions, so, I had to use the same "artistic" image for all, instead an image that mimic the first view of the app (which Apple recommends and I prefer), but at least I do not get the black screen anymore.
It looks like the UILaunchImageFile key that allows to use differents launch images for iOS 7 and previous versions is not working properly for Retina iPad in iOS 7.
WARNING: I am still testing the app, so I don't know if could be some side effects.
I also faced the similar issue but its solution was simple (in my case).
All I did was following -
1.Add a new file (if you have not added it) Launchscreen.storyboard
2.Get a UIViewController, mark it as Is Initial View Controller then add a UIImageView in it and set a picture which you want to display during launch of your app. Make sure you give this UIImageView required constraint.
3.Go to Project->General->App Icons and Launch images and select Launchscreen.storyboard as Launch Screen File (There will be a dropdown for it).
Because of iOS 13 and later, app launch different than earlier versions.
Get the solution from below URL.
https://stackoverflow.com/a/59913274/883505
I simply forgot to call super.loadView() in my view controller...
override func loadView() {
super.loadView()
}

How to make my iphone app work on an iPad?

It is my understanding (i have seen it) that some apps can be opened and viewed in an iPad. Although, the iPad keeps the screen small, or pixelated if doubled the screen size.
I am attempting to do the same thing with my app, however when I attempt to run it on an iPad it crashes with the error
'Could not find a storyboard named 'MainStoryboard_iPad'
This is obvious, as I do no have a storyboard for the iPad, but currently I don't want one. I just want the iPad to run the app as an iPhone app in a smaller version. So my question is, how do I stop it from looking for the iPad storyboard? Its my understanding I must adjust something in the plist.info but I don't know how to access that in xcode. its my understanding you select the project in the navigator then select 'info' but I don't see any information that people say should be in the plist.info.
Thanks
You seem to have made your application universal. You want to set your "devices" to iPhone. This can be done on the target summary page (No need to interact with your .plist directly).
Only target iPhone platform, and do not call any iPad interface objects in your code. You should look in your Main xib file to make sure there are no references to an iPad interface object.
iPhone only apps should natively run in double-pixel mode. In order to resolve the pixelated / grainy issue you see, use #2x (for iPhone) size images. This will reduce the pixelation you see, but will still contain some.
Ok, I found the final issue. After editing the summary to 'iPhone' I also had to go into the Info tab and change the line that says
'Main storyboard file base name (iPad) to MainStoryboard_iPhone. It was currently set to MainStoryboard_iPad. That second step fixed the issue.
Thanks guys!

Missing Localized Screenshots Error on itunes

I have selected Default Language as "Australian English" as Default language. When I am submitting the binary it showing as rejected"Red Icon" with status "Missing Localized Screenshots". The application is in only single language. I have added screen shots also the application is only for iphone.
When I am looking binary information that is showing as:
Localizations : ( "en-AU" )
Please suggest me where I am making mistake.
Check if you have screenshots for iPhone 5. I had this same error, when screenshots for iP5 were missing.
Basically the error telling you that you need to upload the iPhone5 device screen shot(at least one screen shot).
So solution of the problem:
1.Either you can upload the screen shots for iPhone5 Device . OR
2.You can just removed the Default-568h.png from your binary , in this case your application just run in the "letterbox" mode on iPhone5 Device.
So which ever is easy for you just adopt it .
I adopted the second one when i face the problem.
HAPPY TO HELP:):)
Just make sure to upload iPhone 5's screen shots .My app wasn't made for iphone 5 but I ran it on iphone 5 simulator and took screen shots and uploaded and every thing went ok.
All above answers seems right, but this can happen too if you have NO screenshots for 3.5" - RETINA, beware.
If you already have screenshots for 3-in & 4-in, add a single screenshot for iPad and that should fix your problem. The iPad shot is compulsory.
Issue has been solved still posting may be it help someone. Please follow below steps:
1- Upload 5.5 inch display screenshots.
2- Click on "Device Manager".
3- Here you will have list of screen sizes with the options to expand on left side and a check box on right hand side "Use 5.5-Inch Display","Use 4.7-Inch Display".... and so on. Click on these checkboxes if you don't want to use different images than 5.5 inch display screenshots else upload new images here with correct dimensions.
4- Click save.
In my case, I had the iPhone 5 (4" display) screenshots, but it also wanted 3.5" retina screenshots.
I added these, and the app went into 'Waiting for Review' state without further action.
I had the same problem, my solution was to change "Devices" in Development target only to iPhone (bacause i insert screens only for iPhone):
There is nothing wrong with your app - you need to add the screenshots from the iTunes Connect metadata and uploads section.
Once I'd added these in all went through and the app won't automatically flagged as missing localized screenshots.
Not the best of messages, but not wildly inaccurate.
I had this problem and mine was a Universal iOS app made in GameSalad Creator, you need screenshots for all the relevant screens even if it lets you progress without them.
I had changed the name of the app in the previous version and it choked on that. I changed the name of the app back to what it was and it went through fine..

How can I make my iPhone 3GS icons in my app iPhone-4 savvy

I have a quite simple question concerning the difference in screen size between the iPhone 3/3GS and the iPhone 4. I've googled around, but was unable to come up with a good explanation.
Here's the thing: tabbar icons. All my icons are 30x30 and 60x60. I named the high resolution ones like [icon]#2x.png. When I load my app on my own iPhone 3GS, all goes fine. But when I load the app in Simulator, simulating a 4 with retina-display, the icon looks pixelated and is clearly the wrong resolution.
What am I doing wrong? These were the exact steps I followed, but I'm probably missing something. Is there something like an option I need to set in the plist?
Any help is greatly appreciated!
Kind regards,
Reinder
You need to name the icons as you have and edit your plist file
The following link should help
http://developer.apple.com/library/ios/#qa/qa2010/qa1686.html
Make sure you clean and build and remove the existing application from your phone and the simulator to see the results
The complete set of icon sizes distilled is
Icon.png – Home screen icon for iPhone 3 (57×57)
Icon#2x.png – Home screen icon for iPhone 4 (114×114)
Icon-72.png – Home screen icon for iPad (72×72)
Icon-Small.png - Settings/Spotlight icon for iPhone 3 (29×29)
Icon-Small#2x.png – Settings/Spotlight icon for iPhone 4 (58×58)
Icon-Small-50.png – Spotlight icon for iPad (50×50)
iTunesArtwork – Icon for iTunes AdHoc distribution (512×512)
It seems that you're doing it the right way. Did you try to remove the app from the simulator? Clean up the project? Re-import the icon image files?
Try (with the simulator stopped) cleaning all targets and re-building. Sometimes xcode gets dumb about what files it's got and needs to be told to clear its cached build and start fresh. It's in the "build" menu, or ctrl-shift-K.