2016-02-11 39 views
0

我知道這是你如何設置模式的故事板賽格瑞或presentViewController:animated:completion動畫:如何設置自定義解僱動畫的UIViewController

- (id<UIViewControllerAnimatedTransitioning>)animationControllerForPresentedController:(UIViewController *)presented presentingController:(UIViewController *)presenting sourceController:(UIViewController *)source { 
    return [[BounceAnimationController alloc] init]; 
} 

但你如何設置一個解僱視圖控制器?

+1

的可能的複製[UIViewController中 - 自定義問題解僱過渡(http://stackoverflow.com/questions/ 24085867/UIViewController中發出與 - 定製解僱過渡) –

回答

0

我去看看UIViewControllerTransitioningDelegate代碼並發現了這個方法做的:

- (id<UIViewControllerAnimatedTransitioning>)animationControllerForDismissedController:(UIViewController *)dismissed { 
    return [[MyAnimationController alloc] init]; 
} 
相關問題