My iPad app makes heavy use of autorotation. This is great. However, I've noticed that if a hidden view is released by the default implementation of didReceiveMemoryWarning
(as described here), when the view is re-loaded from the nib and I happen to be in landscape, it loads it in portrait. This wreaks havoc with the interface until I rotate the iPad manually and force it to go to the proper orientation.
I had assumed that iOS would load the view in the current orientation; that's what it does when the app launches. But it no, not after being unloaded by didReceiveMemoryWarning
. Why not? And how can I get it to do that?
-willAnimateRotationToInterfaceOrientation:duration:
method. Maybe it's not getting called because the rotation isn't animated? – Prajna-willRotateToInterfaceOrientation:duration:
nor-willAnimateRotationToInterfaceOrientation:duration:
gets called. They're both called on app launch… – Prajna