UIPageViewController uses orientation; does not work with iPad multitasking

Originator:douglashill
Number:rdar://23274100 Date Originated:27-Oct-2015 11:33 AM
Status:Open Resolved:
Product:iOS SDK Product Version:
Classification: Reproducible:
 
Summary:
UIPageViewController makes extensive use of device orientation, which is not a good idea now we have multitasking on iPad. Apps should be more adaptive.

As far as I can see, the only way to change the spine location of page view controller is using the delegate method pageViewController:spineLocationForInterfaceOrientation:, and this is only called when the device rotates, not when changing size due to entering or leaving Split View. It also only provides an orientation, but a size is needed to make a sensible, adaptive decision.

Attached is a screen shot of Xcode’s Page-Based Application template, using two page because it is in landscape.

Steps to Reproduce:
1. Create a new project in Xcode and use the Page-Based Application template.
2. Run the app on iPad Air 2.
3. Experiment with combinations of device orientations, Split View and Slide Over.

Expected Results:
The word ‘orientation’ should not appear in the UIPageViewController API.

UIPageViewController’s delegate should have the chance to make modifications for all size changes. (It would help if spineLocation was a writable property, then we could just use viewWillTransitionToSize.)

Xcode’s Page-Based Application template should not use orientation and userInterfaceIdiom checks, and instead decide to use two pages if the size available is sufficiently large and wide.

Actual Results:
I can find no way to update a UIPageViewController’s spineLocation in response to entering and leaving Split View. I’ll keep looking for a workaround.

Version:
iOS 9, Xcode 7.1 (7B91b)

Notes:


Configuration:
iPad Air 2 simulator

Attachments:
'landscape.png' was successfully uploaded.

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!