I’m looking for a way to perform an animation after the transition to a view is finished, but not using viewDidAppear: because I only want the animation to occur when a notification is posted by the previous view.
I know about UIView‘s animateWithDuration: delay: options: animations: completion: method, so I can set the delay to be the same as the view transition animation duration (that’s a lot of words ending in -tion…), but would like to know if there is a better way to do this.
Thanks in advance.
viewDidAppearis probably the best place to start the animation. This way you don’t have to worry about timing a delay because load times will vary between devices. To solve this problem you could simply place aBOOLcondition inviewDidAppearand set it up so that the animation only starts ifBOOL == YES.