home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Chip 2002 September (Special)
/
Chip-Special_2002-09_Digitalni-Video.bin
/
servis
/
wm9
/
mpsetupXP.exe
/
RCDATA
/
CABINET
/
wmploc.DLL
/
256
/
CROSSFADE.JS
< prev
next >
Wrap
Text File
|
2002-08-19
|
2KB
|
112 lines
// Windows Media Player - Copyright 2002 Microsoft Corporation.
//<script>
//
// Initialization
//
function InitCrossFade()
{
if (PlayingDVD())
{
normalizationOnOff.enabled=false;
crossFadeOnOff.enabled=false;
}
else
{
normalizationOnOff.enabled=true;
crossFadeOnOff.enabled=true;
}
UpdateNormalizationOnOff();
UpdateCrossFadeOnOff();
UpdateCrossFadeWindow();
}
function OnMediaChange(Item)
{
if( Item == player.currentMedia )
{
InitCrossFade();
}
}
//
// Updating
//
function UpdateCrossFadeOnOff()
{
if (eq.crossFade)
{
crossFadeOnOff.value="res://wmploc.dll/RT_STRING/#1916";
}
else
{
crossFadeOnOff.value="res://wmploc.dll/RT_STRING/#1915";
}
if (crossFadeOnOff.enabled)
{
SetDisabledUI(!eq.crossFade);
}
else
{
SetDisabledUI(true);
}
}
function UpdateCrossFadeWindow()
{
var format = theme.loadString("res://wmploc/RT_STRING/#1918");
var num = eq.crossFadeWindow / 100;
format = format.replace(/%1/i, Math.floor(num / 10));
format = format.replace(/%2/i, Math.floor(num % 10));
overlap.value = format;
}
function UpdateNormalizationOnOff()
{
if (eq.normalization)
{
normalizationOnOff.value="res://wmploc.dll/RT_STRING/#1912";
}
else
{
normalizationOnOff.value="res://wmploc.dll/RT_STRING/#1911";
}
var status = "";
if (osMediaOpen == player.openState)
{
if ((0.0 == eq.normalizationPeak) && (0.0 == eq.normalizationAverage))
{
status = theme.loadString("res://wmploc/RT_STRING/#1913");
}
else
{
status = theme.loadString("res://wmploc/RT_STRING/#1914");
var peak = Math.round(eq.normalizationPeak * 100.0);
var average = Math.round(eq.normalizationAverage * 100.0);
status = status.replace(/%1/i, Math.floor(peak / 100));
status = status.replace(/%2/i, Math.floor(peak % 100));
status = status.replace(/%3/i, Math.floor(average / 100));
status = status.replace(/%4/i, Math.floor(average % 100));
}
}
if ((normalizationOnOff.enabled) && (eq.normalization))
{
normalizationStatus.value = status;
}
else
{
normalizationStatus.value = "";
}
}