My application has a multi-level textbook style view that users browse to find out about the application. This is implemented as described in this lesson . Having implemented it for both iOS 7 and 8, I compare how they work and find problems with the latter - here I run Xcode 6 GM.
It seems that the UIPageViewController passes the views after the transition is complete. I tried the delegate methods to find out what was going on:
- (void)pageViewController:(UIPageViewController *)pageViewController willTransitionToViewControllers:(NSArray *)pendingViewControllers { NSLog(@"Frame size before: %@", NSStringFromCGRect([(UIViewController*)pendingViewControllers[0] view].frame)); } - (void)pageViewController:(UIPageViewController *)pageViewController didFinishAnimating:(BOOL)finished previousViewControllers:(NSArray *)previousViewControllers transitionCompleted:(BOOL)completed { NSLog(@"Frame size after: %@", NSStringFromCGRect([(UIViewController*)previousViewControllers[0] view].frame)); }
And here is an example output:
Frame size before: {{0, 0}, {600, 600}} Frame size after: {{0, 0}, {320, 568}}
This manifests itself as follows: swipe the screen to the left to pull out the next view, and pay attention to the 32-pt-white space at the bottom of the new view. Once the transition is complete, it breaks into the correct layout.
Perhaps this is a bug in iOS 8? At the moment, Iβm all guessing.
autolayout ios8 xcode6 uipageviewcontroller
Aaron Vegh Sep 11 '14 at 15:14 2014-09-11 15:14
source share