私のアプリは、このように設定するビューコントローラの階層があります。回転ビューコントローラ - >タブバーコントローラ - >ナビゲーションコントローラ - >ビューコントローラ
UIViewController
|
UITabBarController
|
UINavigationController
| |
| UIViewController (*)
|
UINavigationController
|
UIViewController (*)
なぜ私のUIViewController(*)を(void)willAnimateRotationToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation duration:(NSTimeInterval)durationメソッド? (UIInterfaceOrientation)toInterfaceOrientation時間:(NSTimeInterval)デュレーション方法
UITabBarController
|
UINavigationController
| |
| UIViewController (*)
|
UINavigationController
|
UIViewController (*)
のUIViewController(*)(無効)willAnimateRotationToInterfaceOrientationを取得:私のアプリはこのように設定するビューコントローラの階層があり
。
"ルートUIViewControllerからUITabBarViewControllerにローテーションメッセージを転送する必要があります。 - これを行う方法? – rowwingman
ルート 'UIViewController'に' willRotateToInterfaceOrientation: '(および必要に応じて他のローテーションコールバック)をオーバーライドし、' [self.tabBarController willRotateToInterfaceOrientation:] 'を呼び出します。これは、あなたのルート 'UIViewController'が提示している' UITabBarController'への参照を保持していると仮定しています。 –