1

我的第一个 UIViewcontroller

-(NSInteger) supportedInterfaceOrientations
{ return UIInterfaceOrientationMaskLandscape; }
-(BOOL) shouldAutorotate
{ return YES; }

and through present modally segue..

还有我的第二个 UIViewController

-(NSInteger) supportedInterfaceOrientations
{ return UIInterfaceOrientationMaskPortrait; }
-(BOOL) shouldAutorotate
{ return YES; }

但。我的第二个 UIviewcontroller 出错 SigAbrt !!!

错误信息

Terminating app due to uncaught exception 'NSInvalidArgumentException', reason : [__NSPlaceholderArray initWithObjects:count:] attempt to insert nil object from object[0]

但是如果我删除第二个 UIViewController 代码“supportedInterfaceOrientations”这个应用程序运行良好......

我如何旋转一些视图是纵向的,而另一个视图是横向的...

我的故事板制作 w:any/h:any 和模拟指标:推断方向

在此处输入图像描述 在此处输入图像描述 在此处输入图像描述 在此处输入图像描述

4

0 回答 0