开发者

iPhone/iPad landscape orientation and UIAlertView

开发者 https://www.devze.com 2023-02-14 19:13 出处:网络
I am using Sparrow framework, and also I am forcing my app to be only in landscape orientation. I have a button in my app, clicking on which opens UIAlertView. However, if I rotate (change orientation

I am using Sparrow framework, and also I am forcing my app to be only in landscape orientation. I have a button in my app, clicking on which opens UIAlertView. However, if I rotate (change orientation from say landscape right to landscape left (meaning that home button is either on the right or left)) and click on the 开发者_运维百科button to open UIAlertView -- it opens it but upside down! How do I fix it?


Fixed with

[[UIApplication sharedApplication] setStatusBarOrientation: [UIDevice currentDevice].orientation animated: NO ]; 

in

-(void)orientationDetected:(UIEvent *)event
0

精彩评论

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