View Controller loses landscape support if presented with custom presentation by another custom-presented view controller

Originator:an00na
Number:rdar://22401547 Date Originated:24-Aug-2015 10:53 AM
Status:Open Resolved:
Product:iOS SDK Product Version:9.0 beta 5
Classification:Serious Bug Reproducible:Always
 
Summary:
A and B are portrait-only VCs. C is all-orientation VC.

Case 1: If C is presented with custom presentation(shouldRemovePresentersView = true) on A directly, C can rotate to landscape correctly. But after dismissing C, A is in landscape even though it only supports portrait.

Case 2: If B is first presented with custom presentation(shouldRemovePresentersView = false) on A and C is then presented with custom presentation(shouldRemovePresentersView = true) on B, C can not rotate to landscape.

Steps to Reproduce:
1. Launch sample app.
2. Use button “Present C” to see Case 1.
2. Use button “Present B” to see Case 2.

Expected Results:
Case 1: after dismissing C in landscape, A should appear in portrait mode.
Case 2: C should support landscape mode.

Sample code:
http://cl.ly/1h2O382H1p1J

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!