Reputation: 20412
My app is using a UISplitViewController, which provides a dual-pane in landscape mode for iPad/iPadMini.
I would like to always lock the app to landscape mode in case the device is an iPad or iPadMini.
How can I do that in Swift?
Upvotes: 0
Views: 268
Reputation: 16827
In your Info.plist file, look for Supported interface orientations (iPad), and remove any orientations that you do not want to support, that should force landscape only orientation, there may have to be other things you need to do in your code on top of this, but that is code dependent.
Upvotes: 1