iPhone with iOS 14 beta 2 doesn't autorotate when connected to XCode debugger
I haven't tried the iOS 14.4 beta, does anyone know if it's still broken there?
I was starting to think I was crazy until I found this thread.
rotation is NOT working on iPhone OS, although methods like shouldAutorotate or supportedInterfaceOrientations are called when running with the debugger (but e.g. viewWillTransitionToSize never gets called afterwards)
rotation for the same project IS working when running in the simulator
rotation IS working on iPad when running with the debugger
rotation IS working on physical device when starting the app without Xcode
rotation IS working for a newly created simple iOS App with just a "Hello"-Screen while running in the debugger
Our project uses a GLKViewController subclass as main entry point
I'm currently trying to understand what is causing the issue because I have no problem with other projects. I'll update the answer if I find a solution.
So the steps are:
1) run your app with XCode
2) open control center in your device and lock the screen rotation, then unlock it again
3) close the control center and now the rotation should work
Unfortunately you have to repeat this every time...
Anyway this is just a workaround, I was hoping to find what was causing it in my code but I found no clues. I hope this trick is going to work for you too.
And the little "toggle screen lock" trick above doesn't work for me.
WTF
The control center trick doesn't work either.
Thanks for this thread! I have lost 2 hours before finding it...
Go to Product>Schemes>Manage Schemes
Select your scheme and click edit
Select the options tab for the run section
For 'GPU Frame Capture', select 'Metal' or 'disable'
I guess your answer can be accepted as the right solution for this question.