I have an application compiled for iOS8. The app is set to allow portrait orientation only in the project settings. The views of the application do not rotate to landscape by design. In iOS7 when you rotate the device to landscape the keyboard is not rotated. This is the behaviour I desire.
However, in iOS8 when you rotate the device to landscape the keyboard will incorrectly switch to landscape orientation.
I have tested this on a physical iPhone 6 Plus to confirm the issue. Also tested it on iPhone 5 via simulator. Any idea how to fix this issue?
POTENTIAL FIX
I don't remember exactly why I was doing it but I have some bootstrapping code that executes when the app starts:
d.window.rootViewController = tabBarController;
Where tabBarController is the top level tab bar controller for the app. Removing this bootstrapping code fixes the issue.
SUGGESTED DEBUGGING
Whilst this did not appear in previous versions of iOS it looks like iOS8 behaves a bit differently. I would recommend checking any bootstrapping code you have. You may have to try a sample project and add some bits until you find the culprit as it was quite hard to track down in my case. The two answers provided below are kind of fixing the symptoms not the cause so I have not marked them as correct.