相关疑难解决方法(0)

如何使应用程序在iOS 6中完全正常工作以进行自动旋转?

在iOS6中,shouldAutorotateToInterfaceOrientation已弃用.我尝试使用 supportedInterfaceOrientationsshouldAutorotate 使应用程序正常工作自动旋转但失败了.

这个ViewController我不想旋转,但它不起作用.

- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
    return (interfaceOrientation == UIInterfaceOrientationPortrait);
}

-(BOOL)shouldAutorotate
{
    return NO;
}

-(NSUInteger)supportedInterfaceOrientations
{
    return UIInterfaceOrientationMaskPortrait;
}
Run Code Online (Sandbox Code Playgroud)

有任何想法吗?在此先感谢您的帮助!

uiviewcontroller autorotate ios ios6

17
推荐指数
1
解决办法
2万
查看次数

标签 统计

autorotate ×1

ios ×1

ios6 ×1

uiviewcontroller ×1