03.05.2013 Views

FLASH® LITE™ 2.x - Adobe Help and Support

FLASH® LITE™ 2.x - Adobe Help and Support

FLASH® LITE™ 2.x - Adobe Help and Support

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

See also<br />

play (Video.play method), pause (Video.pause method), resume (Video.resume<br />

method)<br />

onStatus (Video.onStatus h<strong>and</strong>ler)<br />

onStatus = function(infoObject:Object) {}<br />

Callback h<strong>and</strong>ler that can be invoked by the device to indicate status or error conditions.<br />

Parameters<br />

infoObject:Object - The infoObject parameter has two properties:<br />

■ code:String — Description of the error or status condition (device specific).<br />

■ level:Number — Zero for error <strong>and</strong> non-zero for success (device specific).<br />

Example<br />

The following example shows how to create a Video.onStatus() function that displays a<br />

status or error condition.<br />

var v:Video; // v is a Video object on the stage.<br />

v.onStatus = function(o:Object)<br />

{<br />

if ( o.level )<br />

{<br />

trace( "Video Status Msg (" + o.level + "): " + o.code );<br />

}<br />

else<br />

{<br />

trace( "Video Status Error: " + o.code );<br />

}<br />

}<br />

v.play("a.vid");<br />

pause (Video.pause method)<br />

public pause() : Void<br />

Stops playback of the video <strong>and</strong> continues to render the current frame onscreen. A subsequent<br />

call to Video.resume() resumes playback from the current position.<br />

Example<br />

The following example stops the video that is playing in a Video object (called my_video)<br />

when the user clicks the close_btn instance.<br />

// video1 is the name of a Video object on Stage<br />

Video 673

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!