NSTimer freezes the app until it gets fired again?
Posted
by itai alter
on Stack Overflow
See other posts from Stack Overflow
or by itai alter
Published on 2010-04-13T10:00:55Z
Indexed on
2010/04/13
10:02 UTC
Read the original article
Hit count: 333
iphone-sdk
|nstimer
Hello all, I have a simple app with a button, UIImageView and a NSTimer. The timer is fired up every 5 seconds repeatedly to update the ImageView with a new image, while the button simply stops the timer and switches to another View.
The problem is that when I press the button, nothing happens for a few seconds (until the timer fires up again).
Is there a way to cause the button to stop the timer and do its job at any given time instead of between intervals of the timer?
Thanks!
© Stack Overflow or respective owner