I wonder if you have any idea of why my Launch image get displayed upside down when using the iPhone application/storyboard on the iPad simulator. After the launch image the orientation is correct.
Running on iPad device also has the correct orientation. It is only the when running iPhone application on iPad it does not work. iPhone all works fine.
Any ideas?
I had the same problem today without having changed the UISupportedOrientation-key (my app supports all 4 orientations) while I was changing values in the summary view (Xcode 4.2). The app started to do strange behaviours while loading the launch image, it changed the orientation to upsideDown. I solved the problem by just by changing the sequence of the 4 different orientation levels. 1st element was somehow PortraitUpsideDown and the 4th element Portrait, I swapped these two values and then it was working smooth again.
Related
Some wierd stuff is going on in a app that i recently took over development of. For some reason, when i launch the app with simulator iPhone retina (4-inch) the app launches like this:
In the story board, the views look correct when i change to iPhone5.
I just dragged out a clean controller and set it as the initial one, so no messed up code in the controllers should cause this.
What am I missing?!
Thanks
You are missing the fact that the app is not optimized for iPhone 5. It is as easy as setting the correct launch image - Default-568h#2x.png
You need to add a Retina 4 launch image. Default-568h#2x.png is required to run at native resolution on retina 4 devices.
I'm using Xcode 4.6.3 and my storyboard looks like this ,
When I run the app in any other hardware configuration (All sizes, iPhones and iPads) it works perfectly except the 4-inch retina. It cuts off at the top and at the bottom.
When i press home on the simulator the home-screen and the rest looks normal
I'm completely baffled by what can cause this and i don't have an actual device with that size to test on.
Anyone with this problem in xcode 5 (with your Default-568h#2x.png already included) may want to try creating an Asset collection - it fixed it for me (it also fixed a problem I had of icons and launch images not updating in the simulator)!
I am wondering if anyone else has had this happen to them. I have a iPhone App that I have been updating for over a year and it has been working just fine on my iPad2, iPhone 3GS, as well as the 4G, 4GS, and 5. However, just recently I obtained an iPad3 to test the App on. Something very strange happens: When the App is loaded through Xcode in development it comes up and looks perfect - however, it won't respond to any touches at all. I have an alert that pops up on load and you can close that, but the actual main view controller will not react to any drag or touch gestures - it is essentially frozen. However! When I rotate the device and the App rotates correctly, it suddenly starts working just fine, even if I rotate it back! The simulator for the iPad running iOS6 in normal and retina does the same thing even though it works just fine on my iPad2. However, the simulator for the iPhone works just fine.
Like I said, this doesn't happen on any other device. Even loaded the same way all devices allow tapping like normal. Here is what I have been able to confirm:
iPad3 device: frozen
iPad-retina sim: frozen
iPad-normal sim: frozen
iPad2 device: normal
iPhone-retina sim: normal
iPhone-normal sim: normal
iPhone 4S device: normal
iPhone 4 device: normal
If all the iPhones worked and the iPads didn't, it would make some sense. But my ipad2 works just fine. Also, if I use the iPad3 open it, it is frozen. BUT! If I hit the 2X button, it starts working again even without rotation.
I also decided to test and see if it would work as a Universal App. On the iPad3 when I switch it over to Universal, it works just fine to begin with. So something weird must be going on with the simulator. Any ideas?
Thanks!!
-Mark
A view (in your case the whole thing) not accepting any input often means that one of the superviews has a frame smaller than its contents. This could be the case here, strangely only in specific situations, upon rotation the view frame gets the correct size and stays correct afterwards.
Did you solve this in the meantime? You can try to give the views different transparent background colors and/or make them clipToBounds, starting with the top view controller's view. That way you'll see if something is wrong with the frames.
I've got a very strange behavior in my iPhone app.
The app should run in any orientation. Plist keys are all set and shouldAutorotateToInterfaceOrientation always returns YES.
Also, it's an iPhone only app, but at this moment I can test it only on the iPad.
Now, when I start it in portrait mode, everything works fine. However, if it launches in landscape mode, the view doesn't receive any touch input, buttons and gestures simply don't work. This is happening as long as the window remains unaltered. If I rotate the app and then rotate it back to landscape, it works. Moreover, if I press the "2x" button on the iPad, the app also starts to work normally.
I've checked all view frames and everything is drawn correctly.
When run in simulator, it ignores the initial orientation and draws itself in portrait mode.
What can be the reason and how to solve it?
I have found that this is unique to iOS 6 (you'll see this on iPads running iOS 6 and even the iOS 6 iPad simulator, but not devices/simulator running iOS 5). If you remove all of the entries under "Supported interface orientation" in the app's plist, this problem seems to go away. Alternatively, if you check the "Hide during application launch" option for the "Status Bar" settings on the Summary screen of the Target settings, this also fixes it:
It makes no sense why either of these should fix the bug, but they appear to.
If you use the "Supported Orientations" tweak, in iOS 6, you can still programmatically control the permitted interface orientations via supportedInterfaceOrientations (in iOS 5, you can still useshouldAutorotateToInterfaceOrientation:).
I'm making an app for the iPad with TV output to an extra screen. Everything works fine, but for some reason the TV out window disappears when I put the iPad in landscape mode. I commented all the code that makes it go to landscape automatically but as soon as I rotate in iPhone simulator, the tv output window goes away.
Is it just not possible to have the device in landscape mode with an extra screen or is there something I'm overlooking?
Thanks in advance.
I've noticed there's a CALayer use-after-release bug in iOS7.0.3 simulator when you have setup an External Screen triggering at some point, but a later iOS7.1 fixes that. Can you confirm if you have the problem with iOS 7.1 ?