【发布时间】:2015-12-29 19:03:08
【问题描述】:
我需要做一个自定义演示动画,当我同时设置这两个 setTransitioningDelegate 和 modalPresentationStyle=UIModalPresentationCustom
除非在呈现的视图控制器中没有调用 viewDidAppear 和 viewDidDisappear,否则动画是完美的。这与 https://developer.apple.com/library/ios/samplecode/LookInside/Introduction/Intro.html 中的 Apple 示例代码相同
[overlay setTransitioningDelegate:[self transitioningDelegate]];
overlay.modalPresentationStyle=UIModalPresentationCustom;
[self presentViewController:overlay animated:YES completion:NULL];
为什么在没有给出 modalPresentationStyle 时调用方法?
【问题讨论】:
标签: ios uiviewcontroller presentviewcontroller uimodalpresentationstyle