interface org.aswing.util.Impulser
Implementors | ||||||
AbstractImpulser, Timer |
|
Declares API to fire one or more action events after a specified delay.
@author paling @author Igor Sadovskiy
Instance Fields
function addActionListener(listener:Dynamic ->Void?priority:Int, ?useWeakReference:Bool): Void
Adds an action listener to the Impulser
instance.
* @param listener the listener
* @param priority the priority
* @param useWeakReference Determines whether the reference to the listener is strong or weak.
* @see org.aswing.event.AWEvent#ACT
function getInitialDelay(): Int
Returns the Impulser
's initial delay.
@see #setInitialDelay() @see #setDelay()
Returns true
(the default)
if the Impulser
will send
an action event to its listeners multiple times.
@see #setRepeats()
function removeActionListener(listener:Dynamic ->Void): Void
Removes a action listener. @see org.aswing.event.AWEvent#ACT
listener | the listener to be removed. |
function setDelay(delay:Int): Void
Sets the Impulser
's delay between fired events.
@see #setInitialDelay()
delay | the delay |
function setInitialDelay(initialDelay:Int): Void
Sets the Impulser
's initial delay,
which by default is the same as the between-event delay.
This is used only for the first action event.
Subsequent events are spaced using the delay property.
@see #setDelay()
initialDelay | the delay
between the invocation of the |
function setRepeats(flag:Int): Void
If flag
is false
,
instructs the Impulser
to send only once
action event to its listeners after a start.
flag | specify |