I was using
<key>UIStatusBarHidden</key>
<true/>
in info.plist file to hide status bar for ios. Also in my RootViewController.mm is
- (BOOL)prefersStatusBarHidden
{
return YES;
}
to fix hiding status bar on ios7. Everything worked fine untill I tried this code on ios13. At ios13 status bar does not hide anymore. Does anybody know how to hide status bar for ios13? I also tried to add
<key>UIViewControllerBasedStatusBarAppearance</key>
<false/>
in info.plist, but nothing seemed to work.
Finally, I found the reason for that. my project was missing launchscreen storyboard. Adding launchscreen storyboard Seeing black bars at the top and bottom of the iPhone X Simulator and hiding safe area https://forums.developer.apple.com/thread/89037 and setting launch screen file in general settings allowed to hide status bar.