I am using a swipe gesture recognizer to for an IBAction in my iPhone app. I have an image in the middle of the view, and when I swipe to the left, I want the image to move to the left a little bit and then bounce back to its original position, like it is being forced back with a rubber band. Can anyone help me with this? Thanks!
Share
I have used UIView animateWithDuration. I had to nest them in order to have the bouncing, and provided a start and end frame for each.
Here is some hideously ugly code, which may be the best way to do it, but I’m not sure: