iPhone横向模式问题

时间:2012-04-08 19:23:17

标签: ios orientation

我将info.plist设置如下:

  • 初始界面方向:横向(左主页按钮)
  • 支持的界面方向:横向(左主页按钮)和横向(右主页按钮)

当我启动我的应用时,定位设备具有横向模式,但我的视图不会旋转到此定向。

我使用下面的方法进行旋转方向,但在横向模式下查看不是最初的(在我旋转设备之后,我需要结果 - 以横向模式旋转视图)

- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
    // Return YES for supported orientations
    return UIInterfaceOrientationIsLandscape(interfaceOrientation);
}

1 个答案:

答案 0 :(得分:1)

我过去曾遇到过一些问题。基本上,如果您只是将初始视图控制器放在那里,就会将处理错误视为处于纵向模式。我找到的修复程序是将视图控制器添加到导航控制器。

See this question i posted for the full explanation

相关问题