siva
siva

Reputation: 251

need of two xibs for my portrait and landscape modes

i am very new to xcode. i have an app which supports both for iphone and ipad.presently my app supports portrait orientation, now i want to support it for landscape also.

As i goggled it and got an idea that we have to maintain two views for that.is this is the only way to do that? can't i maintain with singleview for landscape and portrait ?

if this is only the way provide me a good tutorial to do this because i have lots of views.

Note: my app should support in ios 4,5,6 also

thankyou

Upvotes: 0

Views: 82

Answers (1)

IronManGill
IronManGill

Reputation: 7226

The answer is NO . You need not use 2 Xib's. Please go through the following links :-

Easiest way to support multiple orientations? How do I load a custom NIB when the application is in Landscape?

Different Xib's for Potrait and Landscape mode for iPad

http://www.theappcodeblog.com/2011/03/30/orientation-change-tutorial-change-the-view-when-the-orientation-changes/

Also ios 6 offers new methods like shouldAutoRotate etc. You might want to go through them too.

Upvotes: 1

Related Questions