1
A
回答
2
我想你想要的是:shouldAutoRotateToInterfaceOrientation方法UIViewController
類。如果UIView
支持方向,則此函數返回YES
。如果您只有return YES
到landscape orientation
,那麼iPhone將自動進入該方向。
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
// Return YES for supported orientations
return (interfaceOrientation == UIInterfaceOrientationLandscape);
}
好運!
0
也許你正在尋找UIViewController shouldAutorotateToInterfaceOrientation
或其他一些方向相關的成員。
相關問題
- 1. 從肖像視圖控制器呈現一個模態景觀視圖控制器
- 2. iOS 6 - 導航控制器一些視圖的景觀旋轉而其他人只有肖像
- 3. 景觀和肖像的不同視圖
- 4. 肖像視頻景觀
- 5. 強制視圖控制器只肖像
- 6. 不同背景圖像的景觀和肖像視圖
- 7. cocos2d風景遊戲目前的肖像視圖控制器
- 8. iPhone視圖控制器風景/肖像旋轉問題
- 9. 風景和肖像方向只在一個視圖控制器中
- 10. iOS強制景觀在一個視圖控制器
- 11. Android的肖像VS景觀
- 12. 如何在導航控制器中的景觀模式下推視圖控制器,而其他人在iPhone中的肖像ios 8
- 13. iPad風景+肖像視圖
- 14. 如何強制一個視圖控制器顯示在橫向和其他總是停留在肖像
- 15. 一個根視圖控制器,管理所有其他視圖?
- 16. 製作一個特定的類視圖控制器自動在標籤欄的應用旋轉,但強迫所有其他類視圖控制器留肖像
- 17. UIView在景觀和肖像
- 18. 肖像和景觀建議
- 19. 從其他視圖控制器刷新視圖控制器
- 20. 在肖像中顯示景觀中的一個視圖應用程序
- 21. 當我將肖像更改爲景觀時,如何獲得景觀視圖?
- 22. 如何在其他視圖控制器上覆制導航控制器圖像
- 23. Swift使用視圖從其他控制器作爲一個uitableview的背景
- 24. @media查詢設備 - 如何肖像一個CSS,風景其他?
- 25. iPhone:一些視圖其他景觀風景
- 26. 當我從一個視圖控制器移動到其他視圖控制器與導航控制器
- 27. 使用視圖控制器管理兩個其他視圖控制器
- 28. 如何初始化其他視圖控制器場景?
- 29. 如何從其他視圖控制器
- 30. viewController在其他視圖控制器
您總是歡迎您! – Bhavin