Created
August 22, 2019 14:01
-
-
Save sagaya/fbb50eab93fdf4dfe2ed282f9da1ab3b to your computer and use it in GitHub Desktop.
This file contains 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
import UIKit | |
class FirstViewController: UIViewController { | |
let transitionDelegate: UIViewControllerTransitioningDelegate = TransitionAnimation() | |
override func viewDidLoad() { | |
super.viewDidLoad() | |
// Do any additional setup after loading the view. | |
} | |
@IBAction func didTapPush(_ sender: Any) { | |
let storyboard = UIStoryboard(name: "Main", bundle: nil) | |
if let controller = storyboard.instantiateViewController(withIdentifier: "secondController") as? SecondViewController{ | |
transitioningDelegate = self.transitionDelegate | |
controller.transitioningDelegate = self.transitionDelegate | |
present(controller, animated: true, completion: nil) | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment