I have a UIViewController detail view which is pushed from a UITableView in a UINavigationController. In the UIViewController I add a number of subviews (e.g a UITextView, UIImageView).
In iOS5 I used this code to stop autorotation if my picture view was enlarged :
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
// Return YES for supported orientations
if (scrollView.isZoomed) {
return NO;
}
else {
return YES;
}
}
I am trying to achieve the same thing under iOS6 using :
- (BOOL)shouldAutorotate {
return FALSE;
}
However this method is never called and the app continues rotating.
Can anyone help ?