Consider the following setup:
- You have a simple application with a single
UINavigationController
subclass and a singleUIViewController
subclass in it. - The UINavigationController overrides
preferredStatusBarStyle()
method and returnsUIStatusBarStyle.LightContent
- The UIViewController overrides
prefersStatusBarHidden()
method and returnstrue
In iOS 8.0 - 8.2 when another UINavigationController
(with another UIViewController that does not override anything) is presented with the modalPresentationStyle
set to UIModalPresentationStyle.OverCurrentContext
, the newly presented controller inherits the status bar appearance and visibility.
But in iOS 8.3 in the exact same situation - the newly presented controller does not inherits the status bar appearance and visibility
Another example would be to present an instance of UIImagePickerController
- the exact same thing happens regarding the status bar appearance.
The questions are:
- Why in iOS 8.3 the newly presented controller does not inherit the status bar appearance?
- What has been changed (I was unable to find any meaningful reference in the iOS 8.2 to 8.3 API diff regarding this)?
- Is there any elegant solution to this, instead of overriding everywhere the appearance and visibility methods?