开发者

iPad orientation Problem

-(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.


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.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜