Closed aaizuss closed 8 years ago
Check in the Storyboard how the Segue "Kind" is set. You can toggle between modal and push here.
@tabinks I already tried that but I didn't actually use a segue... I just used a Bar Button Item action so that option isn't available.
I'll see if I can figure out how to make the button a segue instead of an action. The only way I know how to make a segue right now is ctrl + dragging from one view controller to another, but I don't actually have a view controller in storyboard for the safari view controller (I just have the DetailViewController).
I can't seem to not have it present as modal. If you haven't resolved it, we can review it tomorrow.
Before calling
self.presentViewController(safariViewController, animated: true, completion: nil)
add this line:
safariViewController.modalPresentationStyle = UIModalPresentationStyle.Popover
@prazgaitis That fixed it! Thank you!
I implemented
SFSafariViewController
, but the view controller opens with a sliding (push?) animation (the kind of animation used when transitioning between a table view cell and the detail page, for example) instead of modally. The tutorials I've looked at and the Apple Developer video show a modal transition as the default, so I don't understand why mine isn't. I've read through this documentation and tried to manually change the animation style usingsvc.modalPresentationStyle
(svn is what I called the view controller), but I haven't gotten that to work...