xcode4.5.1のマスター/詳細テンプレートを使用してユニバーサルアプリを作成しています。iPadで横向きを保つために、私は以下の設定をしています。iOS6で動作しますが、iOS5では常に縦向きを保ちます。どうすれば問題を解決できますか?(プロジェクトのリンク:https ://www.dropbox.com/s/7wm9l8kxhan6kp1/itstest.zip )</ p>
plist
<key>UISupportedInterfaceOrientations~ipad</key> <array> <string>UIInterfaceOrientationLandscapeLeft</string> <string>UIInterfaceOrientationLandscapeRight</string> </array> <key>UISupportedInterfaceOrientations~iphone</key> <array> <string>UIInterfaceOrientationPortrait</string> <string>UIInterfaceOrientationPortraitUpsideDown</string> </array>
Appdelegate.mに以下を追加することもできます
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation { return UIInterfaceOrientationIsLandscape(interfaceOrientation); }
ありがとう!