Mixonomer-iOS/Music Tools/Controller/LoginController.swift

51 lines
1.2 KiB
Swift
Raw Normal View History

//
// LoginController.swift
// Music Tools
//
// Created by Ellie McCarthy on 19/02/2020.
// Copyright © 2020 Sarsoo. All rights reserved.
//
import UIKit
class LoginController: UIViewController, UITextFieldDelegate {
// MARK: Properties
@IBOutlet weak var usernameField: UITextField!
@IBOutlet weak var passwordField: UITextField!
@IBOutlet weak var goButton: UIButton!
override func viewDidLoad() {
super.viewDidLoad()
// Do any additional setup after loading the view.
}
// MARK: Actions
@IBAction func login(_ sender: UIButton) {
debugPrint(usernameField?.text)
}
// MARK: UITextFieldDelegate
func textFieldShouldReturn(_ textField: UITextField) -> Bool {
textField.resignFirstResponder()
return true
}
/*
// MARK: - Navigation
// In a storyboard-based application, you will often want to do a little preparation before navigation
override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
// Get the new view controller using segue.destination.
// Pass the selected object to the new view controller.
}
*/
}