| Package | com.devnet.osmf.controls |
| Class | public class ElapsedTime |
| Inheritance | ElapsedTime MediaControl flash.display.MovieClip |
| Language Version : | ActionScript 3.0 |
| Runtime Versions : | AIR 1.0, Flash Player 10.0.0 |
| Property | Defined By | ||
|---|---|---|---|
| currentTime : Number
Sets the current time value (in seconds) and
forces an update to the time display. | ElapsedTime | ||
![]() | mediaPlayer : MediaDisplay
Set the mediaPlayer property to associate a
media display instance with a control instance. | MediaControl | |
| timeText : TextField | ElapsedTime | ||
| totalTime : Number
Sets the total time value (in seconds) and
forces an update to the time display. | ElapsedTime | ||
| Method | Defined By | ||
|---|---|---|---|
| ElapsedTime | |||
getTime(sec:Number):String
Returns the formatted time from seconds (00:00 / 00:00). | ElapsedTime | ||
init():void [override]
Called when the mediaPlayer reference is set. | ElapsedTime | ||
| currentTime | property |
currentTime:NumberSets the current time value (in seconds) and forces an update to the time display.
public function get currentTime():Number public function set currentTime(value:Number):void| timeText | property |
public var timeText:TextField| totalTime | property |
totalTime:NumberSets the total time value (in seconds) and forces an update to the time display.
public function get totalTime():Number public function set totalTime(value:Number):void| ElapsedTime | () | Constructor |
public function ElapsedTime()| getTime | () | method |
public function getTime(sec:Number):StringReturns the formatted time from seconds (00:00 / 00:00).
Parameters
sec:Number — Number of seconds to format.
|
String — Formatted String.
|
| init | () | method |
override public function init():voidCalled when the mediaPlayer reference is set. Use this method to initialize the control with the OSMF media display.