【发布时间】:2012-03-14 06:19:05
【问题描述】:
在我的应用程序中,我在拆分视图的 RootViewController 中添加了 tabBarController。在该纵向模式下工作正常,但它的方向不会更改为横向模式。当我在 rootViewController 中添加 tabBarController 时,横向方向不会改变。
请建议我这样做的方法。
【问题讨论】:
标签: objective-c xcode4.2 ipad
在我的应用程序中,我在拆分视图的 RootViewController 中添加了 tabBarController。在该纵向模式下工作正常,但它的方向不会更改为横向模式。当我在 rootViewController 中添加 tabBarController 时,横向方向不会改变。
请建议我这样做的方法。
【问题讨论】:
标签: objective-c xcode4.2 ipad
确保标签栏控制器中包含的所有视图控制器都可以在所有方向上显示。有关详细信息,请参阅技术问答 QA1688。 https://developer.apple.com/library/ios/#qa/qa1688/_index.html
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
return YES;
}
【讨论】: