Last active
October 17, 2019 12:05
-
-
Save samdods/b6d5da1a4577ee801a3bf8d54fa45af3 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
override func viewDidLoad() { | |
super.viewDidLoad() | |
isModalInPresentation = true | |
navigationController?.presentationController?.delegate = self | |
} | |
/// conforming to UIAdaptivePresentationControllerDelegate | |
func presentationControllerDidAttemptToDismiss(_ presentationController: UIPresentationController) { | |
let controller = UIAlertController(title: nil, message: nil, preferredStyle: .actionSheet) | |
// ... | |
present(controller, animated: true) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment