因此,如果你创建一个带有'MasterView'和'DetailView'设置的UISplitViewController
在iPhone 6 Plus的纵向“MasterView”中按下项目按钮按下/显示“MasterView2”然后旋转设备我希望看到这个 - “MasterView2”| '的DetailView'
但我获得'MasterView'| 'MasterView2'
这应该如何设置,以便在旋转iPhone 6 Plus时获得预期的'MasterView2'| '的DetailView'?
答案 0 :(得分:2)
对于感兴趣的人来说,我是如何使用splitviewcontroller委托解决问题的
- (BOOL)splitViewController:(UISplitViewController *)splitViewController
collapseSecondaryViewController:(UIViewController *)secondaryViewController
ontoPrimaryViewController:(UIViewController *)primaryViewController{
return YES;
}
- (UIViewController *)splitViewController:(UISplitViewController *)splitViewController
separateSecondaryViewControllerFromPrimaryViewController:(UIViewController *)primaryViewController{
UIStoryboard *storyboard = [UIStoryboard storyboardWithName:@"Main" bundle:nil];
return [storyboard instantiateViewControllerWithIdentifier:@"detailView"];
}