Reputation: 16598
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 |
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 frame
properties.
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.
Upvotes: 1
Views: 250
Reputation: 16598
Because of animation option UIViewAnimationOptionBeginFromCurrentState
.
Removed that animation option, and transition works as expected.
Upvotes: 2