Changeset 1606
- Timestamp:
- 02/17/11 10:08:24 (2 years ago)
- Location:
- plugins/qualitymonitor/v5
- Files:
-
- 2 edited
-
qualitymonitor.swf (modified) (previous)
-
src/com/longtailvideo/plugins/qualitymonitor/QualityMonitor.as (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
plugins/qualitymonitor/v5/src/com/longtailvideo/plugins/qualitymonitor/QualityMonitor.as
r1487 r1606 48 48 /** Build the plugin graphics. **/ 49 49 private function buildStage():void { 50 mouseEnabled = false;51 mouseChildren = false;52 50 _back = new Sprite(); 53 51 _back.graphics.beginFill(0x000000,0.8); 54 52 _back.graphics.drawRect(0,0,400,116); 53 _back.mouseEnabled = false; 54 _back.mouseChildren = false; 55 55 addChild(_back); 56 56 _field = new TextField(); … … 62 62 _field.y = 12; 63 63 _field.x = 16; 64 _field.mouseEnabled = false; 64 65 addChild(_field); 65 66 _lines = new Array( … … 76 77 _message.width = 300; 77 78 _message.visible = false; 79 _message.mouseEnabled = false; 78 80 addChild(_message); 79 81 }; … … 82 84 /** Update quality metrics chart. **/ 83 85 private function checkQuality():void { 84 var idx:Number = 1;85 var txt:String = _data.level;86 var txt:String = _data.currentLevel; 87 var idx:Number = Number(_data.currentLevel.substr(0,1)); 86 88 if(_player.playlist.length) { 87 89 var arr:Array = _player.playlist.currentItem.levels; … … 117 119 _player.addEventListener(PlayerStateEvent.JWPLAYER_PLAYER_STATE,stateHandler); 118 120 _data = { 119 bandwidth: _player.config.bandwidth,121 bandwidth: 95, 120 122 droppedFrames: 0, 121 level: '1 of 1',123 currentLevel: '1 of 1 (5kbps, 320px)', 122 124 width: _player.config.width 123 125 }; … … 138 140 _data.droppedFrames = event.metadata.droppedFrames; 139 141 } 140 if(event.metadata. width) {141 _data. level = '1 of 1 ('+event.metadata.width+'px)';142 if(event.metadata.currentLevel) { 143 _data.currentLevel = event.metadata.currentLevel; 142 144 } 143 145 if(event.metadata.type == 'blacklist') {
Note: See TracChangeset
for help on using the changeset viewer.
