Learn how to create simple View Controller transition animations.
This is a companion discussion topic for the original entry at https://www.raywenderlich.com/3422-beginning-ios-animation/lessons/9
Learn how to create simple View Controller transition animations.
Hi Marin, nice video, this help me a lot to learn iOS animation, I have 2 questions:
Should you have started your second animation in the completion block of the first one instead starting it with a delay that match the duration of the first one ?
In the challenge, we add a dimming view to the animateTransition, should it have be done in a UIPresentationController in a separate class instead ?
Quick Tips: Instead of forcing the unwrap of the optionals at the top of animateTransition you could have used guard
thanks
We get ‘extra argument ‘usingSpringWithDamping’ in call’.
Hi Marin,
Nice videos. I am a bit struggling to fix a bug that I found with animating the view controllers. Here is the scenario,
I open the app in any orientation, click on one of the images, rotate the device, click again on the image to dismiss the HerbDetailsViewController. the result is that the main view controller layout still thinks that it is the old orientation and it doesn’t update itself to correspond to the new orientation. Any help explaining that is appreciated.
Thanks
Hey yeah, that’s part of UIKit’s policies. The presented view controllers don’t propagade orientation changes to their presenters.
this happens only when I do custom animations but if I go with the default animations, the presenting viewcontroller corresponds to orientation changes. I was wondering how should I go about fixing that.
Thanks