I’m using this code [[UIApplication sharedApplication] setStatusBarHidden:YES]; in viewDidLoad and nothing else, to hide the status bar in my modal view. But when I come back to the previous view with [self dismissViewControllerAnimated:YES completion:nil]; the status bar is hidden in all the views. Of course I don’t want this behavior. I understand that this is a simple question and might be a possible duplicate.
Anyway, thanks in advance!
I’m using this code [[UIApplication sharedApplication] setStatusBarHidden:YES]; in viewDidLoad and nothing else, to hide
Share
Remember that
sharedApplication(singleton) is your application, so you just told your app to hide the status bar. If you want it to show somewhere else, you need tosetStatusBarHidden:NOthere. Hope this helps.