以下のように info.plist を設定します。
- 初期インターフェースの向き: 横 (左ホーム ボタン)
- サポートされているインターフェイスの向き: 横 (ホーム ボタンの左) と横 (ホーム ボタンの右)
アプリを起動したとき、向きデバイスには横向きモードがありますが、ビューはこの向きに回転しません。
回転方向には以下の方法を使用しますが、ランドスケープモードでは初期ではありません(この場合、デバイスを回転させた後、結果が必要でした-ランドスケープモードで回転を表示)
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
// Return YES for supported orientations
return UIInterfaceOrientationIsLandscape(interfaceOrientation);
}