AdvancedTween
| Kind of class: | public interface |
|---|---|
| Package: | com.bourre.transitions |
| Inherits from: | Tween < Suspendable |
| Implemented by: | |
| Author: | Francis Bourre, Cédric Néhémie |
| Classpath: | com.bourre.transitions.AdvancedTween |
| File last modified: | Monday, 24 November 2008, 11:36:57 |
The
add the support for event dispatching.
AdvancedTween interface extends Tween andadd the support for event dispatching.
The tween object invokes the TweenEvent.onMotionChangedEVENTevent on a regular interval on the effect instance for the duration of
the tween, passing to the onMotionChanged method the interpolated
value between the start value and the end value. Typically, the callback function
updates some property of the target object, causing that object to animate
over the duration of the effect.
When the effect ends, the tween objects invokes TweenEvent.onMotionFinishedEVENTevent on its listeners, if you defined one.
Take a look at MultiTweenFPS,
MultiTweenMS, TweenFPS
and TweenMS for concret implementations.
See also:
Summary
Instance methods
- addListener (listener:TweenListener) : Boolean
- Adds the passed-in listener object as listener for
- removeListener (listener:TweenListener) : Boolean
- Removes the passed-in listener from listening all events
- addEventListener (type:String, listener:Object, rest) : Boolean
- Adds the passed-in listener as listener for the passed-in event type.
- removeEventListener (type:String, listener:Object) : Boolean
- Removes the passed-in listener for listening the passed-in event type.
Instance methods
addEventListener
public function addEventListener (
type:String,
listener:Object,
rest) : Boolean
Adds the passed-in listener as listener for the passed-in event type.
Parameters:
type :
name of the event type.
listener:
object to be added as listener.
Returns:
-
trueif the object have been succesfully added as
listener for the passed-in event type
See also:
- See the
EventBroadcaster.addEventListener() documentation for a complete
description of the behavior of that method
addListener
Adds the passed-in listener object as listener for
all events dispatched by the tween. The object must
implements the
all events dispatched by the tween. The object must
implements the
TweenListener interface. Parameters:
listener:
object to be added as listener.
Returns:
-
trueif the object have been succesfully
added as listener for this object
See also:
- See the
EventBroadcaster.addListener() documentation for a complete
description of the behavior of that method
removeEventListener
public function removeEventListener (
type:String,
listener:Object) : Boolean
Removes the passed-in listener for listening the passed-in event type.
Parameters:
type :
name of the event type.
listener:
object to be removed as listener.
Returns:
-
trueif the object have been succesfully remove as
listener for the passed-in event type
See also:
- See the
EventBroadcaster.removeEventListener() documentation for a complete
description of the behavior of that method
removeListener
Removes the passed-in listener from listening all events
dispatched by this tween.
dispatched by this tween.
Parameters:
listener:
object to be removed as listener.
Returns:
-
trueif the object have been succesfully removed
as listener for this object
See also:
- See the
EventBroadcaster.removeListener() documentation for a complete
description of the behavior of that method