<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">\r
<HTML>\r
<TITLE>VLC Plugin test page</TITLE>\r
-<STYLE>\r
- .inputTrackerInput {\r
- height:20;\r
- width:30;\r
- font-family : Arial, Helvetica, sans-serif;\r
- font-size : 12px;\r
- }\r
-</STYLE>\r
-\r
-<SCRIPT type="text/javascript" src="blueshoes-4.5/javascript/lib/LibCrossBrowser.js"></SCRIPT>\r
-<SCRIPT type="text/javascript" src="blueshoes-4.5/javascript/lib/EventHandler.js"></SCRIPT>\r
-<SCRIPT type="text/javascript" src="blueshoes-4.5/javascript/core/form/Bs_FormUtil.lib.js"></SCRIPT>\r
-<SCRIPT type="text/javascript" src="blueshoes-4.5/javascript/components/slider/Bs_Slider.class.js"></SCRIPT>\r
\r
<SCRIPT language="JavaScript"><!--\r
function init()\r
{\r
- inputTracker = new Bs_Slider();\r
- if (inputTracker)\r
- {\r
- inputTracker.attachOnChange(onInputTrackerChange);\r
- inputTracker.attachOnSlideStart(onInputTrackerScrollStart);\r
- inputTracker.attachOnSlideEnd(onInputTrackerScrollEnd);\r
- inputTracker.width = 530 ;\r
- inputTracker.height = 15;\r
- inputTracker.minVal = 0;\r
- inputTracker.maxVal = 1.0;\r
- inputTracker.valueDefault = 0;\r
- inputTracker.valueInterval = 1/530;\r
- inputTracker.setDisabled(true);\r
- inputTracker.imgDir = 'blueshoes-4.5/javascript/components/slider/img/';\r
- inputTracker.setBackgroundImage('aluminumalloyvolcanic/horizontal_background.gif', 'repeat');\r
- inputTracker.setArrowIconLeft('aluminumalloyvolcanic/horizontal_backgroundLeft.gif', 2, 19);\r
- inputTracker.setArrowIconRight('aluminumalloyvolcanic/horizontal_backgroundRight.gif', 2, 19);\r
- inputTracker.setSliderIcon('aluminumalloyvolcanic/horizontal_knob.gif', 15, 19);\r
- inputTracker.useInputField = 0;\r
- inputTracker.draw('inputTrackerDiv');\r
- }\r
-\r
if( navigator.appName.indexOf("Microsoft Internet")==-1 )\r
{\r
onVLCPluginReady()\r
<!--\r
Insert Slider widget\r
-->\r
-<DIV id="inputTrackerDiv"</DIV>\r
</TD><TD width="15%">\r
<DIV id="info" style="text-align:center">-:--:--/-:--:--</DIV>\r
<DIV id="state" style="text-align:center">Stopped...</DIV>\r
\r
var rate = 0;\r
var prevState = 0;\r
-var monitorTimerId = 0;\r
-var inputTracker;\r
-var inputTrackerScrolling = false;\r
-var inputTrackerIgnoreChange = false;\r
var telxState = false;\r
\r
function doSetSlider()\r
// current media is playing\r
onPlaying();\r
}\r
- if( monitorTimerId == 0 )\r
- {\r
- monitorTimerId = setInterval("monitor()", 1000);\r
- }\r
};\r
\r
/* actions */\r
{\r
// play MRL\r
vlc.playlist.playItem(itemId);\r
- if( monitorTimerId == 0 )\r
- {\r
- monitor();\r
- }\r
+ monitor();\r
}\r
else\r
{\r
if( vlc )\r
vlc.playlist.stop();\r
\r
- if( monitorTimerId != 0 )\r
- {\r
- clearInterval(monitorTimerId);\r
- monitorTimerId = 0;\r
- }\r
onStop();\r
}\r
\r
\r
function onPlaying()\r
{\r
- if( !inputTrackerScrolling )\r
- {\r
var vlc = getVLC("vlc");\r
var info = document.getElementById("info");\r
if( vlc )\r
{\r
var mediaLen = vlc.input.length;\r
- inputTrackerIgnoreChange = true;\r
if( mediaLen > 0 )\r
{\r
- // seekable media\r
- if( inputTracker )\r
- {\r
- if( inputTracker.maxVal == 1.0 )\r
- {\r
- inputTracker.setDisabled(false);\r
- inputTracker.maxVal = 1.0;\r
- }\r
- inputTracker.setValue(vlc.input.position);\r
- }\r
info.innerHTML = formatTime(vlc.input.time)+"/"+formatTime(mediaLen);\r
}\r
else\r
{\r
// non-seekable "live" media\r
- if( inputTracker )\r
- {\r
- if( inputTracker.maxVal != 0.0 )\r
- {\r
- inputTracker.maxVal = 0.0;\r
- inputTracker.setValue(0.0);\r
- inputTracker.setDisabled(true);\r
- }\r
- }\r
liveFeedRoll = liveFeedRoll & 3;\r
info.innerHTML = liveFeedText[liveFeedRoll++];\r
}\r
- inputTrackerIgnoreChange = false;\r
}\r
}\r
}\r
\r
function onStop()\r
{\r
- var vlc = getVLC("vlc");\r
-\r
- if( inputTracker )\r
- {\r
- if( !inputTracker.disabled )\r
- {\r
- inputTracker.setValue(inputTracker.minVal);\r
- inputTracker.setDisabled(true);\r
- }\r
- }\r
-\r
document.getElementById("info").innerHTML = "-:--:--/-:--:--";\r
document.getElementById("state").innerHTML = "Stopped...";\r
document.getElementById("PlayOrPause").value = " Play ";\r
\r
function onError()\r
{\r
- var vlc = getVLC("vlc");\r
-\r
document.getElementById("state").innerHTML = "Error...";\r
}\r
\r
-function onInputTrackerScrollStart()\r
-{\r
- inputTrackerScrolling = true;\r
-}\r
-\r
-function onInputTrackerScrollEnd(inputTracker, value, pos)\r
-{\r
- inputTrackerScrolling = false;\r
-}\r
-\r
-function onInputTrackerChange(inputTracker, value, pos)\r
-{\r
- if( !inputTrackerIgnoreChange )\r
- {\r
- var vlc = getVLC("vlc");\r
- if( vlc )\r
- {\r
- if( (vlc.input.state == 3) && (vlc.input.position != value) )\r
- {\r
- var info = document.getElementById("info");\r
- vlc.input.position = value;\r
- info.innerHTML = formatTime(vlc.input.time)+"/"+formatTime(vlc.input.length);\r
- }\r
- }\r
- }\r
-}\r
-\r
function doMarqueeOption(option, value)\r
{\r
var vlc = getVLC("vlc");\r