Changeset 413
- Timestamp:
- 10/08/09 10:06:10 (4 years ago)
- Location:
- trunk/fl5/src/com/longtailvideo/jwplayer
- Files:
-
- 4 edited
-
events/PlayerEvent.as (modified) (1 diff)
-
events/PlayerStateEvent.as (modified) (1 diff)
-
view/components/ControlbarComponentV4.as (modified) (5 diffs)
-
view/components/DisplayComponent.as (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/fl5/src/com/longtailvideo/jwplayer/events/PlayerEvent.as
r396 r413 50 50 public static var JWPLAYER_ERROR:String = "jwplayerError"; 51 51 52 /**53 * The PlayerEvent.JWPLAYER_ERROR constant defines the value of the54 * <code>type</code> property of the event object55 * for a <code>jwplayerError</code> event.56 *57 * <table class="innertable">58 * <tr><th>Property</th><th>Value</th></tr>59 * <tr><td><code>id</code></td><td>ID of the player in the HTML DOM. Used by javascript to reference the player.</td></tr>60 * <tr><td><code>client</code></td><td>A string representing the client the player runs in (e.g. FLASH WIN 9,0,115,0).</td></tr>61 * <tr><td><code>version</code></td><td>A string representing the major version, minor version and revision number of the player (e.g. 5.0.395).</td></tr>62 * <tr><td><code>message</code></td><td>Message explaining the cause of the error</td></tr>63 * </table>64 *65 * @see com.longtailvideo.jwplayer.player.Player66 * @eventType jwplayerState67 */68 public static var JWPLAYER_STATE:String = "jwplayerState";69 70 52 public var id:String; 71 53 public var client:String; -
trunk/fl5/src/com/longtailvideo/jwplayer/events/PlayerStateEvent.as
r396 r413 3 3 4 4 public class PlayerStateEvent extends PlayerEvent { 5 6 /** 7 * The PlayerEvent.JWPLAYER_PLAYER_STATE constant defines the value of the 8 * <code>type</code> property of the event object 9 * for a <code>jwplayerPlayerState</code> event. 10 * 11 * <table class="innertable"> 12 * <tr><th>Property</th><th>Value</th></tr> 13 * <tr><td><code>id</code></td><td>ID of the player in the HTML DOM. Used by javascript to reference the player.</td></tr> 14 * <tr><td><code>client</code></td><td>A string representing the client the player runs in (e.g. FLASH WIN 9,0,115,0).</td></tr> 15 * <tr><td><code>version</code></td><td>A string representing the major version, minor version and revision number of the player (e.g. 5.0.395).</td></tr> 16 * <tr><td><code>newstate</code></td><td>The new state of the player</td></tr> 17 * <tr><td><code>oldstate</code></td><td>The previous state of the player</td></tr> 18 * </table> 19 * 20 * @see com.longtailvideo.jwplayer.player.PlayerState 21 * @eventType jwplayerPlayerState 22 */ 5 23 public static var JWPLAYER_PLAYER_STATE:String = "jwplayerPlayerState"; 24 6 25 7 26 public var newstate:String = ""; -
trunk/fl5/src/com/longtailvideo/jwplayer/view/components/ControlbarComponentV4.as
r406 r413 2 2 import com.longtailvideo.jwplayer.events.MediaEvent; 3 3 import com.longtailvideo.jwplayer.events.PlayerEvent; 4 import com.longtailvideo.jwplayer.events.PlayerStateEvent; 4 5 import com.longtailvideo.jwplayer.events.PlaylistEvent; 5 6 import com.longtailvideo.jwplayer.events.ViewEvent; … … 9 10 import com.longtailvideo.jwplayer.utils.Stacker; 10 11 import com.longtailvideo.jwplayer.utils.Strings; 11 import com.longtailvideo.jwplayer.view.components.CoreComponent;12 12 import com.longtailvideo.jwplayer.view.interfaces.IControlbarComponent; 13 13 … … 25 25 26 26 import mx.effects.Fade; 27 import com.longtailvideo.jwplayer.view.interfaces.IControlbarComponent;28 27 29 28 … … 74 73 skin.y = 0; 75 74 addChild(skin); 76 player.addEventListener(Player Event.JWPLAYER_STATE, stateHandler);75 player.addEventListener(PlayerStateEvent.JWPLAYER_PLAYER_STATE, stateHandler); 77 76 player.addEventListener(MediaEvent.JWPLAYER_MEDIA_TIME, timeHandler); 78 77 player.addEventListener(MediaEvent.JWPLAYER_MEDIA_MUTE, muteHandler); … … 404 403 } catch (err:Error) { 405 404 } 406 switch (player. config.state) {405 switch (player.state) { 407 406 case PlayerState.PLAYING: 408 407 case PlayerState.BUFFERING: -
trunk/fl5/src/com/longtailvideo/jwplayer/view/components/DisplayComponent.as
r411 r413 2 2 import com.longtailvideo.jwplayer.events.MediaEvent; 3 3 import com.longtailvideo.jwplayer.events.PlayerEvent; 4 import com.longtailvideo.jwplayer.events.PlayerStateEvent; 4 5 import com.longtailvideo.jwplayer.events.ViewEvent; 5 6 import com.longtailvideo.jwplayer.player.Player; 6 7 import com.longtailvideo.jwplayer.player.PlayerState; 7 import com.longtailvideo.jwplayer.view.components.CoreComponent;8 8 import com.longtailvideo.jwplayer.view.interfaces.IDisplayComponent; 9 9 … … 30 30 private function addListeners():void { 31 31 player.addEventListener(MediaEvent.JWPLAYER_MEDIA_MUTE, muteHandler); 32 player.addEventListener(Player Event.JWPLAYER_STATE, stateHandler);32 player.addEventListener(PlayerStateEvent.JWPLAYER_PLAYER_STATE, stateHandler); 33 33 player.addEventListener(PlayerEvent.JWPLAYER_ERROR, errorHandler); 34 34 addEventListener(MouseEvent.CLICK, clickHandler); … … 94 94 } 95 95 96 protected function stateHandler(event:Player Event):void {97 switch (event. type) {96 protected function stateHandler(event:PlayerStateEvent):void { 97 switch (event.newstate) { 98 98 case PlayerState.BUFFERING: 99 99 setDisplay(getSkinElement('display', 'bufferIcon'));
Note: See TracChangeset
for help on using the changeset viewer.
