Just a quick question. Say I have updated my app to iOS6 and changed the shouldAutoRotate methods of iOS5 as follows :
- (BOOL) shouldAutorotate
{
return YES;
}
-(NSUInteger)supportedInterfaceOrientations
{
return UIInterfaceOrientationMaskLandscapeRight;
}
If I am still supporting iOS5, do I need to check for the iOS version and then also include the old iOS5 methods (i.e shouldAutoRotateToInterfaceOrientation) if the app is being run on a device running iOS5 ?
Thanks !
It’s ok to have both iOS5 and iOS6 code in your app.
On iOS5, supportedInterfaceOrientations and shouldAutorotate will not be called, and on iOS6 the old methods shouldRotateToInterfaceOrientation etc will not be called.