User Guide
530 Chapter 6: Components Dictionary
}
myMedia.addEventListener("playheadChange", listenerObject)
Description
Event; broadcast by the MediaController or MediaPlayback component when the user moves the
playback slider or clicks the Go to Beginning or Go to End button. The
Media.playheadChange
event object has the following properties:
detail A number that indicates the percentage of the media that has played.
type The string "playheadChange".
Example
The following example sends the percentage played to the Output panel when the user stops
dragging the playhead:
var controlListen = new Object();
controlListen.playheadChange = function(eventObject){
trace(eventObject.detail);
}
myMedia.addEventListener("playheadChange", controlListen);
Media.playheadTime
Applies to
MediaDisplay, MediaPlayback
Availability
Flash Player 7.
Edition
Flash MX Professional 2004.
Usage
myMedia.playheadTime
Description
Property; holds the current position of the playhead (in seconds) for the media Timeline that is
playing. The default value is the location of the playhead.
Example
The following example sets a variable to the location of the playhead, which is indicated in
seconds:
var myPlayhead = myMedia.playheadTime;