home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC World Plus! (NZ) 2000 October
/
PCWORLDPLUS_OCTO.BIN
/
review
/
wmp7.exe
/
RCDATA
/
CABINET
/
wmploc.DLL
/
256
/
170
< prev
next >
Wrap
Text (UTF-16)
|
2000-06-26
|
8KB
|
157 lines
var settingsIsOpen = false;
var playlistIsOpen = false;
var giSettingsPos = 0;
var gsSettingsNames = new Array("SRSSettings", "AudioSettings", "VideoSettings");
var openedWidth = 640;
var closedWidth = 422;
var openedHeight = 480;
var closedHeight = 378;
function InitCompact()
{
playlist.setColumnResizeMode( 0, "Stretches" );
playlist.setColumnResizeMode( 1, "AutoSizeData" );
InitVisualizations(); // Init the Video and Visualization windows
InitControls(); // Init mode transports
InitEQ();
InitSRS();
OnModeChange();
// load saved settings
var s = "";
s = theme.loadPreference("SettingsTab");
for (var i = 0; i < gsSettingsNames.length; i++)
{
if (s == gsSettingsNames[i])
{
giSettingsPos = i;
}
}
ChangeSettingsTab(0); // Init settings tab
s = theme.loadPreference("SettingsDrawer");
if (s == "True")
ToggleSettings();
s = theme.loadPreference("PlaylistDrawer");
if (s == "True")
TogglePlaylist();
}
function CloseCompact()
{
theme.savePreference("SettingsTab", gsSettingsNames[giSettingsPos]);
theme.savePreference("SettingsDrawer", settingsIsOpen);
theme.savePreference("PlaylistDrawer", playlistIsOpen);
CloseVisualizations();
}
function ToggleSettings()
{
if(settingsIsOpen==true)
{
settingsDrawer.moveTo(settingsDrawer.left,236,1000);
settingsIsOpen=false;
}
else
{
view.height = openedHeight;
settingsTab.visible = true;
settingsDrawer.moveTo(settingsDrawer.left,338,1000);
settingsIsOpen=true;
ChangeSettingsTab(0);
}
}
function TogglePlaylist()
{
if(playlistIsOpen==true)
{
playlist.visible=false;
playlistDrawer.moveTo(219, playlistDrawer.top,1000);
playlistIsOpen=false;
}
else
{
view.width = openedWidth;
playlistDrawer.moveTo(397, playlistDrawer.top,1000);
playlistIsOpen=true;
}
}
function OnModeChange()
{
shuffle.down = player.settings.GetMode("shuffle");
}
function Playlist_OnEndMove()
{
if(playlistIsOpen==true)
{
playlist.visible=true;
}
else
{
playlist.visible=false;
view.width = closedWidth;
}
}
function Settings_OnEndMove()
{
if (!settingsIsOpen)
{
SRSSettings.visible = false;
AudioSettings.visible = false;
VideoSettings.visible = false;
settingsTab.visible = false;
view.height = closedHeight;
}
}
function ChangeSettingsTab(iWhichDir)
{
var iPos = giSettingsPos;
iPos = iPos + iWhichDir;
if (iPos < 0)
{
iPos = gsSettingsNames.length -1;
}
else if (iPos >= gsSettingsNames.length)
{
iPos = 0;
}
if (settingsIsOpen)
{
switch (iPos)
{
case 0:
AudioSettings.visible = false;
VideoSettings.visible = false;
SRSSettings.visible = true;
tabTitle.value = "res://wmploc.dll/RT_STRING/#1827";
break;
case 1:
SRSSettings.visible = false;
VideoSettings.visible = false;
AudioSettings.visible = true;
tabTitle.value = "res://wmploc.dll/RT_STRING/#1848";
break;
case 2:
SRSSettings.visible = false;
AudioSettings.visible = false;
VideoSettings.visible = true;
tabTitle.value = "res://wmploc.dll/RT_STRING/#1849";
break;
}
}
giSettingsPos = iPos;
}