UIModalPresentationFormSheet在iPad上的横向模式 [英] UIModalPresentationFormSheet on iPad in landscape mode

查看:169
本文介绍了UIModalPresentationFormSheet在iPad上的横向模式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我从XIB创建了一个UIViewController视图,modalPresentationStyle设置为UIModalPresentationFormSheet,一切都在肖像模式下工作得很好。当我切换到横向时,视图被移动到左上角(它不是中心的,因为它应该是),大部分它被剪辑。

I created a UIViewController view from XIB with modalPresentationStyle set to UIModalPresentationFormSheet and everything works great in portrait mode. When I switch to landscape the view gets moved upperleft (it's not centered as it should be) and most part of it is clipped.

任何想法为什么这是发生和如何

Any ideas why this is happening and how to solve it?

感谢

推荐答案

好。结果表明,模态控制器和调用控制器的自动旋转功能设置为纵向。

I had this problem as well. Turned out, I had the autorotate function set to Portrait for both the modal controller and the calling controller.

这篇关于UIModalPresentationFormSheet在iPad上的横向模式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆