Skip to content

Instantly share code, notes, and snippets.

@psaitu
Created July 5, 2016 12:38
Show Gist options
  • Select an option

  • Save psaitu/905228c50f1ff5ba5a1487f6dcffed16 to your computer and use it in GitHub Desktop.

Select an option

Save psaitu/905228c50f1ff5ba5a1487f6dcffed16 to your computer and use it in GitHub Desktop.
Code Snippets For Blog Post -
import UIKit
class PopUpViewController: UIViewController {
@IBOutlet weak var actionButton: UIButton!
override func viewDidLoad() {
super.viewDidLoad()
// Do any additional setup after loading the view.
self.actionButton.layer.cornerRadius = 4.0
self.view.layer.cornerRadius = 4.0
}
override func didReceiveMemoryWarning() {
super.didReceiveMemoryWarning()
// Dispose of any resources that can be recreated.
}
@IBAction func didPressActionButton(sender: AnyObject) {
dismissViewControllerAnimated(true) {
print("Dismissed")
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment