自从我转到 iOS 7.1 后,我不断收到每个自定义转换的警告消息。如何摆脱这个:
“UIModalPresentationCustom演示文稿样式只能用于 动画师或无人解雇。“
答案 0 :(得分:4)
我有同样的问题。我不得不在呈现控制器中保留转换代表,因为当我从提交的控制器中解雇时它是零。
@property (strong, nonatomic) YourTransitioningDelegate *transitioningDelegate;
@synthesize transitioningDelegate;
transitioningDelegate = [[YourTransitioningDelegate alloc] init];
UIViewController *presentingController = [[UIViewController alloc] init];
presentingController.transitioningDelegate = transitioningDelegate;
[self presentViewController:presentingController];
答案 1 :(得分:1)
我有同样的警告,但我所做的是从 UIViewControllerTransitioningDelegate 协议实现animationControllerForDismissedController。
- (id<UIViewControllerAnimatedTransitioning>)animationControllerForDismissedController;