Question

I just started custom UIViewController transitions using UIViewControllerAnimatedTransitioning. Everything went fine, but when I dismiss a view, the topography of the presenting view beneath (green) gets reset.

You can see it with Cover, and Push transitions. | Click for GIF |

enter image description here

If you listen Cover transition carefully, you can see my problem. As soon as I click for dismiss, the presenting (green) view get's transformed back to fullscreen, while it's alpha works as I expect (!). Stays on 0.5 and animate toward 1.0 as it should be. This is not the case with transform of frameproperties.

Same goes for Push transition, the presenting controller's view gets reset right after click. The modal view just fine.


I've put the project to GitHub, actually made some helper class to cut down boilerplate, but you'll get the point. See EPPZPartialCover for a transition implementation.

Was it helpful?

Solution

Because of animation option UIViewAnimationOptionBeginFromCurrentState. Removed that animation option, and transition works as expected.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top