Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-1.1
Commits
2b2cb996
Commit
2b2cb996
authored
May 11, 2005
by
Damien Fouilleul
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test.html: improved user feedback, especially for live stream
parent
83974ced
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
104 additions
and
77 deletions
+104
-77
activex/test.html
activex/test.html
+104
-77
No files found.
activex/test.html
View file @
2b2cb996
<HTML>
<TITLE>
VLC ActiveX plugin test page
</TITLE>
<BODY>
<TABLE>
<TR><TD
colspan=
"2"
>
MRL:
<INPUT
size=
"90"
name=
"targetTextField"
value=
""
>
<INPUT
type=
submit
value=
"Go"
onClick=
"doGo(targetTextField.value);"
>
</TD></TR>
<TR><TD
colspan=
"2"
>
<!--
Insert VideoLAN.VLCPlugin.1 activex control
-->
<OBJECT
classid=
"clsid:E23FE9C6-778E-49D4-B537-38FCDE4887D8"
codebase=
"axvlc.cab"
width=
"640"
height=
"480"
id=
"vlc"
events=
"True"
>
<param
name=
"Src"
value=
""
/>
<param
name=
"ShowDisplay"
value=
"True"
/>
<param
name=
"Loop"
value=
"False"
/>
<param
name=
"AutoPlay"
value=
"False"
/>
</OBJECT>
</TD></TR>
<TR><TD>
<!--
Insert MSComctlLib.Slider.2 activex control
-->
<OBJECT
classid=
"clsid:F08DF954-8592-11D1-B16A-00C0F0283628"
width=
"540"
height=
"20"
id=
"slider"
events=
"True"
>
<param
name=
"TickStyle"
value=
"3"
/>
<param
name=
"Min"
value=
"0"
/>
<param
name=
"Max"
value=
"0"
/>
<param
name=
"Value"
value=
"0"
/>
<param
name=
"Enabled"
value=
"False"
/>
</OBJECT>
</TD><TD
width=
"15%"
>
<DIV
id=
"info"
style=
"text-align:center"
>
-:--:--/-:--:--
</DIV>
</TD></TR>
<TR><TD
colspan=
"2"
>
<INPUT
type=
button
id=
"PlayOrPause"
value=
" Play "
onClick=
'doPlayOrPause()'
>
<INPUT
type=
button
value=
"Stop"
onClick=
'document.vlc.stop();'
>
<INPUT
type=
button
value=
" << "
onClick=
'document.vlc.playSlower();'
>
<INPUT
type=
button
value=
" >> "
onClick=
'document.vlc.playFaster();'
>
<INPUT
type=
button
value=
"Mute"
onClick=
'document.vlc.toggleMute();'
>
<INPUT
type=
button
value=
"Show"
onClick=
'document.vlc.Visible = true;'
>
<INPUT
type=
button
value=
"Hide"
onClick=
'document.vlc.Visible = false;'
>
<INPUT
type=
button
value=
"Version"
onClick=
'alert(document.vlc.VersionInfo);'
>
</TD></TR>
</TABLE>
<SCRIPT
LANGUAGE=
"JScript"
>
<!--
var sliderTimerId = 0;
...
...
@@ -22,82 +66,84 @@ function formatTime(timeVal)
else
return timeMin+":"+timeSec;
};
function
go(targetURL
)
function
onPlay(
)
{
var options = new Array(":input-repeat");
document.vlc.addTarget(targetURL, options, 4+8, -666);
if( ! sliderTimerId )
document.getElementById("PlayOrPause").value = "Pause";
};
function onPause()
{
document.getElementById("PlayOrPause").value = " Play ";
};
function onStop()
{
if( slider.Enabled )
{
sliderTimerId = setTimeout("updateInterface()", 1000);
slider.Value = slider.Min;
slider.Enabled = false;
}
info.innerText = "-:--:--/-:--:--";
document.getElementById("PlayOrPause").value = " Play ";
};
function updateInterface()
var liveFeedText = new Array("Live", "((Live))", "(( Live ))", "(( Live ))");
var liveFeedRoll = 0;
function doUpdate()
{
if(
! sliderScroll
ing )
if(
vlc.Play
ing )
{
if(
vlc.Length > 0
)
if(
! sliderScrolling
)
{
slider.Enabled = true;
slider.Max = vlc.Length;
slider.Value = vlc.Time;
info.innerText = formatTime(vlc.Time)+"/"+formatTime(vlc.Length);
}
else if( slider.Enabled )
{
slider.Enabled = false;
slider.Value = slider.Min;
info.innerText = "--:--/--:--";
if( vlc.Length > 0 )
{
// seekable stream
slider.Enabled = true;
slider.Max = vlc.Length;
slider.Value = vlc.Time;
info.innerText = formatTime(vlc.Time)+"/"+formatTime(vlc.Length);
document.getElementById("PlayOrPause").Enabled = true;
}
else {
// non-seekable "live" stream
if( slider.Enabled )
{
slider.Value = slider.Min;
slider.Enabled = false;
}
liveFeedRoll = liveFeedRoll & 3;
info.innerText = liveFeedText[liveFeedRoll++];
}
}
sliderTimerId = setTimeout("doUpdate()", 1000);
}
if( vlc.Playing )
else
{
sliderTimerId = setTimeout("updateInterface()", 1000);
onStop();
sliderTimerId = 0;
}
};
function doGo(targetURL)
{
var options = new Array(":input-repeat=1");
document.vlc.addTarget(targetURL, options, 4+8, -666);
};
function doPlayOrPause()
{
if( document.vlc.playing )
{
document.vlc.pause();
}
else
{
sliderTimerId = 0
;
document.vlc.play()
;
}
};
//-->
</SCRIPT>
<TABLE>
<TR><TD
colspan=
"2"
>
MRL:
<INPUT
size=
"90"
name=
"targetTextField"
value=
""
>
<INPUT
type=
submit
value=
"Go"
onClick=
"go(targetTextField.value);"
>
</TD></TR>
<TR><TD
colspan=
"2"
>
<!--
Insert VideoLAN.VLCPlugin.1 activex control
-->
<OBJECT
classid=
"clsid:E23FE9C6-778E-49D4-B537-38FCDE4887D8"
codebase=
"axvlc.cab"
width=
"640"
height=
"480"
id=
"vlc"
events=
"True"
>
<param
name=
"Src"
value=
""
/>
<param
name=
"ShowDisplay"
value=
"True"
/>
<param
name=
"Loop"
value=
"False"
/>
<param
name=
"AutoPlay"
value=
"False"
/>
</OBJECT>
</TD></TR>
<TR><TD>
<!--
Insert MSComctlLib.Slider.2 activex control
-->
<OBJECT
classid=
"clsid:F08DF954-8592-11D1-B16A-00C0F0283628"
width=
"540"
height=
"20"
id=
"slider"
events=
"True"
>
<param
name=
"TickStyle"
value=
"3"
/>
<param
name=
"Min"
value=
"0"
/>
<param
name=
"Max"
value=
"0"
/>
<param
name=
"Value"
value=
"0"
/>
<param
name=
"Enabled"
value=
"False"
/>
</OBJECT>
<SCRIPT
LANGUAGE=
"JScript"
>
function vlc::play()
{
if( ! sliderTimerId )
{
sliderTimerId = setTimeout("
updateInterfac
e()", 1000);
sliderTimerId = setTimeout("
doUpdat
e()", 1000);
}
onPlay();
};
function vlc::pause()
{
...
...
@@ -106,6 +152,7 @@ function vlc::pause()
clearTimeout(sliderTimerId)
sliderTimerId = 0;
}
onPause();
};
function vlc::stop()
{
...
...
@@ -113,13 +160,8 @@ function vlc::stop()
{
clearTimeout(sliderTimerId)
sliderTimerId = 0;
if( slider.Enabled )
{
slider.Value = slider.Min;
slider.Enabled = false;
info.innerText = "--:--/--:--";
}
}
onStop();
};
function slider::Scroll()
{
...
...
@@ -143,20 +185,5 @@ function slider::Change()
};
//-->
</SCRIPT>
</TD><TD
width=
"15%"
>
<DIV
id=
"info"
style=
"text-align:right"
>
--:--/--:--
</DIV>
</TD></TR>
<TR><TD
colspan=
"2"
>
<INPUT
type=
button
value=
"Play"
onClick=
'document.vlc.play();'
>
<INPUT
type=
button
value=
"Stop"
onClick=
'document.vlc.stop();'
>
<INPUT
type=
button
value=
"Pause"
onClick=
'document.vlc.pause();'
>
<INPUT
type=
button
value=
" << "
onClick=
'document.vlc.playSlower();'
>
<INPUT
type=
button
value=
" >> "
onClick=
'document.vlc.playFaster();'
>
<INPUT
type=
button
value=
"Mute"
onClick=
'document.vlc.toggleMute();'
>
<INPUT
type=
button
value=
"Show"
onClick=
'document.vlc.Visible = true;'
>
<INPUT
type=
button
value=
"Hide"
onClick=
'document.vlc.Visible = false;'
>
<INPUT
type=
button
value=
"Version"
onClick=
'alert(document.vlc.VersionInfo);'
>
</TD></TR>
</TABLE>
</BODY>
</HTML>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment