home *** CD-ROM | disk | FTP | other *** search
Wrap
/* http://www.theskinsfactory.com info@theskinsfactory.com XSN Sports WMP 9Series skin (XP) */ /* var contentStatus = false; function toggleContent() { if(!contentStatus) { contentMode.alphaBlendTo(255,500); contentStatus = !contentStatus; } else { contentMode.alphaBlendTo(0,500); contentStatus = !contentStatus; } } */ function checkPlayerVersion() { if(player){} view.width = 0; view.height = 0; view.backgroundImage = ""; var ver = parseInt(player.versionInfo); switch(ver) { case 7: theme.currentViewID = "upgradeView"; break; case 8: theme.currentViewID = "upgradeView"; break; case 9: theme.currentViewID = "mainView"; break; default: theme.currentViewID = "mainView"; break; } } // upgrade view function loadUpgradePrefs(){ view.height = view.minHeight; var ver = parseInt(player.versionInfo); mpVersion.value = mp9.toolTip; mpVersion.value += ver; } function mainStartUp() { volume.value = player.settings.volume; htcpSetTimerStatus(); htcpSetTimer(); htcpSetID(); htcpSetMsg(); loadMainPrefs(); theme.savePreference("vidViewer", "false"); checkPlayerState(); updateMetadata('status'); } function checkPlayerState() { if (player) { switch (player.playState) { case 2: case 3: //playing if(("false"==theme.loadPreference("vidViewer"))&&player.currentMedia.ImageSourceWidth>0) { sampleAlpha(); theme.openView('videoView'); theme.savePreference('htcpTimerStatus', "false" ); if("true"==theme.loadPreference("visViewer")){ theme.savePreference("visViewer", "false"); theme.closeView( "visView" ); } break } break; } } if(!player.controls.isAvailable("Stop")) { } } // metadata function updateMetadata(type){ if("status"==type){ if(player.openState!=13) return; var metaAuthor = player.currentMedia.getItemInfo("author"); if (metaAuthor != "") { metaAuthor += " - "; } metadata.value = player.status; if (metadata.value != "") { metadata.value += " - "; } metadata.value += metaAuthor; }else if("playlist"==type){ if(player.currentPlaylist.count==0) return; var metaAuthor = player.currentMedia.getItemInfo("author"); if (metaAuthor != "") { metaAuthor += " - "; } if(player.openState!=13){ metadata.value = metaAuthor; } }else{ metadata.value = player.status; metadata.scrolling = (metadata.textWidth>metadata.width); return; } metadata.value += player.currentmedia.name; metadata.scrolling = (metadata.textWidth>metadata.width); } var seekStatus = true; function drawSeekDigits( seconds ) { if(player.currentPlaylist.count==0) return; if( !seekStatus ) { seconds = player.currentMedia.duration - seconds; } frame = 14 seconds = seconds - seconds % 1; time4.left = -( seconds % 10 ) * frame; seconds = seconds - ( seconds % 10); time3.left = -( ( seconds % 60 ) / 10 ) * frame; seconds = seconds - ( seconds % 60 ); seconds = seconds / 60; time2.left = -( seconds % 10 ) * frame; seconds = seconds - ( seconds % 10 ); time1.left = -( seconds / 10 ) * frame; } function SetTimeShowState() { seekStatus = !seekStatus; if( seekStatus ) { timeDash.visible = false;; } else { timeDash.visible = true; } seconds = seek.value; drawSeekDigits( seconds ); } //special function volInc(){ if(player.settings.volume < 95){ player.settings.volume+=5; }else{ player.settings.volume = 100; } player.settings.mute = false; } function volDec(){ if(player.settings.volume > 5){ player.settings.volume-=5; }else{ player.settings.volume = 0; } player.settings.mute = false; } function seekInc(){ if(player.openState!=13) return; if(player.controls.currentPosition < player.currentMedia.duration){ player.controls.currentPosition+=10; }else{ player.controls.currentPosition = player.currentMedia.duration; } } function seekDec(){ if(player.openState!=13) return; if(player.controls.currentPosition > 10){ player.controls.currentPosition-=10; }else{ player.controls.currentPosition = 0; } } // open file function openFile() { var media = theme.openDialog('FILE_OPEN','FILES_ALLMEDIA'); if(media) { player.URL = media; player.controls.play(); } } function viewHotKeys() { switch(event.keycode) { case 122: case 90: player.controls.previous(); break; case 120: case 88: player.controls.play(); break; case 99: case 67: player.controls.pause(); break; case 118: case 86: player.controls.stop(); break; case 98: case 66: player.controls.next(); break; case 108: case 76: openFile(); break; } } function viewResizer(event) { switch(event.keycode) { case 37: view.width-=20; break; case 38: view.height-=20 break; case 39: view.width+=20; break; case 40: view.height+=20; break; } } function updateToolTip(id,button,tip) { if("true"==theme.loadPreference( id )) { eval( button +".upToolTip = locHide" + tip + ".toolTip" ); } else { eval( button +".upToolTip = locShow" + tip + ".toolTip" ); } } function updateSeekToolTip() { if(player.openState!=13) return; var seekHours = Math.floor((seek.value / 3600)); if (seekHours < 10) seekHours = "0" + seekHours; var seekMinutes = Math.floor((seek.value - (seekHours*3600))/60); if (seekMinutes < 10) seekMinutes = "0" + seekMinutes; var seekSeconds = Math.floor((seek.value - (seekMinutes*60) - (seekHours*3600))); if (seekSeconds < 10) seekSeconds = "0" + seekSeconds; var seekString; if (seekHours==00) { seekString = ""; } else { seekString = seekHours + ":"; } seekString += seekMinutes + ":" + seekSeconds; seek.toolTip = seekString; seek.toolTip += " / "; seek.toolTip += player.currentMedia.DurationString; } function updateVolToolTip(id) { vol = ""; vol += player.settings.volume; eval(id + ".toolTip = vol" ); } function updateShuffRep() { if(player.settings.getMode('shuffle')) { shuffleButton.down = true; }else{ shuffleButton.down = false; } if(player.settings.getMode('loop')) { repeatButton.down = true; }else{ repeatButton.down = false; } } // function volKey(event) { switch(event.keycode) { case 39: case 38: if(player.settings.volume < 95) { player.settings.volume+=5; }else{ player.settings.volume = 100; } break; case 37: case 40: if(player.settings.volume > 5) { player.settings.volume-=5; }else{ player.settings.volume = 0; } break; } player.settings.mute = false; } function seekKey(event) { switch(event.keycode) { case 37: case 40: if(player.controls.currentPosition > 10) { player.controls.currentPosition-=10; }else{ player.controls.currentPosition = 0; } break; case 39: case 38: if(player.controls.currentPosition < player.currentMedia.duration) { player.controls.currentPosition+=10; }else{ player.controls.currentPosition = player.currentMedia.duration; } break; } } // view toggle function toggleView(name,id) { if("true"==theme.loadPreference(id)) { theme.savePreference(id, "false"); theme.closeView( name ); }else{ sampleAlpha(); theme.openView( name ); } } function closeView(id) { theme.savePreference(id, "false"); if( id=="vidViewer" ) { player.controls.stop(); //theme.savePreference("vidCheck", "false"); theme.savePreference("vidViewer", "false"); } view.close(); } function autoSizeView(width,height) { var viewSize = theme.loadPreference( width ); if( "--" != viewSize ) { view.width = viewSize; }else{ view.width = view.minWidth; } viewSize = theme.loadpreference( height ); if( "--" != viewSize ) { view.height = viewSize; }else{ view.height = view.minHeight; } } function saveViewSize(width,height) { theme.savepreference( width , view.width ); theme.savepreference( height , view.height ); } // preferences function loadMainPrefs(){ htcpStartup(); sampleAlpha(); if ("true"==theme.loadPreference("plViewer")) { theme.openView( 'plView' ); } if ("true"==theme.loadPreference("eqViewer")) { theme.openView( 'eqView' ); } if ("true"==theme.loadPreference("visViewer")) { theme.openView( 'visView' ); } if ("true"==theme.loadPreference("infoViewer")) { theme.openView( 'infoView' ); } if("true"===theme.loadPreference('htcpMsg')) { theme.openView( 'msgView' ); } var _seekStatus = theme.loadPreference('seekStatus'); if (_seekStatus != '--') { seekStatus = (_seekStatus.toLowerCase() == 'true') ? false : true; } else { seekStatus = true; } SetTimeShowState(); } function saveMainPrefs() { theme.savePreference('seekStatus',seekStatus); } function mainShutDown() { saveMainPrefs(); } /* Hyper-Transient Color PhasingÖ (HTCP) Hyper-Transient Color Phasing is a trademark of The Skins Factory, Inc. Patent Pending. All scripts related to Hyper-Transient Color Phasing are Copyright ⌐ 2003. The Skins Factory, Inc. All Rights Reserved. Private use only. Sale, duplication, or other transfer of this material is strictly prohibited. */ function blendFrameFast(win, num, blend) { for(x=1; x<9; x++) { eval( win + x + "_" + num + ".alphaBlend = '" + blend + "';" ); } } function blendFrameSlow(win, num, blend, speed) { for(x=1; x<9; x++) { eval( win + x + "_" + num + ".alphaBlendTo(" + blend + "," + speed + ");" ); } } function htcpSetMsg() { var val = theme.loadPreference('htcpMsg'); if(val=='--') { theme.savePreference('htcpMsg','true'); } } function htcpMsgToggle() { if("true"==theme.loadPreference("htcpMsg")){ theme.savePreference('htcpMsg', "false" ); msgButton.down = true; } else { theme.savePreference('htcpMsg', "true" ); msgButton.down = false; } } function htcpSetTimerStatus() { var val = theme.loadPreference('htcpTimerStatus'); if(val=='--') { theme.savePreference('htcpTimerStatus',"true"); } } function htcpSetTimer() { var val = theme.loadPreference('htcpTimer'); if(val=='--') { theme.savePreference('htcpTimer',1500); theme.savePreference('htcpViewTimer',10000); } } function htcpSetID() { var val = theme.loadPreference('htcpID'); if(val=='--') { theme.savePreference('htcpID','8'); } } function htcpSliderUpdate() { htcpAdjust.min = 4000; alphaInt = htcpAdjust.value; //alphaInt = parseInt(alphaInt/1); theme.savePreference('htcpViewTimer', alphaInt ); htcpAdjust.toolTip = parseInt(alphaInt/1000); if(htcpAdjust.toolTip==1) { htcpAdjust.toolTip += aTip.toolTip; }else{ htcpAdjust.toolTip += aTips.toolTip; } htcpValue.value = htcpAdjust.toolTip; } function htcpTimerPause() { if("true"==theme.loadPreference("htcpTimerStatus")){ theme.savePreference('htcpTimerStatus', "false" ); htcpValue.value = htcpPause.toolTip; htcpAdjust.toolTip = htcp2.toolTip; htcpAdjust.enabled = false; } else { theme.savePreference('htcpTimerStatus', "true" ); htcpAdjust.enabled = true; htcpSliderUpdate(); htcpAdjust.toolTip = htcp1.toolTip; } } var mainStatus = 1; var htcpStatus = 0; function htcpStartup() { var mainColor = theme.loadPreference('htcpID'); if(mainColor==1) { mainBack2.alphaBlend = 255; mainStatus = 1; htcpStatus = 0; wipeAnim.backgroundImage = "m_wipe_1.gif"; spinnerAnim.backgroundImage = "spinner_open_2.gif"; link1.visible = true; } else if(mainColor==2) { mainBack3.alphaBlend = 255; mainStatus = 2; htcpStatus = 1; wipeAnim.backgroundImage = "m_wipe_2.gif"; spinnerAnim.backgroundImage = "spinner_open_3.gif"; link2.visible = true; } else if(mainColor==3) { mainBack3.alphaBlend = 255; mainBack4.alphaBlend = 255; mainStatus = 3; htcpStatus = 2; wipeAnim.backgroundImage = "m_wipe_3.gif"; spinnerAnim.backgroundImage = "spinner_open_4.gif"; link3.visible = true; } else if(mainColor==4) { mainBack5.alphaBlend = 255; mainStatus = 4; htcpStatus = 3; wipeAnim.backgroundImage = "m_wipe_4.gif"; spinnerAnim.backgroundImage = "spinner_open_5.gif"; link4.visible = true; } else if(mainColor==5) { mainBack6.alphaBlend = 255; mainStatus = 5; htcpStatus = 4; wipeAnim.backgroundImage = "m_wipe_5.gif"; spinnerAnim.backgroundImage = "spinner_open_6.gif"; link5.visible = true; } else if(mainColor==6) { mainBack7.alphaBlend = 255; mainStatus = 6; htcpStatus = 5; wipeAnim.backgroundImage = "m_wipe_6.gif"; spinnerAnim.backgroundImage = "spinner_open_7.gif"; link6.visible = true; } else if(mainColor==7) { mainBack8.alphaBlend = 255; mainStatus = 7; htcpStatus = 6; wipeAnim.backgroundImage = "m_wipe_7.gif"; spinnerAnim.backgroundImage = "spinner_open_8.gif"; link7.visible = true; } else if(mainColor==8) { wipeAnim.backgroundImage = "m_wipe_8.gif"; spinnerAnim.backgroundImage = "spinner_open_1.gif"; //mainBack8.alphaBlend = 255; mainStatus = 8; htcpStatus = 7; } } function htcpMain() { var mainTimer = theme.loadPreference('htcpTimer'); if("true"==theme.loadPreference('htcpTimerStatus')) { hideLinks(); if(mainStatus==1&&htcpStatus==0) { mainBack2.alphaBlendTo(255,mainTimer); mainStatus++ theme.savePreference('htcpID','1'); wipeAnim.backgroundImage = "m_wipe_1.gif"; } else if(mainStatus==2&&htcpStatus==1) { mainBack3.alphaBlendTo(255,mainTimer); mainStatus++ theme.savePreference('htcpID','2'); wipeAnim.backgroundImage = "m_wipe_2.gif"; } else if(mainStatus==3&&htcpStatus==2) { mainBack4.alphaBlendTo(255,mainTimer); mainStatus++ theme.savePreference('htcpID','3'); wipeAnim.backgroundImage = "m_wipe_3.gif"; } else if(mainStatus==4&&htcpStatus==3) { mainBack5.alphaBlendTo(255,mainTimer); mainStatus++ theme.savePreference('htcpID','4'); wipeAnim.backgroundImage = "m_wipe_4.gif"; } else if(mainStatus==5&&htcpStatus==4) { mainBack6.alphaBlendTo(255,mainTimer); mainStatus++ theme.savePreference('htcpID','5'); wipeAnim.backgroundImage = "m_wipe_5.gif"; } else if(mainStatus==6&&htcpStatus==5) { mainBack7.alphaBlendTo(255,mainTimer); mainStatus++ theme.savePreference('htcpID','6'); wipeAnim.backgroundImage = "m_wipe_6.gif"; } else if(mainStatus==7&&htcpStatus==6) { mainBack8.alphaBlendTo(255,mainTimer); mainStatus++ theme.savePreference('htcpID','7'); wipeAnim.backgroundImage = "m_wipe_7.gif"; } else if(mainStatus==8&&htcpStatus==7) { mainBack8.alphaBlendTo(0,mainTimer); mainStatus = 1; theme.savePreference('htcpID','8'); wipeAnim.backgroundImage = "m_wipe_8.gif"; mainBack2.alphaBlend = 0; mainBack3.alphaBlend = 0; mainBack4.alphaBlend = 0; mainBack5.alphaBlend = 0; mainBack6.alphaBlend = 0; mainBack7.alphaBlend = 0; } var viewTimer = theme.loadPreference('htcpViewTimer'); view.timerInterval = (Math.round(viewTimer)) + (Math.round(mainTimer)); }else{ view.timerInterval = 500; } } function htcpCheck() { htcpStatus++ if(htcpStatus==8) { htcpStatus = 0; } eval("spinnerAnim.backgroundImage='spinner_spin_" + htcpStatus + ".gif'"); eval("link" + htcpStatus + ".visible = 'true'"); } function hideLinks() { for (x = 1; x<8 ; x++) { eval("link" + x + ".visible = 'false'"); } } function sampleAlpha() { var htcpAlpha = theme.loadPreference('htcpID'); if(htcpAlpha==1) { htcpOpac = mainBack2.alphaBlend; theme.savePreference('winAlpha',htcpOpac); } else if(htcpAlpha==2) { htcpOpac = mainBack3.alphaBlend; theme.savePreference('winAlpha',htcpOpac); } else if(htcpAlpha==3) { htcpOpac = mainBack4.alphaBlend; theme.savePreference('winAlpha',htcpOpac); } else if(htcpAlpha==4) { htcpOpac = mainBack5.alphaBlend; theme.savePreference('winAlpha',htcpOpac); } else if(htcpAlpha==5) { htcpOpac = mainBack6.alphaBlend; theme.savePreference('winAlpha',htcpOpac); } else if(htcpAlpha==6) { htcpOpac = mainBack7.alphaBlend; theme.savePreference('winAlpha',htcpOpac); } else if(htcpAlpha==7) { htcpOpac = mainBack8.alphaBlend; theme.savePreference('winAlpha',htcpOpac); } else if(htcpAlpha==8) { htcpOpac = mainBack8.alphaBlend; theme.savePreference('winAlpha',htcpOpac); } } var plStatus = 1; function htcpStartupPl() { var htcpAlpha = theme.loadPreference('htcpID'); var winColor = theme.loadPreference('winAlpha'); if(htcpAlpha==1) { blendFrameFast('pl',2,winColor); plStatus = 0; } else if(htcpAlpha==2) { blendFrameFast('pl',2,255); blendFrameFast('pl',3,winColor); plStatus = 1; } else if(htcpAlpha==3) { blendFrameFast('pl',2,255); blendFrameFast('pl',3,255); blendFrameFast('pl',4,winColor); plStatus = 2; } else if(htcpAlpha==4) { blendFrameFast('pl',3,255); blendFrameFast('pl',4,255); blendFrameFast('pl',5,winColor); plStatus = 3; } else if(htcpAlpha==5) { blendFrameFast('pl',4,255); blendFrameFast('pl',5,255); blendFrameFast('pl',6,winColor); plStatus = 4; } else if(htcpAlpha==6) { blendFrameFast('pl',5,255); blendFrameFast('pl',6,255); blendFrameFast('pl',7,winColor); plStatus = 5; } else if(htcpAlpha==7) { blendFrameFast('pl',6,255); blendFrameFast('pl',7,255); blendFrameFast('pl',8,winColor); plStatus = 6; } else if(htcpAlpha==8) { blendFrameFast('pl',8,winColor); plStatus = 7; } htcpPl(); } function htcpPl() { var winTimer = theme.loadPreference('htcpTimer'); var htcpAlpha = theme.loadPreference('htcpID'); if(htcpAlpha==1&&plStatus==0) { blendFrameSlow('pl',2,255,winTimer); plStatus++; } else if(htcpAlpha==2&&plStatus==1) { blendFrameFast('pl',2,255); blendFrameSlow('pl',3,255,winTimer); plStatus++; } else if(htcpAlpha==3&&plStatus==2) { blendFrameFast('pl',3,255); blendFrameSlow('pl',4,255,winTimer); plStatus++; } else if(htcpAlpha==4&&plStatus==3) { blendFrameFast('pl',4,255); blendFrameSlow('pl',5,255,winTimer); plStatus++; } else if(htcpAlpha==5&&plStatus==4) { blendFrameFast('pl',5,255); blendFrameSlow('pl',6,255,winTimer); plStatus++; } else if(htcpAlpha==6&&plStatus==5) { blendFrameFast('pl',6,255); blendFrameSlow('pl',7,255,winTimer); plStatus++; } else if(htcpAlpha==7&&plStatus==6) { blendFrameFast('pl',7,255); blendFrameSlow('pl',8,255,winTimer); plStatus++; } else if(htcpAlpha==8&&plStatus==7) { blendFrameSlow('pl',8,0,winTimer); plStatus = 0; blendFrameFast('pl',2,0); blendFrameFast('pl',3,0); blendFrameFast('pl',4,0); blendFrameFast('pl',5,0); blendFrameFast('pl',6,0); blendFrameFast('pl',7,0); } } var eqStatus = 1; function htcpStartupEq() { var htcpAlpha = theme.loadPreference('htcpID'); var winColor = theme.loadPreference('winAlpha'); if(htcpAlpha==1) { blendFrameFast('eq',2,winColor); eqStatus = 0; } else if(htcpAlpha==2) { blendFrameFast('eq',2,255); blendFrameFast('eq',3,winColor); eqStatus = 1; } else if(htcpAlpha==3) { blendFrameFast('eq',3,255); blendFrameFast('eq',4,winColor); eqStatus = 2; } else if(htcpAlpha==4) { blendFrameFast('eq',4,255); blendFrameFast('eq',5,winColor); eqStatus = 3; } else if(htcpAlpha==5) { blendFrameFast('eq',5,255); blendFrameFast('eq',6,winColor); eqStatus = 4; } else if(htcpAlpha==6) { blendFrameFast('eq',6,255); blendFrameFast('eq',7,winColor); eqStatus = 5; } else if(htcpAlpha==7) { blendFrameFast('eq',7,255); blendFrameFast('eq',8,winColor); eqStatus = 6; } else if(htcpAlpha==8) { blendFrameFast('eq',8,winColor); eqStatus = 7; } htcpEq(); } function htcpEq() { var winTimer = theme.loadPreference('htcpTimer'); var htcpAlpha = theme.loadPreference('htcpID'); if(htcpAlpha==1&&eqStatus==0) { blendFrameSlow('eq',2,255,winTimer); eqStatus++; } else if(htcpAlpha==2&&eqStatus==1) { blendFrameSlow('eq',3,255,winTimer); eqStatus++; } else if(htcpAlpha==3&&eqStatus==2) { blendFrameSlow('eq',4,255,winTimer); eqStatus++; } else if(htcpAlpha==4&&eqStatus==3) { blendFrameSlow('eq',5,255,winTimer); eqStatus++; } else if(htcpAlpha==5&&eqStatus==4) { blendFrameSlow('eq',6,255,winTimer); eqStatus++; } else if(htcpAlpha==6&&eqStatus==5) { blendFrameSlow('eq',7,255,winTimer); eqStatus++; } else if(htcpAlpha==7&&eqStatus==6) { blendFrameSlow('eq',8,255,winTimer); eqStatus++; } else if(htcpAlpha==8&&eqStatus==7) { blendFrameSlow('eq',8,0,winTimer); eqStatus = 0; blendFrameFast('eq',2,0); blendFrameFast('eq',3,0); blendFrameFast('eq',4,0); blendFrameFast('eq',5,0); blendFrameFast('eq',6,0); blendFrameFast('eq',7,0); } } var visStatus = 1; function htcpStartupVis() { var htcpAlpha = theme.loadPreference('htcpID'); var winColor = theme.loadPreference('winAlpha'); if(htcpAlpha==1) { blendFrameFast('vis',2,winColor); visDrawer2.alphaBlend = winColor; visDrawerCover2.alphaBlend = winColor; visStatus = 0; } else if(htcpAlpha==2) { blendFrameFast('vis',2,255); blendFrameFast('vis',3,winColor); visDrawer2.alphaBlend = 255; visDrawer3.alphaBlend = winColor; visDrawerCover2.alphaBlend = 255; visDrawerCover3.alphaBlend = winColor; visStatus = 1; } else if(htcpAlpha==3) { blendFrameFast('vis',2,255); blendFrameFast('vis',3,255); blendFrameFast('vis',4,winColor); visDrawer2.alphaBlend = 255; visDrawer3.alphaBlend = 255; visDrawer4.alphaBlend = winColor; visDrawerCover3.alphaBlend = 255; visDrawerCover4.alphaBlend = winColor; visStatus = 2; } else if(htcpAlpha==4) { blendFrameFast('vis',3,255); blendFrameFast('vis',4,255); blendFrameFast('vis',5,winColor); visDrawer4.alphaBlend = 255; visDrawer5.alphaBlend = winColor; visDrawerCover4.alphaBlend = 255; visDrawerCover5.alphaBlend = winColor; visStatus = 3; } else if(htcpAlpha==5) { blendFrameFast('vis',4,255); blendFrameFast('vis',5,255); blendFrameFast('vis',6,winColor); visDrawer4.alphaBlend = 255; visDrawer5.alphaBlend = 255; visDrawer6.alphaBlend = winColor; visDrawerCover5.alphaBlend = 255; visDrawerCover6.alphaBlend = winColor; visStatus = 4; } else if(htcpAlpha==6) { blendFrameFast('vis',5,255); blendFrameFast('vis',6,255); blendFrameFast('vis',7,winColor); visDrawer5.alphaBlend = 255; visDrawer6.alphaBlend = 255; visDrawer7.alphaBlend = winColor; visDrawerCover6.alphaBlend = 255; visDrawerCover7.alphaBlend = winColor; visStatus = 5; } else if(htcpAlpha==7) { blendFrameFast('vis',6,255); blendFrameFast('vis',7,255); blendFrameFast('vis',8,winColor); visDrawer6.alphaBlend = 255; visDrawer7.alphaBlend = 255; visDrawer8.alphaBlend = winColor; visDrawerCover7.alphaBlend = 255; visDrawerCover8.alphaBlend = winColor; visStatus = 6; } else if(htcpAlpha==8) { blendFrameFast('vis',8,winColor); visDrawer8.alphaBlend = winColor; visDrawerCover3.alphaBlend = winColor; visStatus = 7; } htcpVis(); } function htcpVis() { var winTimer = theme.loadPreference('htcpTimer'); var htcpAlpha = theme.loadPreference('htcpID'); if(htcpAlpha==1&&visStatus==0) { blendFrameSlow('vis',2,255,winTimer); visDrawer2.alphaBlendTo(255,winTimer); visDrawerCover2.alphaBlendTo(255,winTimer); visStatus++; } else if(htcpAlpha==2&&visStatus==1) { blendFrameFast('vis',2,255); blendFrameSlow('vis',3,255,winTimer); visDrawer3.alphaBlendTo(255,winTimer); visDrawerCover3.alphaBlendTo(255,winTimer); visStatus++; } else if(htcpAlpha==3&&visStatus==2) { blendFrameFast('vis',3,255); blendFrameSlow('vis',4,255,winTimer); visDrawer4.alphaBlendTo(255,winTimer); visDrawerCover4.alphaBlendTo(255,winTimer); visStatus++; } else if(htcpAlpha==4&&visStatus==3) { blendFrameFast('vis',4,255); blendFrameSlow('vis',5,255,winTimer); visDrawer5.alphaBlendTo(255,winTimer); visDrawerCover5.alphaBlendTo(255,winTimer); visStatus++; } else if(htcpAlpha==5&&visStatus==4) { blendFrameFast('vis',5,255); blendFrameSlow('vis',6,255,winTimer); visDrawer6.alphaBlendTo(255,winTimer); visDrawerCover6.alphaBlendTo(255,winTimer); visStatus++; } else if(htcpAlpha==6&&visStatus==5) { blendFrameFast('vis',6,255); blendFrameSlow('vis',7,255,winTimer); visDrawer7.alphaBlendTo(255,winTimer); visDrawerCover7.alphaBlendTo(255,winTimer); visStatus++; } else if(htcpAlpha==7&&visStatus==6) { blendFrameFast('vis',7,255); blendFrameSlow('vis',8,255,winTimer); visDrawer8.alphaBlendTo(255,winTimer); visDrawerCover8.alphaBlendTo(255,winTimer); visStatus++; } else if(htcpAlpha==8&&visStatus==7) { blendFrameSlow('vis',8,0,winTimer); visDrawer8.alphaBlendTo(0,winTimer); visDrawerCover8.alphaBlendTo(0,winTimer); visStatus = 0; blendFrameFast('vis',2,0); blendFrameFast('vis',3,0); blendFrameFast('vis',4,0); blendFrameFast('vis',5,0); blendFrameFast('vis',6,0); blendFrameFast('vis',7,0); visDrawer2.alphaBlend = 0; visDrawer3.alphaBlend = 0; visDrawer4.alphaBlend = 0; visDrawer5.alphaBlend = 0; visDrawer6.alphaBlend = 0; visDrawer7.alphaBlend = 0; visDrawerCover2.alphaBlend = 0; visDrawerCover3.alphaBlend = 0; visDrawerCover4.alphaBlend = 0; visDrawerCover5.alphaBlend = 0; visDrawerCover6.alphaBlend = 0; visDrawerCover7.alphaBlend = 0; } } var vidStatus = 1; function htcpStartupVid() { var htcpAlpha = theme.loadPreference('htcpID'); var winColor = theme.loadPreference('winAlpha'); if(htcpAlpha==1) { blendFrameFast('vid',2,winColor); vidDrawer2.alphaBlend = winColor; vidDrawerCover2.alphaBlend = winColor; vidStatus = 0; } else if(htcpAlpha==2) { blendFrameFast('vid',2,255); blendFrameFast('vid',3,winColor); vidDrawer2.alphaBlend = 255; vidDrawer3.alphaBlend = winColor; vidDrawerCover2.alphaBlend = 255; vidDrawerCover3.alphaBlend = winColor; vidStatus = 1; } else if(htcpAlpha==3) { blendFrameFast('vid',2,255); blendFrameFast('vid',3,255); blendFrameFast('vid',4,winColor); vidDrawer2.alphaBlend = 255; vidDrawer3.alphaBlend = 255; vidDrawer4.alphaBlend = winColor; vidDrawerCover3.alphaBlend = 255; vidDrawerCover4.alphaBlend = winColor; vidStatus = 2; } else if(htcpAlpha==4) { blendFrameFast('vid',3,255); blendFrameFast('vid',4,255); blendFrameFast('vid',5,winColor); vidDrawer3.alphaBlend = 255; vidDrawer4.alphaBlend = 255; vidDrawer5.alphaBlend = winColor; vidDrawerCover4.alphaBlend = 255; vidDrawerCover5.alphaBlend = winColor; vidStatus = 3; } else if(htcpAlpha==5) { blendFrameFast('vid',4,255); blendFrameFast('vid',5,255); blendFrameFast('vid',6,winColor); vidDrawer4.alphaBlend = 255; vidDrawer5.alphaBlend = 255; vidDrawer6.alphaBlend = winColor; vidDrawerCover5.alphaBlend = 255; vidDrawerCover6.alphaBlend = winColor; vidStatus = 4; } else if(htcpAlpha==6) { blendFrameFast('vid',5,255); blendFrameFast('vid',6,255); blendFrameFast('vid',7,winColor); vidDrawer5.alphaBlend = 255; vidDrawer6.alphaBlend = 255; vidDrawer7.alphaBlend = winColor; vidDrawerCover6.alphaBlend = 255; vidDrawerCover7.alphaBlend = winColor; vidStatus = 5; } else if(htcpAlpha==7) { blendFrameFast('vid',6,255); blendFrameFast('vid',7,255); blendFrameFast('vid',8,winColor); vidDrawer6.alphaBlend = 255; vidDrawer7.alphaBlend = 255; vidDrawer8.alphaBlend = winColor; vidDrawerCover7.alphaBlend = 255; vidDrawerCover8.alphaBlend = winColor; vidStatus = 6; } else if(htcpAlpha==8) { blendFrameFast('vid',8,winColor); vidDrawer8.alphaBlend = winColor; vidDrawerCover8.alphaBlend = winColor; vidStatus = 7; } htcpVid(); } function htcpVid() { var winTimer = theme.loadPreference('htcpTimer'); var htcpAlpha = theme.loadPreference('htcpID'); if(htcpAlpha==1&&vidStatus==0) { blendFrameSlow('vid',2,255,winTimer); vidDrawer2.alphaBlendTo(255,winTimer); vidDrawerCover2.alphaBlendTo(255,winTimer); vidStatus++; } else if(htcpAlpha==2&&vidStatus==1) { blendFrameFast('vid',2,255); blendFrameSlow('vid',3,255,winTimer); vidDrawer3.alphaBlendTo(255,winTimer); vidDrawerCover3.alphaBlendTo(255,winTimer); vidStatus++; } else if(htcpAlpha==3&&vidStatus==2) { blendFrameFast('vid',3,255); blendFrameSlow('vid',4,255,winTimer); vidDrawer4.alphaBlendTo(255,winTimer); vidDrawerCover4.alphaBlendTo(255,winTimer); vidStatus++; } else if(htcpAlpha==4&&vidStatus==3) { blendFrameFast('vid',4,255); blendFrameSlow('vid',5,255,winTimer); vidDrawer5.alphaBlendTo(255,winTimer); vidDrawerCover5.alphaBlendTo(255,winTimer); vidStatus++; } else if(htcpAlpha==5&&vidStatus==4) { blendFrameFast('vid',5,255); blendFrameSlow('vid',6,255,winTimer); vidDrawer6.alphaBlendTo(255,winTimer); vidDrawerCover6.alphaBlendTo(255,winTimer); vidStatus++; } else if(htcpAlpha==6&&vidStatus==5) { blendFrameFast('vid',6,255); blendFrameSlow('vid',7,255,winTimer); vidDrawer7.alphaBlendTo(255,winTimer); vidDrawerCover7.alphaBlendTo(255,winTimer); vidStatus++; } else if(htcpAlpha==7&&vidStatus==6) { blendFrameFast('vid',7,255); blendFrameSlow('vid',8,255,winTimer); vidDrawer8.alphaBlendTo(255,winTimer); vidDrawerCover8.alphaBlendTo(255,winTimer); vidStatus++; } else if(htcpAlpha==8&&vidStatus==7) { blendFrameSlow('vid',8,0,winTimer); vidDrawer8.alphaBlendTo(0,winTimer); vidDrawerCover8.alphaBlendTo(0,winTimer); vidStatus = 0; blendFrameFast('vid',2,0); blendFrameFast('vid',3,0); blendFrameFast('vid',4,0); blendFrameFast('vid',5,0); blendFrameFast('vid',6,0); blendFrameFast('vid',7,0); vidDrawer2.alphaBlend = 0; vidDrawer3.alphaBlend = 0; vidDrawer4.alphaBlend = 0; vidDrawer5.alphaBlend = 0; vidDrawer6.alphaBlend = 0; vidDrawer7.alphaBlend = 0; vidDrawerCover2.alphaBlend = 0; vidDrawerCover3.alphaBlend = 0; vidDrawerCover4.alphaBlend = 0; vidDrawerCover5.alphaBlend = 0; vidDrawerCover6.alphaBlend = 0; vidDrawerCover7.alphaBlend = 0; } } var msgStatus = 1; function htcpStartupMsg() { var htcpAlpha = theme.loadPreference('htcpID'); var winColor = theme.loadPreference('winAlpha'); if(htcpAlpha==1) { blendFrameFast('msg',2,winColor); msgStatus = 0; } else if(htcpAlpha==2) { blendFrameFast('msg',2,255); blendFrameFast('msg',3,winColor); msgStatus = 1; } else if(htcpAlpha==3) { blendFrameFast('msg',2,255); blendFrameFast('msg',3,255); blendFrameFast('msg',4,winColor); msgStatus = 2; } else if(htcpAlpha==4) { blendFrameFast('msg',3,255); blendFrameFast('msg',4,255); blendFrameFast('msg',5,winColor); msgStatus = 3; } else if(htcpAlpha==5) { blendFrameFast('msg',4,255); blendFrameFast('msg',5,255); blendFrameFast('msg',6,winColor); msgStatus = 4; } else if(htcpAlpha==6) { blendFrameFast('msg',5,255); blendFrameFast('msg',6,255); blendFrameFast('msg',7,winColor); msgStatus = 5; } else if(htcpAlpha==7) { blendFrameFast('msg',6,255); blendFrameFast('msg',7,255); blendFrameFast('msg',8,winColor); msgStatus = 6; } else if(htcpAlpha==8) { blendFrameFast('msg',8,winColor); msgStatus = 7; } htcpMsg(); } function htcpMsg() { var winTimer = theme.loadPreference('htcpTimer'); var htcpAlpha = theme.loadPreference('htcpID'); if(htcpAlpha==1&&msgStatus==0) { blendFrameSlow('msg',2,255,winTimer); msgStatus++; } else if(htcpAlpha==2&&msgStatus==1) { blendFrameSlow('msg',3,255,winTimer); msgStatus++; } else if(htcpAlpha==3&&msgStatus==2) { blendFrameSlow('msg',4,255,winTimer); msgStatus++; } else if(htcpAlpha==4&&msgStatus==3) { blendFrameSlow('msg',5,255,winTimer); msgStatus++; } else if(htcpAlpha==5&&msgStatus==4) { blendFrameSlow('msg',6,255,winTimer); msgStatus++; } else if(htcpAlpha==6&&msgStatus==5) { blendFrameSlow('msg',7,255,winTimer); msgStatus++; } else if(htcpAlpha==7&&msgStatus==6) { blendFrameSlow('msg',8,255,winTimer); msgStatus++; } else if(htcpAlpha==8&&msgStatus==7) { blendFrameSlow('msg',8,0,winTimer); msgStatus = 0; blendFrameFast('msg',2,0); blendFrameFast('msg',3,0); blendFrameFast('msg',4,0); blendFrameFast('msg',5,0); blendFrameFast('msg',6,0); blendFrameFast('msg',7,0); } } // playlist function loadPlPrefs() { theme.savePreference( 'plViewer', "true" ); autoSizeView('plWidth','plHeight'); var index = 0; playlist1.setColumnResizeMode( index++, "AutosizeData" ); playlist1.setColumnResizeMode( index++, "Stretches" ); playlist1.setColumnResizeMode( index++, "AutosizeHeader" ); playlist1.setColumnResizeMode( index++, "AutosizeHeader" ); playlist1.setColumnResizeMode( index++, "AutosizeHeader" ); playlist1.setColumnResizeMode( index++, "AutosizeHeader" ); htcpStartupPl(); //checkPlViewSize(); } function savePlPrefs(){ saveViewSize('plWidth','plHeight'); } // eq settings function loadEQPrefs(){ theme.savePreference( 'eqViewer', "true" ); htcpStartupEq(); var speaker = eq.speakerSize; eval("speakerText.image='speaker_" + speaker + ".png'"); } function toggleSpeaker(){ if(eq.speakerSize==2){ eq.speakerSize = -1; } eq.speakerSize++ var speaker = eq.speakerSize; eval("speakerText.image='speaker_" + speaker + ".png'"); } function toggleSkinFx(){ if("true"==theme.loadPreference("soundFX")){ theme.savePreference("soundFX", "false"); }else{ theme.savePreference("soundFX", "true"); } } function eqKey(event,level){ switch(event.keyCode){ case 38: // up case 39: eval("eq.gainLevel" + level + "++"); break; case 40: // down case 37: eval("eq.gainLevel" + level + "--"); break; } } function sliderKey(event,id,val) { switch(event.keyCode){ case 39: case 38: // up eval(id + "+=" + val); break; case 40: // down case 37: eval(id + "-=" + val); break; } } function updateBalToolTip(){ balance.toolTip = ""; balance.toolTip += player.settings.balance; } // visualizations function loadVisPrefs(){ theme.savePreference( 'visViewer', "true" ); visEffects.currentEffectType = mediacenter.effectType; visEffects.currentPreset = mediacenter.effectPreset; autoSizeView('visWidth','visHeight'); htcpStartupVis(); checkVisualsPlayerState(); htcpAdjust.value = theme.loadPreference('htcpViewTimer'); htcpSliderUpdate(); htcpAdjust.toolTip = htcp1.toolTip; if('false'==theme.loadPreference('htcpTimerStatus')) { htcpPauseButton.down= true; htcpValue.value = htcpPause.toolTip; htcpAdjust.enabled = false; htcpAdjust.toolTip = htcp2.toolTip; } var _visDrawerStatus = theme.loadPreference('visDrawerStatus'); if (_visDrawerStatus != '--') { visDrawerStatus = (_visDrawerStatus.toLowerCase() == 'true') ? false : true; } else { visDrawerStatus = true; } if('--'==theme.loadPreference('visDrawerStatus')) visDrawerStatus = false; toggleVisDrawer(); } function saveVisPrefs(){ mediacenter.effectType = visEffects.currentEffectType; mediacenter.effectPreset = visEffects.currentPreset; saveViewSize('visWidth','visHeight'); theme.savePreference('visDrawerStatus',visDrawerStatus); } function checkVisualsPlayerState(){ if (player){ switch (player.playState){ case 3: //playing //visMask.visible = true; break; } } if (!player.controls.isAvailable("Stop")) { //visMask.visible = false; } } visDrawerStatus = false; function toggleVisDrawer() { if(!visDrawerStatus) { visDrawer.moveTo(0,view.height-73,400); visDrawerStatus = !visDrawerStatus; visDrawerFrame.visible = true; visDrawerButton.down = true; } else { visDrawer.moveTo(0,view.height-123,400); visDrawerStatus = !visDrawerStatus; visDrawerButton.down = false; } } function checkVisDrawerFrame() { visDrawerStatus = visDrawerStatus; visDrawerFrame.visible = visDrawerStatus; } // video settings function loadVidPrefs() { theme.savePreference( 'vidViewer', "true" ); var _drawerStatus = theme.loadPreference('drawerStatus'); if (_drawerStatus != '--') { drawerStatus = (_drawerStatus.toLowerCase() == 'true') ? false : true; } else { drawerStatus = true; } checkSnapStatus(); checkVideoPlayerState(); htcpStartupVid(); updateZoomToolTip(); toggleVidDrawer(); } function saveVidPrefs() { theme.savePreference('drawerStatus',drawerStatus); } function loadVidSize() { var vidSizer = theme.loadPreference( "videoWidth" ); if( "--" != vidSizer ) { view.width = vidSizer; } vidSizer = theme.loadpreference( "videoHeight" ); if( "--" != vidSizer ) { view.height = vidSizer; } } function saveVidSize() { theme.savepreference( "videoWidth", view.width ); theme.savepreference( "videoHeight", view.height ); theme.savePreference("vidSnapper" , "false"); vidZoom.upToolTip = vidSetTip.toolTip; mediacenter.videoZoom = 50; } function videoZoom() { if("false"==theme.loadPreference("vidSnapper")) { mediacenter.videoZoom = 50; } if(mediacenter.videoZoom < 76){ mediacenter.videoZoom = 100; }else if(mediacenter.videoZoom <101){ mediacenter.videoZoom = 150; }else if(mediacenter.videoZoom < 156){ mediacenter.videoZoom = 200; }else{ mediacenter.videoZoom = 75; } SnapToVideo(); updateZoomToolTip(); } function updateZoomToolTip() { vidZoom.upToolTip = vidZoomIn.toolTip + mediacenter.videoZoom + vidZoomMid.toolTip; if(mediacenter.videoZoom < 76){ nextZoom = 100; }else if(mediacenter.videoZoom <101){ nextZoom = 150; }else if(mediacenter.videoZoom < 156){ nextZoom = 200; }else{ nextZoom = 75; } vidZoom.upToolTip += nextZoom + vidZoomOut.toolTip; if("false"==theme.loadPreference("vidSnapper")) { vidZoom.upToolTip = vidSetTip.toolTip; } } function SnapToVideo() { theme.savePreference("vidSnapper" , "true"); var zoom = mediacenter.videoZoom; var viewWidth = (player.currentMedia.imageSourceWidth * (zoom/100.00)); var viewHeight = (player.currentMedia.imageSourceHeight * (zoom/100.00)); view.width = viewWidth + 71; view.height = viewHeight + 227; } function checkSnapStatus() { if(player.openState!=13) return; if("false"==theme.loadPreference("vidSnapper")) { loadVidSize(); }else{ SnapToVideo(); } } function checkVideoPlayerState() { if (player) { switch (player.playState) { case 3: //playing theme.savePreference('htcpTimerStatus', "false" ); if(!player.currentMedia.ImageSourceWidth>0) { theme.savePreference('vidViewer', "false"); view.close(); break; } vidBack.visible = false; vidBack.alphaBlend = 0; videoFrame.visible = true; if(!player.fullScreen) { checkSnapStatus(); } break; } vidResize.enabled = true; vidZoom.enabled = true; } if (!player.controls.isAvailable("Stop")) { videoFrame.visible = false; vidResize.enabled = false; vidZoom.enabled = false; vidBack.visible = true; vidBack.alphaBlendTo(255,500); view.width = view.minWidth; view.height = 416; } } function toggleVidDrawer() { if(!drawerStatus) { vidDrawer.moveTo(0,view.height-131,400); vidDrawerFrame.visible = true; vidDrawerButton.down = true; drawerStatus = !drawerStatus; } else { vidDrawer.moveTo(0,view.height-239,400); drawerStatus = !drawerStatus; } } function checkVidDrawer() { drawerStatus = drawerStatus; vidDrawerFrame.visible = drawerStatus; } // message function loadMsgPrefs() { view.height = view.minHeight; htcpStartupMsg() }