/* 
  ------------------------------------------------
  PopMenu Magic menu scripts
  Copyright (c) 2004 Project Seven Development
  www.projectseven.com
  
  Version: Alpha 532 -mxp version: 0.80
  ------------------------------------------------
*/
function P7_setPM(){ //v532 alpha by PVII-www.projectseven.com
 var i,d='',h="<sty"+"le type=\"text/css\">",tA=navigator.userAgent.toLowerCase();
 if(window.opera){if(tA.indexOf("opera 5")>-1 || tA.indexOf("opera 6")>-1){return;}}
 if(document.getElementById){for(i=1;i<20;i++){d+='ul ';
 h+="\n#p7PMnav "+d+"{position:absolute;left:-9000px;}html{height:100%;}body{height:100%;}";}
 document.write(h+"\n<"+"/sty"+"le>");}}P7_setPM();

function P7_initPM(){ //v532 alpha by PVII-www.projectseven.com
 var i,g,tD,tA,tU,pp,lvl,tn=navigator.userAgent.toLowerCase();
 if(window.opera){if(tn.indexOf("opera 5")>-1||tn.indexOf("opera 6")>-1){
 return;}}else if(!document.getElementById){return;}p7PMp=arguments;
 p7PMct= new Array;tD=document.getElementById('p7PMnav');if(tD){
 tA=tD.getElementsByTagName('A');for(i=0;i<tA.length;i++){tA[i].p7PMcl=p7PMct.length;
 p7PMct[p7PMct.length]=tA[i];g=tA[i].parentNode.getElementsByTagName("UL");
 tA[i].p7PMsub=(g)?g[0]:false;tA[i].onmouseover=function(){P7_PMtrig(this);};
 tA[i].onfocus=function(){P7_PMtrig(this);};if(tA[i].p7PMsub){pp=tA[i].parentNode;
 lvl=0;while(pp){if(pp.tagName&&pp.tagName=="UL"){lvl++;}pp=pp.parentNode;}
 tA[i].p7PMlv=lvl;}}tD.onmouseout=P7_PMclose;P7_PMopen();}
}

function P7_PMtrig(a){ //v530 alpha by PVII-www.projectseven.com
 var b,t;if(document.p7PMt){clearTimeout(document.p7PMt);}document.p7PMa=1;
 b=(a.p7PMsub)?'P7_PMshow(':'P7_PMtg(';t='document.p7PMt=setTimeout("'+b+a.p7PMcl+')",160)';
 eval (t);
}

function P7_PMshow(a,bp){ //v532 alpha by PVII-www.projectseven.com
 var u,lv,oft,ofr,uw,uh,pp,aw,ah,adj,mR,mT,wW=0,wH,w1,w2,w3,sct,pw,lc,pwv,xx=0,yy=0,wP=true;
 var iem=(navigator.appVersion.indexOf("MSIE 5")>-1)?true:false;
 var dce=document.documentElement,dby=document.body;document.p7PMa=1;if(!bp){
 P7_PMtg(a);}u=p7PMct[a].p7PMsub;if(u.p7pmax&&u.p7pmax==1){return;}u.p7pmax=1;
 lv=(p7PMp[0]==1&&p7PMct[a].p7PMlv==1)?true:false;
 p7PMct[a].className=p7PMct[a].className.replace("p7PMtrg","p7PMon");
 oft=parseInt(p7PMp[3]);ofr=parseInt(p7PMp[4]);uw=u.offsetWidth;uh=u.offsetHeight;
 pp=p7PMct[a];aw=pp.offsetWidth;ah=pp.offsetHeight;while(pp){xx+=(pp.offsetLeft)?pp.offsetLeft:0;
 yy+=(pp.offsetTop)?pp.offsetTop:0;if(window.opera||navigator.userAgent.indexOf("Safari")>-1){
 if(p7PMct[a].p7PMlv!=1&&pp.nodeName=="BODY"){yy-=(pp.offsetTop)?pp.offsetTop:0;}}pp=pp.offsetParent;}
 if(iem&&navigator.userAgent.indexOf("Mac")>-1){yy+=parseInt(dby.currentStyle.marginTop);}
 adj=parseInt((aw*ofr)/100);mR=(lv)?0:aw-adj;adj=parseInt((ah*oft)/100);mT=(lv)?0:(ah-adj)*-1;
 w3=dby.parentNode.scrollLeft;if(!w3){w3=dby.scrollLeft;}w3=(w3)?w3:0;if(dce&&dce.clientWidth){
 wW=dce.clientWidth+w3;}else if(dby){wW=dby.clientWidth+w3;}if(!wW){wW=0;wP=false;}
 wH=dby.clientHeight;if(dce&&dce.clientHeight){w1=dce.clientHeight;}if(w1&&w1<wH){
 wH=w1;}if(window.innerHeight){w2=window.innerHeight;}if(w2&&(w2<wH||!wH)){wH=w2;}
 sct=dby.parentNode.scrollTop;if(!sct){sct=dby.scrollTop;if(!sct){sct=window.scrollY?window.scrollY:0;}}
 pw=xx+mR+uw;if(pw>wW&&wP){mR=uw*-1;mR+=10;if(lv){mR=(wW-xx)-uw;}}lc=xx+mR;if(lc<0){mR=xx*-1;}
 pw=yy+uh+ah+mT-sct;pwv=wH-pw;if(pwv<0){mT+=pwv;}u.style.marginLeft=mR+'px';u.style.marginTop=mT+'px';
 if(p7PMp[2]==1){if(!iem){P7_PManim(a,20);}}u.className="p7PMshow";
}

function P7_PMhide(u){ //v532 alpha PVII-www.projectseven.com
 var i,tt,ua;u.p7pmax=0;
 u.className="p7PMhide";ua=u.parentNode.firstChild;
 ua.className=ua.className.replace("p7PMon","p7PMtrg");
}

function P7_PMtg(a,b){ //v532 alpha by PVII-www.projectseven.com
 var i,u,tA,tU,pp;tA=p7PMct[a];pp=tA.parentNode;while(pp){if(pp.tagName=="UL"){break;}
 pp=pp.parentNode;}if(pp){tU=pp.getElementsByTagName("UL");for(i=tU.length-1;i>-1;i--){
 if(b!=1&&tA.p7PMsub==tU[i]){continue;}else{P7_PMhide(tU[i]);}}}
}

function P7_PMclose(evt){ //v532 alpha by PVII-www.projectseven.com
 var pp,st,tS,m=true;evt=(evt)?evt:((event)?event:null);st=document.p7PMa;
 if(st!=-1){if(evt){tS=(evt.relatedTarget)?evt.relatedTarget:evt.toElement;
 if(tS){pp=tS.parentNode;while(pp){if(pp&&pp.id&&pp.id=="p7PMnav"){m=false;
 document.p7PMa=1;break;}pp=pp.parentNode;}}if(m){document.p7PMa=-1;
 if(document.p7PMt){clearTimeout(document.p7PMt);}
 document.p7PMt=setTimeout("P7_PMclr()",180);}}}
}

function P7_PMclr(){ //v532 alpha by PVII-www.projectseven.com
 var i,tU,tUU;document.p7PMa=-1;tU=document.getElementById('p7PMnav');
 if(tU){tUU=tU.getElementsByTagName("UL");if(tUU){
 for(i=tUU.length-1;i>-1;i--){P7_PMhide(tUU[i]);}}}
}

function P7_PManim(a,st){ //v532 alpha by PVII-www.projectseven.com
 var g=p7PMct[a].p7PMsub,sp=30,inc=20;st=(st>=100)?100:st;g.style.fontSize=st+"%";
 if(st<100){st+=inc;setTimeout("P7_PManim("+a+","+st+")",sp);}
}

function P7_PMmark(){document.p7PMop=arguments;}

function P7_PMopen(){ //v532 alpha by PVII-www.projectseven.com
 var i,x,tA,wH,m=false,mt = new Array(1,'','');if(document.p7PMop){mt=document.p7PMop;}
 tA=document.getElementById('p7PMnav').getElementsByTagName("A");wH=window.location.href;
 m_l:for(i=0;i<tA.length;i++){if(tA[i].href){if(mt[0]==1&&tA[i].href==wH){m=true;break;}
 if(mt[0]==2){if(tA[i].firstChild){if(tA[i].firstChild.nodeValue==mt[1]){m=true;break;}}}
 if(mt[0]==3 && tA[i].href.indexOf(mt[1])>-1){m=true;break;}if(mt[0]==4){
 for(x=1;x<mt.length;x+=2){if(wH.indexOf(mt[x])>-1){if(tA[i].firstChild&&tA[i].firstChild.data){
 if(tA[i].firstChild.data==mt[x+1]){m=true;break m_l;}}}}}}}if(m){pp=tA[i].parentNode;while(pp){
 if(pp.nodeName=="LI"){pp.firstChild.className="p7PMmark"+" "+pp.firstChild.className;}pp=pp.parentNode;}}
}
