home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Minami 79
/
MINAMI79.iso
/
Extra
/
MPSetup.exe
/
1033
/
RCDATA
/
CABINET
/
wmploc.DLL
/
256
/
VIZ.JS
< prev
next >
Wrap
Text File
|
2002-12-14
|
3KB
|
118 lines
// Windows Media Player - Copyright 2000 Microsoft Corporation.
//<script>
function OnLoad()
{
UpdateFullScreenAvailability();
// registry controlled skunk works, Blend Album Art feature
var baa = theme.loadPreference("BlendAlbumArt");
if(baa == "true")
{
myeffect.windowed = "false";
btnCoverArt.visible = "true";
}
else
{
myeffect.windowed = "true";
btnCoverArt.visible = "false";
}
// end - skunk works
}
function OnShowTitles()
{
UpdateTitles();
myeffect.top = mediacenter.showTitles? 45 : 4;
myeffect.height = VizDisplay.height - myeffect.top - myeffect.left;
}
function OnVizRequest(Request)
{
switch(Request)
{
case VR_PRESET_PREV:
myeffect.previous();
break;
case VR_PRESET_NEXT:
myeffect.next();
break;
case VR_VIZ_PREV:
myeffect.previousEffect();
break;
case VR_VIZ_NEXT:
myeffect.nextEffect();
break;
default:
return;
break;
}
SynchViz();
}
function UpdateTitles()
{
if (!player.currentMedia) return;
trackname.visible = mediacenter.showTitles;
playlistArtist.value = player.currentMedia.getItemInfo('artist');
trackname.value = player.currentMedia.name;
// skunk works, Blend Album Art feature
UpdateAlbumArt("WMPImage_AlbumArtLarge");
}
// skunk works, Blend Album Art feature
function UpdateAlbumArt(bstrItemName)
{
if(btnCoverArt.visible &&
(bstrItemName == "WMPImage_AlbumArtSmall" || bstrItemName == "WMPImage_AlbumArtLarge"))
{
btnCoverArt.alphaBlend = "0";
btnCoverArt.image = "WMPImage_AlbumArtLarge";
btnCoverArt.alphaBlendTo(0xA0, 6000);
}
}
// end skunk works
function UpdateFullScreenAvailability()
{
mediacenter.fullScreenAvailable=myeffect.effectCanGoFullscreen;
}
function SynchViz()
{
var nPreset = myeffect.currentPreset;
mediacenter.effectType = myeffect.currentEffectType;
mediacenter.effectPreset = nPreset;
SynchEffectColor();
}
function SynchEffectColor()
{
try
{
if (myeffect.currentEffectType=="Bars")
{
if ( (myeffect.currentPreset==1) || (myeffect.currentPreset==2) )
{
//ignore Ocean Mist and Fire Storm
return;
}
else
{
var bars = myeffect.currentEffect;
bars.levelColor = mediacenter.itemPlayingColor;
bars.peakColor = mediacenter.appColorLight;
}
}
else
{
//give all viz'es a chance to synch the color
myeffect.currentEffect.foregroundColor = mediacenter.itemPlayingColor;
}
}
catch(err){}
}