Reputation: 30025
I have
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
</array>
in info.plist and did a search and set every instance of shouldAutorotateToInterfaceOrientation
to return YES
. But on iPhone it behaves as if upsidedown is not supported. UpsideUp portrait works, landscapes work, updsidedown shows landscape. Why?
iPad works fine in all orientations. And they share .xibs
UPDATE
I have since added
- (BOOL)shouldAutorotate {
return YES;
}
- (NSUInteger)supportedInterfaceOrientations {
return UIInterfaceOrientationMaskAll;
}
after every existing instance of shouldAutorotateToInterfaceOrientation
and still no love.
I am targeting iOS 4.3 but my simulator and physical device run iOS 6
Upvotes: 11
Views: 7520
Reputation: 1892
Need some more context based on what you've tried already? Are you using a NIB-based setup with a navigation controller, tab bar controller or something like that? If so, you need to add a category to support it because you can't override the implementation of those classes in NIBs (or in general)
https://stackoverflow.com/a/12758715/490180
Talks about iPhone 5, but the issue is really iOS6 related.
Upvotes: 6
Reputation: 3585
It's by design. The reason being the iPhone is a phone and if the UI can be rotated upside down, the user will have problems when a phone call comes in. There is no nice sequence for dealing with an upside down UI. If your app were rotated upside down, the incoming call screen would have to be upside down relative to your app, which would not be a good experience. If it were not, user's would be answering the phone holding the hardware upside down, which would be quite funny, but not in a good way.
Upvotes: -1