Check if status bar is hidden:
Objective C:
if ([UIApplication sharedApplication].isStatusBarHidden) {
// do stuff here...
}
Swift:
if UIApplication.shared.isStatusBarHidden {
// do stuff here...
}
Hide status bar:
override var prefersStatusBarHidden: Bool {
return true
}