home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Chip 2003 January
/
Chip_2003-01_cd1.bin
/
zkuste
/
wmakeup
/
download
/
anime.wmz
/
Anime.js
< prev
next >
Wrap
Text File
|
2000-05-15
|
3KB
|
145 lines
var plIsOpen = false;
var eqIsOpen = false;
var speed = 250;
function Init()
{
plist.setColumnResizeMode( 0, "Stretches" );
plist.setColumnResizeMode( 1, "AutoSizeData" );
if(player.OpenState == osMediaOpen)
{
OnPlayStateChange();
}
}
function OnOpenStateChange()
{
if(player.OpenState == osMediaOpen)
{
Init();
}
}
function OnPlayStateChange()
{
switch(player.PlayState)
{
case 1:
EndVideo();
break;
case 3:
if (player.currentMedia.ImageSourceWidth>0) {
vAnimation.visible = false;
vidWindow.visible = true;
visEffects.visible = false;
vid.visible = true;
// StartVideo();
}
break;
}
}
function togglePlView() {
if(plIsOpen) {
left_button.visible = false;
plist.visible = false;
vPlist.moveto(176,25,speed);
left_button.moveto(330, 105, speed);
} else {
lefthandle.visible = false;
vPlist.moveto(0,25,speed);
left_button.moveto(0, 105, 300);
}
plIsOpen = !plIsOpen;
}
function vPListOnEndMove(){
if(plIsOpen) {
left_button.visible = true;
plist.visible = true;
} else {
lefthandle.visible = true;
}
}
function StartVideo()
{
vAnimation.visible = false;
vidWindow.visible = true;
visEffects.visible = false;
vid.visible = true;
}
function EndVideo()
{
vidWindow.visible = false;
vAnimation.visible = true;
visEffects.visible = true;
vid.visible = false;
}
function togglePlVis(bool) {
if(plIsOpen) {
plist.visible = true;
}
}
// EQ tooltips are set dynamically, because otherwise they popup when the EQ is closed... bug?
eqToolTips = new Array("32 Hz","63 Hz","125 Hz","250 Hz","500 Hz","1 kHz","2 kHz","4 kHz","8 kHz","16 kHz");
function toggleEqView() {
if(eqIsOpen) {
vEq.moveto(488,25,speed);
right_button.moveto(700, 107, speed);
for(i=1; i<=10; i++) {
eval("eq" + i + ".tooltip=''");
}
} else {
righthandle.visible = false;
right_button.moveto(950, 107, 125);
vEq.moveto(700,25,speed);
vEq.visible = true;
for(i=1; i<=10; i++) {
eval("eq" + i + ".tooltip='" + eqToolTips[i-1] + "';");
}
}
eqIsOpen = !eqIsOpen;
}
function vEqOnEndMove() {
if(eqIsOpen) {
right_button.visible = true;
} else {
righthandle.visible = true;
}
}
function resetEq() {
eq.gainLevel1=0;
eq.gainLevel2=0;
eq.gainLevel3=0;
eq.gainLevel4=0;
eq.gainLevel5=0;
eq.gainLevel6=0;
eq.gainLevel7=0;
eq.gainLevel8=0;
eq.gainLevel9=0;
eq.gainLevel10=0;
}
function OnTimerTick()
{
var position = player.Controls.currentPosition;
var mm = ((position < 600) ? "0" : "")
+ Math.floor(position / 60);
var ss = ((position%60) < 10 ? "0" : "")
+ Math.floor(position % 60);
metadataTime.value = mm + ":" + ss;
}