Fix iPad status bar orientation as portrait

2019-08-04 07:38发布

问题:

I have an iPad application with a simple tab bar. I need to fix the orientation as portrait. I do that by setting "Portrait (bottom home button)" in the "Supported interface orientation" field in the plist file.

The problem is that the status bar still move when rotating the iPad... how can I fix it ??

Thanks for reading.

回答1:

Remove the default implementation of shouldAutorotateToInterfaceOrientation: from all your view controllers.