Fittoburst
Fittoburst

Reputation: 2305

Starting iPad app in current landscape orientation

My ipad app only runs in landscape orientation. But when I test on an actual device (not the simulator) it always seem to start in one particular landscape orientation, then turn 180 degrees to match the current physical landscape orientation. So, it seems to start in LandscapeLeft(I think) then rotate 180 if I have it in LandscapeRight. There's nothing in Info.plist to set the initial orientation.

Can anyone suggest a way to detect current orientation before view loads and set it to correct landscape view before showing?

Thanks

Fitto

Upvotes: 1

Views: 599

Answers (2)

Jasarien
Jasarien

Reputation: 58448

There is the UIInterfaceOrientation~iPad key which sets the initial interface orientation on startup.

There is also the UISupportedInterfaceOrientations key which informs the app which orientations are supported.

There is no way, however, to make the app start in the current orientation of the iPad.

Upvotes: 1

Tustin2121
Tustin2121

Reputation: 2146

Have you looked into these questions?

Also, technically, the iPad should just do it. Make sure you have supported orientations set properly, as I'm sure it checks those to see where it should start.

Upvotes: 0

Related Questions