home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC World Plus! (NZ) 2001 November
/
PCW1101.ISO
/
Essent
/
MediaPlayer
/
mp71.exe
/
RCDATA
/
CABINET
/
Roundlet.wmz
/
roundlet.js
< prev
next >
Wrap
Text File
|
2001-03-02
|
3KB
|
143 lines
/*
⌐2000 Microsoft Corporation. All rights reserved.
*/
var visPane = 0;
var vidPane = 1;
var plPane = 2;
var eqPane = 3;
var currentPane = 0;
var vidIsRunning = false;
function Init()
{
pl.setColumnResizeMode(0, "Stretches");
pl.setColumnResizeMode(1, "AutoSizeData");
visEffects.currentEffectType = mediacenter.effectType;
visEffects.currentPreset = mediacenter.effectPreset;
vidIsRunning =
(player.PlayState==psPlaying ||
player.PlayState==psPaused) &&
(player.currentMedia.ImageSourceWidth>0);
if(vidIsRunning)
{
StartVideo();
}
else
{
SetVisibility(visPane);
}
}
function OnClose()
{
mediacenter.effectType = visEffects.currentEffectType;
mediacenter.effectPreset = visEffects.currentPreset;
}
function StartVideo()
{
vidIsRunning = true;
SetVisibility(vidPane);
}
function EndVideo()
{
vidIsRunning = false;
if(currentPane == vidPane)
{
SetVisibility(visPane);
}
}
function SetVisibility(newPane)
{
bVisToggle.enabled = true;
switch(newPane)
{
case plPane:
pl.visible =
sPlView.visible = true;
sEq.visible =
vid.visible =
visEffects.visible =
bgToggleEq.down = false;
bVisToggle.upToolTip =
bgTogglePl.downToolTip = vidIsRunning ?
xVideoTt.toolTip : xVisTt.toolTip;
break;
case eqPane:
sEq.visible = true;
pl.visible =
sPlView.visible =
vid.visible =
visEffects.visible =
bgTogglePl.down = false;
bVisToggle.upToolTip =
bgToggleEq.downToolTip = vidIsRunning ?
xVideoTt.toolTip : xVisTt.toolTip;
break;
case vidPane:
vid.visible = true;
pl.visible =
sPlView.visible =
sEq.visible =
visEffects.visible =
bgTogglePl.down =
bgToggleEq.down = false;
bVisToggle.upToolTip = "";
bgToggleEq.downToolTip =
bgTogglePl.downToolTip = xVideoTt.toolTip;
bVisToggle.enabled = false;
break;
case visPane:
visEffects.visible = true;
pl.visible =
sPlView.visible =
sEq.visible =
vid.visible =
bgTogglePl.down =
bgToggleEq.down = false;
bVisToggle.upToolTip = xVisTt.value;
bgToggleEq.downToolTip =
bgTogglePl.downToolTip = xVisTt.toolTip;
break;
}
currentPane = newPane;
}
function TogglePlaylist()
{
SetVisibility( (currentPane==plPane) ?
(vidIsRunning ? vidPane : visPane)
: plPane );
}
function ToggleEq()
{
SetVisibility( (currentPane==eqPane) ?
(vidIsRunning ? vidPane : visPane)
: eqPane );
}
function VisClick()
{
if(currentPane == visPane)
{
visEffects.next();
}
else
{
SetVisibility(vidIsRunning ?
vidPane : visPane);
}
}