I am using splitviewcontroller as the rootview of my application. I need to show the login and registration view as a modal view on top of the splitview controller. When I try to present the login / reg view from the viewdidAppear method in the splitViewController root directory, it does not appear. I tried to present the login / reg view from the appdelegate didFinishLaunching method using the following code
[self.window.rootViewController presentModalViewController:self.navController animated:NO];
and it works.
My problem is that the application supports both landscape orientation, but when I run it on the device, no matter what orientation I hold the device in, I only get LandscapeRight as orientation. Therefore, if I hold the device in the LandscapeLeft orientation, the lauches application with the login screen upside down. I use LandscapeLeft and Right in the supported orientations on info.plist.
Please help me solve the problem. Also, how do we present the view when we have splitViewcontroller as the root directory of the application?
In iOS 5.0 (only) I can imagine the login view from the rootviewcontroller rootview controller - viewdidAppear. In all other OS versions, this case does not work, and I have to present it from the appdelegate didFinishLaunching method.
source share