Changeset 1276
- Timestamp:
- 03/07/10 10:21:32 (5 months ago)
- Location:
- flash_player/trunk/src/org/korsakow/player
- Files:
-
- 1 added
- 6 modified
-
engine/Engine.as (modified) (4 diffs)
-
engine/action/ExecuteSnuAction.as (modified) (1 diff)
-
engine/rules/RequireKeywordsRule.as (modified) (2 diffs)
-
engine/rules/SearchRule.as (modified) (1 diff)
-
engine/rules/SetBackgroundSoundRule.as (added)
-
widget/MultiMediaArea.mxml (modified) (1 diff)
-
widget/VideoArea.mxml (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
flash_player/trunk/src/org/korsakow/player/engine/Engine.as
r1271 r1276 125 125 addEventListener(EnvironmentEvent.SNU_BEGIN_PLAYING, onSnuBeginPlaying); 126 126 addEventListener(EnvironmentEvent.SNU_FINISH_PLAYING, onSnuFinishPlaying); 127 addEventListener(EnvironmentEvent.SNU_TIME_UPDATE, onSnuTimeUpdate);128 129 127 130 128 dispatchEvent(new EnvironmentEvent(EnvironmentEvent.INITIALIZED)); … … 147 145 removeEventListener(EnvironmentEvent.SNU_BEGIN_PLAYING, onSnuBeginPlaying); 148 146 removeEventListener(EnvironmentEvent.SNU_FINISH_PLAYING, onSnuFinishPlaying); 149 removeEventListener(EnvironmentEvent.SNU_TIME_UPDATE, onSnuTimeUpdate);150 147 } 151 148 public function showErrorDialog(message:String, title:String):void … … 309 306 return _currentSnuTime; 310 307 } 308 public function set currentSnuTime(time:uint):void 309 { 310 _currentSnuTime = time; 311 } 311 312 public function get currentSnuTimeOffset():uint 312 313 { … … 665 666 protected function onSnuFinishPlaying(event:EnvironmentEvent):void 666 667 { 667 }668 protected function onSnuTimeUpdate(event:EnvironmentEvent):void669 {670 if (_currentInterfacaMainMedia)671 _currentSnuTime = _currentInterfacaMainMedia.playTime;672 668 } 673 669 protected function togglePauseScreen(event:MediaEvent):void -
flash_player/trunk/src/org/korsakow/player/engine/action/ExecuteSnuAction.as
r1260 r1276 234 234 protected function onMainMediaTime(event:MediaEvent=null):void 235 235 { 236 if (_engine.currentMainMedia) 237 _engine.currentSnuTime = _engine.currentMainMedia.playTime; 236 238 _engine.snuEventContext.dispatchEvent(new EnvironmentEvent(EnvironmentEvent.SNU_TIME_UPDATE)); 237 239 _engine.dispatchEvent(new EnvironmentEvent(EnvironmentEvent.SNU_TIME_UPDATE)); -
flash_player/trunk/src/org/korsakow/player/engine/rules/RequireKeywordsRule.as
r255 r1276 1 1 package org.korsakow.player.engine.rules 2 2 { 3 import __AS3__.vec.Vector; 4 3 import org.korsakow.debug.Debug; 5 4 import org.korsakow.domain.Rule; 6 5 import org.korsakow.domain.RuleType; … … 17 16 override public function execute(env:IEnvironment):void 18 17 { 18 Debug.log("RequireKeywordsRule.execute; keywords=", keywords); 19 19 // we give each snu without the keyword a score of 0 20 20 var snusWithoutKeyword:Vector.<ISnu> = new Vector.<ISnu>; // an array of snu vectors -
flash_player/trunk/src/org/korsakow/player/engine/rules/SearchRule.as
r1244 r1276 106 106 continue; 107 107 var score:Score = env.getSnuScore(snu); 108 Debug.log("\tSearchRule.links", '#'+i, snu.id, '('+snu.name+')', score.score, '('+snu.rating+')'); 109 availableLinks[linksCounter].snu = candidates[i]; 108 var chosenLink:ISnuLink = availableLinks[linksCounter]; 109 Debug.log("\tSearchRule.links", 'available#'+i, 'index#'+chosenLink.model['index'], snu.id, '('+snu.name+')', score.score, '('+snu.rating+')'); 110 chosenLink.snu = candidates[i]; 110 111 linksCounter++; 111 112 ++maxlinkscount; -
flash_player/trunk/src/org/korsakow/player/widget/MultiMediaArea.mxml
r1263 r1276 155 155 super.initializeWidget(env); 156 156 playMedia(_mediaId); 157 Debug.log("MediaArea.init", visible, _media?_media.name:'', _media?_media.filename:'');157 Debug.log("MediaArea.init", 'id#'+(this), visible, _media?_media.name:'', _media?_media.filename:''); 158 158 } 159 159 override public function destroyWidget(env:IEnvironment):void -
flash_player/trunk/src/org/korsakow/player/widget/VideoArea.mxml
r1272 r1276 216 216 { 217 217 ScalingPolicy.apply(scalingPolicy, video, this.width, this.height); 218 trace('VideoArea.scaling', this.width, this.height, video.width, video.height);219 218 } 220 219 override public function destroyWidget(env:IEnvironment):void
