Search code examples
ios5ios6

Different Initial interface orientation iPhone and iPad universal application


What I want is Portrait orientation for iPhone and Landscape orientation for iPad app. My app is targeted for >
I searched on web about this but got different answers but not the exact one.


Solution

  • So here is what I did

    For iPhone enter image description here

    and for iPad enter image description here

    And for iPad controllers I added below code, this is not necessary for applications

    - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
    {
        return (interfaceOrientation == UIInterfaceOrientationLandscapeRight ||
                interfaceOrientation == UIInterfaceOrientationLandscapeLeft);
    }