
A playback controller basically has at least play and stop buttons. Sometimes we may have the pause, next and previous buttons to control more than one item such as images, videos or sounds.
This component can be used to handle the task for rapid development. It is for the rapid development because it has already handled all status control (for display). So we no need to write the gotoandplay scripts again and again. And this component is not a Compiled Flash Component(and i'm not recommended) so all we need to do is just to change the visuals if need.
The way I handle the event is by using AsBroadcaster for simplicity (Even EventDispatcher can be used :)). The Playback is extended from MovieClip and with the following new events/properteis/methods:
Events (String):
- play
- stop
- pause
- next
- prev
Properties:
- status:String
Sample Code to handle the event:
playback_mc.addListener(this);
function changeStatus(status:String):Void {
trace(status);
}

(Pause during Playing)
No comments:
Post a Comment