2

有是一名的UINavigationControllerRootViewController的(根)和secondViewController(作爲一個孩子)。該RootViewController的應該能夠旋轉到任何方位(如預期那樣的作品,我只是覆蓋shouldAutorotateToInterfaceOrientation),但secondViewController應在肖像模式下工作只(在這裏,我的shouldAutorotateToInterfaceOrientation設置爲自轉中的UINavigationController

interfaceOrientation == UIInterfaceOrientationPortrait 

問題:從RootViewController的導航到secondViewController而在後l和風景,secondViewController不會將其用戶界面切換回肖像。有沒有正確的方法來做到這一點?

回答

1

嘗試把一個

[super willRotateToInterfaceOrientation:toInterfaceOrientation duration:duration]; 

你的宣言後出現。看看是否有效。

相關問題