2012-03-05 32 views

回答

0

也許你會嘗試類似編寫你自己的UIViewController子類的東西,它只會實現你的自定義視圖在界面取向變化上的出現。像這樣的:

- (void)didRotateFromInterfaceOrientation:(UIInterfaceOrientation)fromInterfaceOrientation{ 
    DetailViewController *dvc = [[DetailViewController alloc] initWithNibName:@"DetailViewController_iPhone" bundle:[NSBundle mainBundle]]; 
    } 
    //navigation controller ruft den bdv Controller auf 
    [self.navigationController pushViewController:dvc animated:YES]; 
    [dvc release]; 

} 

所有其他類現在繼承自此自定義UIViewController。 當然這只是一個解決方案,如果你有所有的視圖ViewControllers。

希望它有幫助

相關問題