【问题标题】:2nd (landscape) screen of application turns portrait in iOS6应用程序的第二个(横向)屏幕在 iOS6 中变成纵向
【发布时间】:2013-05-16 15:08:04
【问题描述】:

我正在开发一个横向模式的 iPad 应用程序,该应用程序仅在 iOS5 及以下版本下运行良好。 在 iOS6 上,第二个屏幕(登录屏幕)突然变成纵向模式。 我应该检查哪些参数?

【问题讨论】:

    标签: ipad ios6 landscape regression uiinterfaceorientation


    【解决方案1】:

    检查以下方法。

    //ios6以上需要

    - (BOOL)shouldAutorotate
    {
    
    return NO; // YES or NO as per your requirement
    }
    
    - (BOOL)supportedInterfaceOrientations
    {
    return UIInterfaceOrientationLandscapeRight|UIInterfaceOrientationLandscapeLeft;
    }
    

    【讨论】:

    • 感谢@ParthDubai,我解决了在 AppDelegate 中添加[window setRootViewController:viewController]; 的问题
    猜你喜欢
    • 2020-08-10
    • 1970-01-01
    • 1970-01-01
    • 2015-04-21
    • 2015-12-30
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多