Advertisement
Guest User

Untitled

a guest
Jun 24th, 2019
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.54 KB | None | 0 0
  1. @IBAction func Register(_ sender: Any) {
  2. print("successfully tapped")
  3. }
  4.  
  5. @IBAction func switchViews(_ sender: UISegmentedControl) {
  6. if sender.selectedSegmentIndex == 0 {
  7. firstView.alpha = 1
  8. secondView.alpha = 0
  9. thirdView.alpha = 0
  10. } else if sender.selectedSegmentIndex == 1 {
  11. firstView.alpha = 0
  12. secondView.alpha = 1
  13. thirdView.alpha = 0
  14. } else if sender.selectedSegmentIndex == 2 {
  15. firstView.alpha = 0
  16. secondView.alpha = 0
  17. thirdView.alpha = 1
  18. }
  19. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement