Advertisement
Guest User

Untitled

a guest
Mar 22nd, 2017
63
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Swift 0.79 KB | None | 0 0
  1. protocol RegistrationFormViewControllerDelegate: class {
  2.     func saveDataButtonTapped()
  3. }
  4. weak var myAccountDelegate: RegistrationFormViewControllerDelegate?
  5. @IBAction func saveButtonTapped(_ sender: UIBarButtonItem) {
  6.         myAccountDelegate?.saveDataButtonTapped()
  7.         print("b")
  8.     }
  9.    
  10.    
  11.    
  12.     let storyboard = UIStoryboard(name: GlobalConsts.registrationFormsStoryboardName, bundle: Bundle.main)
  13.         if let rootVC = storyboard.instantiateViewController(withIdentifier: "RegistrationFormRootViewController") as? RegistrationFormRootViewController {
  14.             rootVC.myAccountDelegate = self
  15.         }
  16.        
  17.         extension PaymentRegistrationFormViewController: RegistrationFormViewControllerDelegate {
  18.     func saveDataButtonTapped() {
  19.         print("a")
  20.     }
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement