Package | cv.events |
Class | public class PlayProgressEvent |
Inheritance | PlayProgressEvent ![]() |
PlayProgressEvent.PLAY_START
: dispatched when playback has begun.PlayProgressEvent.PLAY_PROGRESS
: dispatched constantly during playback.PlayProgressEvent.PLAY_COMPLETE
: dispatched when playback is complete.PlayProgressEvent.STATUS
: dispatched whenever status has changed.PlayProgressEvent.LOADING
: constant used to verify file is loading.PlayProgressEvent.LOADED
: constant used to verify file is loaded but hasn't played once yet.PlayProgressEvent.STARTED
: constant used to verify file has started playing atleast once.PlayProgressEvent.UNLOADED
: constant used to verify file is unlaoded.Property | Defined by | ||
---|---|---|---|
elapsed : Number
The reference to the elapsed time of the media playing.
| PlayProgressEvent | ||
percent : uint
The reference to the percentage of progress for the media playing.
| PlayProgressEvent | ||
remain : Number
The reference to the remaining time of the media playing.
| PlayProgressEvent | ||
total : Number
The reference to the total time of the media playing.
| PlayProgressEvent |
Method | Defined by | ||
---|---|---|---|
PlayProgressEvent(type:String, bubbles:Boolean = false, cancelable:Boolean = false, percent:uint = 0, elapsed:Number = 0, remain:Number = 0, total:Number = 0)
Creates a new PlayProgressEvent object with the specified parameters.
| PlayProgressEvent | ||
clone():Event
Creates a copy of the PlayProgressEvent object and sets the value of each parameter to match
the original.
| PlayProgressEvent | ||
toString():String
Returns a string that contains all the properties of the PlayProgressEvent object.
| PlayProgressEvent |
Constant | Defined by | ||
---|---|---|---|
LOADED : String = "loaded" [static]
| PlayProgressEvent | ||
LOADING : String = "loading" [static]
| PlayProgressEvent | ||
PLAY_COMPLETE : String = "playComplete" [static]
| PlayProgressEvent | ||
PLAY_PROGRESS : String = "playProgress" [static]
Defines the value of the
type property of an playProgress
event object. | PlayProgressEvent | ||
PLAY_START : String = "playStart" [static]
| PlayProgressEvent | ||
STARTED : String = "started" [static]
| PlayProgressEvent | ||
STATUS : String = "status" [static]
| PlayProgressEvent | ||
UNLOADED : String = "unloaded" [static]
| PlayProgressEvent |
elapsed | property |
public var elapsed:Number
The reference to the elapsed time of the media playing.
percent | property |
public var percent:uint
The reference to the percentage of progress for the media playing.
remain | property |
public var remain:Number
The reference to the remaining time of the media playing.
total | property |
public var total:Number
The reference to the total time of the media playing.
PlayProgressEvent | () | constructor |
public function PlayProgressEvent(type:String, bubbles:Boolean = false, cancelable:Boolean = false, percent:uint = 0, elapsed:Number = 0, remain:Number = 0, total:Number = 0)
Creates a new PlayProgressEvent object with the specified parameters.
Parameterstype:String — The event type; this value identifies the action that caused the event.
|
|
bubbles:Boolean (default = false ) — Indicates whether the event can bubble up the display list hierarchy.
|
|
cancelable:Boolean (default = false ) — Indicates whether the behavior associated with the event can be
prevented.
|
|
percent:uint (default = 0 ) — The play progress in terms of percent.
|
|
elapsed:Number (default = 0 ) — The time elapsed in terms of milliseconds.
|
|
remain:Number (default = 0 ) — The time remaining in terms of milliseconds.
|
|
total:Number (default = 0 ) — The total time in terms of milliseconds.
|
clone | () | method |
public override function clone():Event
Creates a copy of the PlayProgressEvent object and sets the value of each parameter to match the original.
ReturnsEvent — A new PlayProgressEvent object with parameter values that match those of the original.
|
toString | () | method |
public override function toString():String
Returns a string that contains all the properties of the PlayProgressEvent object. The string is in the following format:
[PlayProgressEvent type=value bubbles=value
cancelable=value percent=value elapsed=value remain=value total=value
]
String — A string representation of the PlayProgressEvent object.
|
LOADED | constant |
public static const LOADED:String = "loaded"
LOADING | constant |
public static const LOADING:String = "loading"
PLAY_COMPLETE | constant |
public static const PLAY_COMPLETE:String = "playComplete"
PLAY_PROGRESS | constant |
public static const PLAY_PROGRESS:String = "playProgress"
Defines the value of the type
property of an playProgress
event object.
This event has the following properties:
Property | Value |
---|---|
bubbles | false |
cancelable | false ; there is
no default behavior to cancel. |
percent | The percentage of progress for the media playing. |
elapsed | The elapsed time of the media playing. |
remain | The remaining time of the media playing. |
total | The total time of the media playing. |
currentTarget | The object that is actively processing the event object with an event listener. |
target | The object that dispatched the event. The target is
not always the object listening for the event. Use the currentTarget
property to access the object that is listening for the event. |
PLAY_START | constant |
public static const PLAY_START:String = "playStart"
STARTED | constant |
public static const STARTED:String = "started"
STATUS | constant |
public static const STATUS:String = "status"
UNLOADED | constant |
public static const UNLOADED:String = "unloaded"