Swift: Long Press Gesture Recognizer – Detect taps and Long Press
Define two IBActions and set one Gesture Recognizer to each of them. This way you can perform two different actions for each gesture. You can set each Gesture Recognizer to different IBActions in the interface builder. @IBAction func tapped(sender: UITapGestureRecognizer) { println(“tapped”) //Your animation code. } @IBAction func longPressed(sender: UILongPressGestureRecognizer) { println(“longpressed”) //Different code } … Read more