How can I change a window orientation to landscape in XCode 4 Interface Builder?

后端 未结 1 1776
情话喂你
情话喂你 2021-01-05 13:53

I appreciate I\'m probably missing something basic here, but...

My iPad app will only support landscape mode, and has a MainWindow.xib Window that I\'d like to work

相关标签:
1条回答
  • 2021-01-05 14:46

    I think it's because apps always starts up in portrait and then rotates to appropriate oriantations. From the UIViewController docs:

    Note: At launch time, applications should always set up their interface in a portrait orientation. After the application:didFinishLaunchingWithOptions: method returns, the application uses the view controller rotation mechanism described above to rotate the views to the appropriate orientation prior to showing the window.

    So you'll need the UIViewController magic for the simulated metrics to make any sense. If you used the "Window-based application" template as a starting point for your project try the "View-based application" template instead.

    0 讨论(0)
提交回复
热议问题