Skip to content
This repository has been archived by the owner on Jul 11, 2022. It is now read-only.

- #245 fairly major issue with dragger animating before playback has act... #246

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions plugins/controls/README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ Version history:
3.2.17
------
- #191 fix for buffer bar flickering problem with RTMP
- #245 fairly major issue with dragger animating before playback has actually begun. Wait until buffer full events to fix issues when transversing between instream clips and when switching http clips.

3.2.16 (Nov 2013)
-----------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ package org.flowplayer.controls.scrubber {
private var _currentClip:Clip;
private var _isSeekPaused:Boolean;
private var _isRtmp:Boolean;
private var _started:Boolean;

public function ScrubberSlider(config:ScrubberConfig, player:Flowplayer, controlbar:DisplayObject) {
super(config, player, controlbar);
Expand Down Expand Up @@ -76,16 +77,29 @@ package org.flowplayer.controls.scrubber {

playlist.onBegin(function(event:ClipEvent):void {
_currentClip = event.target as Clip;
//#245 prevent the dragger animating until buffer full / playback begins.
_started = false;
});
playlist.onResume(function(event:ClipEvent):void {
_currentClip = event.target as Clip;
});

// onBegin instead of onStart: http://code.google.com/p/flowplayer-core/issues/detail?id=190
playlist.onBegin(start);
//playlist.onBegin(start);

//#404 stop/start dragger animation when switching to update correctly.
playlist.onSwitch(resume);
//#245 for http switching, the stream gets reset so stop the dragger and reset all elements to continue again on playback / buffer full.
playlist.onSwitch(function(event:ClipEvent):void {
if (_currentClip.provider == "http") {
stop(null);
_started = false;
updateDraggerPos(0, _currentClip);
doDrawBufferBar(0, 0);
drawProgressBar(0, 0);
} else {
resume(event);
}
});

playlist.onResume(resume);

Expand Down Expand Up @@ -304,9 +318,17 @@ package org.flowplayer.controls.scrubber {
animationEngine.pause(_dragger);
}

//#245 if playback has not begin start the dragger animation or else resume it after the buffer is full.
private function bufferFull(event:ClipEvent):void {
log.debug("bufferFull()");
animationEngine.resume(_dragger);
log.debug("bufferFull()");
if (!_started) {
start(event);
_started = true;

} else {
animationEngine.resume(_dragger);
}

}

private function stopAndRewind(event:ClipEvent):void {
Expand Down