Skip to content

Instantly share code, notes, and snippets.

@JeremyXue77
Created April 13, 2019 23:30
Show Gist options
  • Select an option

  • Save JeremyXue77/490975e55829310b9357d53f45514b36 to your computer and use it in GitHub Desktop.

Select an option

Save JeremyXue77/490975e55829310b9357d53f45514b36 to your computer and use it in GitHub Desktop.
enum GesturePasswordType: Int {
case setting = 0
case unlock = 1
}
@IBAction func changeType(_ sender: UISegmentedControl) {
guard let type = GesturePasswordType(rawValue: sender.selectedSegmentIndex) else { return }
gesturePasswordType = type
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment