Quote Originally Posted by saman_artorious View Post
In other words, let's consider this, whenever a particular condition sets to TRUE, I need to start a timer for a specific amount of time and then it goes dim till the condition goes true again.
I don't understand what you mean. If you mean that you want it to fire once then make it a single shot timer by calling setSingleShot(true).

For this case, which one do yo think is better

-connect the timer, set interval, set singleshot to true. and.. in this case I think everytime I need to activate the timer I should call restart

the other case is to:
-connect the timer, setinterval, and set the timer to start and stop when it times out.
The first one.

is there any way to wait for some period of time before executing the next instructions then? imagine I don't want to call any slots in some cases, I only want to delay.
Call sleep().