views:

21

answers:

1

Hi All,

I'm currently trying to implement UIOrientation in my app and it works well so far for each individual ViewController.

However, if I... Load View 1 and set it to portrait. Then go to view 2. Then rotate the phone to landscape. Then go back to view 1.

The view in view 1 is still in portrait mode and falling off the bottom of the screen.

(i.e. a 320 by 420 frame on a 420 by 320 screen)

Is there away to rotate a view or manage this so that when I press a view it works out what orientation it should be in and sorts itself out?

Thanks for any help.

Oliver

A: 

Well, that was easy!

I set the UITabBarControllerDelegate and then set the protocol method called something like didSelectViewController.

In there I then run willRotateTo blah whatever and set the toOrientation to my device orientation.

Fogmeister