Hi, my requirement is :
in Scene1, the orientation should be locked to portrait.
while in Scene2, the orientation should be locked to landscape.
In RootviewController’s shouldAutorotateToOrientation method, I judged the current scene, if it is Scene1 then return UIInterfaceOrientationIsPortrait(…) ,otherwise return UIInterfaceOrientationIsLandscape(…);
Now the problem is that, when I replace scene from Scene1 to Scene2, I need to force the device orientation to Landscape, even if the current orientation is Portrait.
Is There any way to implement this ?
I tried [[UIApplication sharedApplication] setStatusBarOrientation:animated] and [UIViewController attemptRotationToDeviceOrientation] but they don’t work.
Can anyone help me ?
Thanks very much.