【发布时间】:2012-03-10 15:20:30
【问题描述】:
是否可以创建 2 个故事板并根据设备方向访问每个故事板?我试过这段代码:
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
return YES;
if (UIInterfaceOrientationPortrait){
UIStoryboard *controller = [self.storyboard instantiateViewControllerWithIdentifier:@"Storyboardland.storyboard"];
}else if (UIInterfaceOrientationPortraitUpsideDown){
UIStoryboard *controller = [self.storyboard instantiateViewControllerWithIdentifier:@"MainStoryboard_iPad.storyboard"];
}}
...但是不起作用??我犯了什么错误??
【问题讨论】:
标签: ios xcode storyboard uistoryboard