问题
I have my app setup and everything works great until I call my image picker and my mail controller. On each of those views the UIStatusBar changes to black even though I have
[[UIApplication sharedApplication] setStatusBarStyle:UIStatusBarStyleLightContent];
and View controller-based status bar appearance set to YES.
Any idea how to control the light color of these modal views? See the images - the first one is the entire app, working great. The second is the image picker after the image library is shown and the third is the mail composer.
Any help would be highly appreciated!
回答1:
I think you need to put this on the view controller presenting the modal controller
- (UIStatusBarStyle) preferredStatusBarStyle {
return UIStatusBarStyleLightContent;
}
来源:https://stackoverflow.com/questions/20895906/ios7-status-bar-changing-back-to-black-on-modal-views