Reputation: 107
I just recently started coding again after about four months. There were a few updates in between. When I went to work on my app I clicked on a link and noticed the new view was hovering over the last view and there was no status bar. Just wanted to know what is causing this to happen and how to fix? Thanks
self.performSegue(withIdentifier: "Recover=>SignIn", sender: self)
override func prepare(for segue: UIStoryboardSegue, sender: Any!) {
if(segue.identifier == "Recover=>Connection") {
let navController = segue.destination as! UINavigationController
_ = navController.topViewController as! Connection
}
}
Upvotes: 0
Views: 199
Reputation: 2864
iOS 13 changed the way view controllers are presented by default. If you are using something like
parentViewController.show(childViewController, sender: self)
In iOS 12 the child view controller used to be shown full screen. In iOS 13 it shows up hovering over its parent.
To make it show up full screen, you need to add one line above the show()
:
childViewController.modalPresentationStyle = .fullScreen
.
Upvotes: 1