I recently upgraded my XCode to 4.5 version and now I'm having problems when I try to develop applications to iOS 5.0/5.1.
I developed a simple iPad game where the user needs to match images with the correspondent words. All these items are stored in UIImageView, if that is relevant. The supported interface orientation is only landscape.
When I run my application using iPad 6.0 Simulator everything works fine without any problem. But when I try to run it using 5.1, everything goes wrong. The images simply don't appear and my background image appears sideways and repeated. The status bar also appears wrongly: the device orientation is landscape, but the sidebar appears on the right side. This also doesn't happen when I use 6.0 simulator.
In the project details I already changed the iOS Deployment Target to 5.1, as well in the Storyboard. Using iOS 5.1 deployment target the storyboard don't let me to select "Use Autolayout" option, so I deselected this option. Is this caused by this option?
I already tried to run my application in a device, but the result is the same. Since I installed XCode 4.5 I started to have these kind of issues, since for example I can't even run a "Master-detail Application" template properly in iOS 5.x simulator, because it crashes when I click the "Add" button.
Am I missing something to run 5.x applications created using SDK 6? I already searched in a lot of forums but I haven't found any solution to this kind of problem yet. I'll be glad to ear any kind of suggestions, since I already lost lots of time around this issue and I'm running out of options.
[EDIT]: I remembered a detail that maybe can be relevant for this problem: my view in storyboard is a custom view. I created a class that extends from UIView so that I could override drawRect function to draw lines between my objects. Then in Storyboard, in the View, I just selected my class in Custom Class -> Class.
I noticed that when I run 5.1 Simulator the status bar initially appears on the top and then when the window is loaded it goes to the right.
If you want to know any other detail please just ask me.
Thank you very much.
English isn't my native so please forgive my grammar...
As far as your Master-detail "Add" button issue, this is what worked for me.
From what I can tell, the app crashes because of:
Quick Help says:
So I tried changing the code in MasterViewController.m:
for code that Xcode used in older versions:
Hope this helps.
Have you checked your storyboard to make sure you have shut off Autolayout? Autolayout only works with iOS6. This option can be found when looking at your view controller in the File Inspector Area under Interface Builder Document. It is a checkbox
Seems like you're not the only person with Simulator 5.1 issues in XCode 4.5. Bug in iPhone Simulator 5.1 with Xcode 4.5 using UIManagedDocument My apps broke too. 5.0 sim seems to work well enough.