tags:

views:

60

answers:

1

-(void) setOrientation { UIInterfaceOrientation toOrientation = self.interfaceOrientation; //toOrientation = [[UIDevice currentDevice] orientation];

if (toOrientation == UIInterfaceOrientationLandscapeLeft ||
    toOrientation == UIInterfaceOrientationLandscapeRight )
{


}else if(toOrientation == UIInterfaceOrientationPortrait
     || toOrientation  == UIInterfaceOrientationPortraitUpsideDown){


}

}

When i am going to move iPad in Landscape position from Portrait position, portrait condition is get executed. Due to this my screen is distorted.

A: 

If you're talking about the interface being automatically reorganized to fit the other orientation, you should set a new frame to all interface elements when the screen gets rotated.

Fernando Valente