Hi,
As I’ve started actively working with Corona, I’ve just noticed that problem last night.
When the device orientation is changed, contents of the OpenGL canvas rotated instantly while it’s followed by the native UI rotation animation. Sampled in 1st image below.
When using native orientation support I was expecting default rotation behavior where both rotated at once. As illustrated in 2nd image below.
Also, some other apps such as Angry Birds appears to be disabled that rotation animation which is also ok. Contents rotated instantly as Corona does. But there is no following mask animation.
I found few threads over this but none of them concluded with a solution.
Following is a solution for Unity, based on disabling the keyboard…
iPhoneKeyboard.autorotateToPortrait = false;
iPhoneKeyboard.autorotateToPortraitUpsideDown = false;
iPhoneKeyboard.autorotateToLandscapeLeft = false;
iPhoneKeyboard.autorotateToLandscapeRight = false;
Current configuration docs states we can fix the canvas (content statement in build.settings) and allow only the UI rotate. If we had access to direct opposite of this by fixing the UI but allowing to content roatate, that might also work…
I think following property might help fixing that also…
- (void)setStatusBarOrientation:(UIInterfaceOrientation)interfaceOrientation animated:(BOOL)animated
Parameters
interfaceOrientation
A specific orientation of the status bar. See UIInterfaceOrientation for details. The default value is UIInterfaceOrientationPortrait.
animated
YES if the transition to the new orientation should be animated; NO if it should be immediate, without animation. [import]uid: 10478 topic_id: 9803 reply_id: 309803[/import]