I am trying to develop a splitView based iPad app, that displays the split interface in every orientation. I have tried subclassing the UISplitViewController class as given
In the viewController class that implements the UISplitViewControllerDelegate Protocol (usually the DetailViewController), add the following code.
- (BOOL) splitViewController:(UISplitViewController *)svc shouldHideViewController:(UIViewController *)vc inOrientation:(UIInterfaceOrientation)orientation {
return NO;
}
According to the Docs, this has been available since iOS 5.
To see it in action:
-open Xcode.
-Create a new Master/Detail app.
-Add the above code to the DetailViewController
-Run in the iPad simulator.
In your own project you'll want to add the following line to the viewDidLoad method of the detailViewController.
self.splitViewController.delegate = self;