class org.aswing.util.AbstractImpulser extends EventDispatcher
Sub classes | ||||
Timer |
|
Provides common routines for classes implemented
Impulse
interface.
@author paling @author Igor Sadovskiy
Instance Fields
Show inherited public instance fields | Hide inherited public instance fields
|
function addActionListener(listener:Dynamic ->Void?priority:Int = 0, ?useWeakReference:Bool = false): Void
Adds an action listener to the AbstractImpulser
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 AbstractImpulser
's initial delay.
@see #setInitialDelay() @see #setDelay()
Returns true
(the default)
if the AbstractImpulser
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 AbstractImpulser
's delay between
fired events.
@see #setInitialDelay()
delay | the delay |
function setInitialDelay(initialDelay:Int): Void
Sets the AbstractImpulser
'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 AbstractImpulser
to send only once
action event to its listeners after a start.
flag | specify |