Advertisement
iamalizade

WVC

Mar 3rd, 2016
190
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Swift 1.06 KB | None | 0 0
  1. class WelcomeViewController: UIViewController, SegueDelegate {
  2.     @IBOutlet weak var signInButton: UIButton!
  3.     @IBOutlet weak var signUpButton: UIButton!
  4.     @IBOutlet weak var logoImageView: UIImageView!
  5.     @IBOutlet weak var descriptionLabel: UILabel!
  6.    
  7.     var screen = CGRect()
  8.     let signUpView = SignUpView.signUpView()
  9.     let signInView = SignInView.signInView()
  10.    
  11.     var a = SignUpView()
  12.    
  13.     override func viewDidLoad() {
  14.         super.viewDidLoad()        
  15.         a.segueDelegate = self
  16.     }
  17.  
  18.     @IBAction func signUpButtonClicked(sender: AnyObject) {
  19.         fallAnimation(self.signUpButton, secondButton: signInButton, xib: signUpView)
  20.     }
  21.    
  22.     func fallAnimation(firstButton: UIButton, secondButton: UIButton, xib: UIView) {
  23.         xib.frame.size.width = self.screen.width
  24.         xib.frame.size.height = self.screen.height
  25.  
  26.         self.view.addSubview(xib)    
  27.     }
  28.    
  29.     func runSegue(identifier: String) {
  30.         print("B")
  31.         self.performSegueWithIdentifier(identifier, sender: self)
  32.     }
  33. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement