The
event handler in the following example calls the
ready
the cue point
ASpt1
navigation cue point that is nearest to the time of cue point
import mx.video.*;
my_FLVPlybk.contentPath = "http://www.helpexamples.com/flash/video/
cuepoints.flv"
var rtn_obj:Object = new Object(); //create cue point object
my_FLVPlybk.addASCuePoint(2.02, "ASpt1");
var listenerObject:Object = new Object();
listenerObject.ready = function(eventObject:Object):Void {
rtn_obj = my_FLVPlybk.findCuePoint("ASpt1");
traceit(rtn_obj);
rtn_obj = my_FLVPlybk.findNearestCuePoint(rtn_obj.time,
FLVPlayback.NAVIGATION);
traceit(rtn_obj);
}
my_FLVPlybk.addEventListener("ready", listenerObject);
function traceit(cuePoint:Object):Void {
trace("Cue point name is: " + cuePoint.name);
trace("Cue point time is: " + cuePoint.time);
trace("Cue point type is: " + cuePoint.type);
}
In the following example, the
findNextCuePointWithName()
import mx.video.*;
my_FLVPlybk.contentPath = "http://www.helpexamples.com/flash/video/
cuepoints.flv"
var rtn_obj:Object = new Object(); //create cue point object
my_FLVPlybk.addASCuePoint(2.02, "ASpt");
my_FLVPlybk.addASCuePoint(3.4, "ASpt");
var listenerObject:Object = new Object();
listenerObject.ready = function(eventObject:Object):Void {
rtn_obj = my_FLVPlybk.findCuePoint("ASpt");
traceit(rtn_obj);
rtn_obj = my_FLVPlybk.findNextCuePointWithName(rtn_obj);
traceit(rtn_obj);
}
my_FLVPlybk.addEventListener("ready", listenerObject);
function traceit(cuePoint:Object):Void {
trace("Cue point name is: " + cuePoint.name);
trace("Cue point time is: " + cuePoint.time);
trace("Cue point type is: " + cuePoint.type);
}
For more information about finding cue points, see
on page
586,
FLVPlayback.findNearestCuePoint()
FLVPlayback.findNextCuePointWithName()
518
FLVPlayback Component (Flash Professional Only)
and then calls the
findNearestCuePoint()
event handler finds cue point
ready
method to find the next cue point with the same name:
findCuePoint()
method to find the
:
ASpt1
//add AS cue point
ASpt
//add AS cue point
//add 2nd Aspt
FLVPlayback.findCuePoint()
on page
589, and
on page
592.
method to find
and calls the
Need help?
Do you have a question about the FLASH 8-COMPONENTS LANGUAGE and is the answer not in the manual?
Questions and answers