Skip to content

Instantly share code, notes, and snippets.

@jazzsasori
Created June 11, 2014 17:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jazzsasori/8681057d137507bb91aa to your computer and use it in GitHub Desktop.
Save jazzsasori/8681057d137507bb91aa to your computer and use it in GitHub Desktop.
import UIKit
class ViewController: UIViewController {
@IBOutlet var button:UIButton
@IBAction func buttonTapped(sender:AnyObject) {
var tappedButton:UIButton = sender as UIButton
tappedButton.setTitle("tapped", forState:UIControlState.Normal)
}
override func viewDidLoad() {
super.viewDidLoad()
button.setTitle("tap me", forState:UIControlState.Normal)
}
override func didReceiveMemoryWarning() {
super.didReceiveMemoryWarning()
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment