Search code examples
iosobjective-ciphonecocoa-touchuikit

How can I delay a method call for 1 second?


Is there an easy way delay a method call for 1 second?

I have a UIImageView that reacts on a touch event. When the touch is detected, some animations happen in the app. After one second, I want to call another method. In this case, I can't use the animationDidStop selector.


Solution

  • performSelector:withObject:afterDelay:
    

    Document Reference