Prevent AlertView from auto rotating
The launch page of my app is set to portrait only with this little bit of code: - (NSUInteger)supportedInterfaceOrientations { return UIInterfaceOrientationMaskPortrait ; } When the app launches a UIAlertView appears for username and password entry. The method to display it is called from viewWillAppear . This worked fine for iOS6 but since iOS7 , if I switch the device to landscape, the main view remains in portrait but the the alert view and keyboard rotate to landscape. A further bizarre quirk is that when I switch back to portrait, only the keyboard switches back (in truncated form),