Starting an application in landscape mode

Discussion in 'iPhone/iPad Programming' started by mtgred, Aug 27, 2008.

  1. macrumors newbie

    Joined:
    Mar 30, 2008
    Location:
    Brussels, Belgium
    #1
    I would like to start a application in lanscape mode.

    For that a new key has been added to the info.plist file:
    <key>UIInterfaceOrientation</key>
    <string>UIInterfaceOrientationLandscapeRight</string>

    With the new key the application indeed starts in landscape mode. However once a ViewController's view is added to the main window, the application reverts back to portrait mode.

    This is probably due to the fact that ViewControllers have their own UIInterfaceOrientation property which is different then the UIInterfaceOrientation of the Application.

    Is there a workaround to prevent the view to revert back to portrait when using a ViewController ?
     

Share This Page