[Pkg-javascript-commits] [jarisplayer] 11/80: fixed bug on redraw player controls function
Jonas Smedegaard
dr at jones.dk
Tue May 10 08:45:31 UTC 2016
This is an automated email from the git hooks/post-receive script.
js pushed a commit to branch master
in repository jarisplayer.
commit 3226dc2a06dfef65b7a125f08668bceb3e39e069
Author: jgmylm <jgmylm at edf201c3-a14d-0410-a11e-aa85364efa9f>
Date: Wed Mar 10 06:22:48 2010 +0000
fixed bug on redraw player controls function
git-svn-id: https://jaris.svn.sourceforge.net/svnroot/jaris/trunk@11 edf201c3-a14d-0410-a11e-aa85364efa9f
---
bin/JarisFLVPlayer.swf | Bin 18861 -> 18867 bytes
bin/index.html | 8 ++++----
src/jaris/Main.hx | 2 +-
src/jaris/player/controls/Controls.hx | 11 ++++++++++-
4 files changed, 15 insertions(+), 6 deletions(-)
diff --git a/bin/JarisFLVPlayer.swf b/bin/JarisFLVPlayer.swf
index a939b7d..f3090b3 100644
Binary files a/bin/JarisFLVPlayer.swf and b/bin/JarisFLVPlayer.swf differ
diff --git a/bin/index.html b/bin/index.html
index bd49bb0..c5f0e87 100644
--- a/bin/index.html
+++ b/bin/index.html
@@ -40,10 +40,10 @@
logowidth: "130",
logolink: "http://jaris.sourceforge.net",
hardwarescaling: "false",
- darkcolor: "000000",
- brightcolor: "4c4c4c",
- controlcolor: "FFFFFF",
- hovercolor: "67A8C1"
+ darkcolor: "D3D3D3",
+ brightcolor: "FFFFFF",
+ controlcolor: "000000",
+ hovercolor: "FF0000"
};
var params = {
menu: "false",
diff --git a/src/jaris/Main.hx b/src/jaris/Main.hx
index d72c315..f7268a3 100644
--- a/src/jaris/Main.hx
+++ b/src/jaris/Main.hx
@@ -118,8 +118,8 @@ class Main
controlColors[2] = parameters.controlcolor != null ? parameters.controlcolor : "";
controlColors[3] = parameters.hovercolor != null ? parameters.hovercolor : "";
- controls.setControlColors(controlColors);
controls.setDurationLabel(duration);
+ controls.setControlColors(controlColors);
movieClip.addChild(controls);
}
diff --git a/src/jaris/player/controls/Controls.hx b/src/jaris/player/controls/Controls.hx
index 82959f5..7196dea 100644
--- a/src/jaris/player/controls/Controls.hx
+++ b/src/jaris/player/controls/Controls.hx
@@ -580,9 +580,11 @@ class Controls extends MovieClip {
*/
private function redrawControls():Void
{
+ drawSeekControls();
+
var count:UInt = 1;
//draw until seekbar width == stage width
- if(_seekBar.width != _stage.stageWidth && count <= 3)
+ while(_seekBar.width != _stage.stageWidth && count <= 3)
{
drawSeekControls();
@@ -626,6 +628,7 @@ class Controls extends MovieClip {
_track.graphics.clear();
_thumb.graphics.clear();
+ //Draw seek bar
_seekBar.x = 0;
_seekBar.y = _stage.stageHeight - 25;
_seekBar.graphics.lineStyle();
@@ -635,6 +638,7 @@ class Controls extends MovieClip {
_seekBar.width = _stage.stageWidth;
_seekBar.height = 25;
+ //Draw trackbar
var matrix:Matrix = new Matrix( );
matrix.createGradientBox(_seekBar.width, 25, Utils.degreesToRadians(90), 0, _seekBar.height-25);
var colors:Array<UInt> = [_brightColor, _darkColor];
@@ -645,20 +649,25 @@ class Controls extends MovieClip {
_trackBar.graphics.drawRect(0, 0, _seekBar.width, _seekBar.height);
_trackBar.graphics.endFill( );
+ //Draw current play time label
_currentPlayTimeLabel.textColor = _controlColor;
_currentPlayTimeLabel.y = _seekBar.height - (_trackBar.height/2)-(_currentPlayTimeLabel.height/2);
+ //Draw total play time label
_totalPlayTimeLabel.textColor = _controlColor;
_totalPlayTimeLabel.x = _seekBar.width - _totalPlayTimeLabel.width;
_totalPlayTimeLabel.y = _seekBar.height - (_trackBar.height / 2) - (_totalPlayTimeLabel.height / 2);
+ //Draw download progress
drawDownloadProgress();
+ //Draw track place holder for drag
_track.graphics.lineStyle(1, _controlColor);
_track.graphics.beginFill(_darkColor, 0);
_track.graphics.drawRect(_currentPlayTimeLabel.width, (_seekBar.height / 2) - (10 / 2), _seekBar.width - _currentPlayTimeLabel.width - _totalPlayTimeLabel.width, 10);
_track.graphics.endFill();
+ //Draw thumb
_thumb.graphics.lineStyle();
_thumb.graphics.beginFill(_controlColor);
_thumb.graphics.drawRect(_currentPlayTimeLabel.width, (_seekBar.height/2)-(10/2), 10, 10);
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/jarisplayer.git
More information about the Pkg-javascript-commits
mailing list