iphone xcode横向模式默认情况下

问题描述:

如何设置iPhone应用程序以横向模式启动?并保持这种状态

how can I set an iphone app to start in Landscape mode? and stays that way

将初始界面方向" app.plist条目设置为横向"(左或右主页按钮)并添加(或更可能取消注释和编辑)以下视图控制器方法:

Set the "Initial interface orientation" app.plist entry to "Landscape" (left or right home button) and add (or more likely, uncomment and edit) the following view controller method:

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