Transitioning Between View Controllers

UIKit offers a simple way to animate view features when you move from one child view controller to another. You provide a source view controller, a destination, and a duration for the animated transition. You can specify the kind of transition in the options. Supported transitions include page curls, dissolves, and flips. This method creates a simple curl from one view controller to the next:

- (void)action:(id)sender {     [redController willMoveToParentViewController:nil];     [self addChildViewController:blueController];     [self transitionFromViewController:redController         toViewController:blueController         duration:1.0f         options:UIViewAnimationOptionLayoutSubviews ...

Get The Core iOS Developer’s Cookbook, Fifth Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.