<!--

function WA_dynmenuBg(DHHoI)
{
var iDVtQ=document.wa_global_menu_declaration[DHHoI]
WA_bg(iDVtQ.id,iDVtQ.root_lx,iDVtQ.root_ly,iDVtQ.root_corner,iDVtQ.root_border,iDVtQ.root_col_border,[iDVtQ.root_bg],false,0)
}
function over_menu_off(p_obj,id_menu)
{
DKMjb()
var TAGPt_menu_root=document.wa_root_obj_menu;
var TAGPt_current_menu=TAGPt_menu_root.search(id_menu)
var UmmmO=p_obj.offsetParent.offsetParent;
if(UmmmO)
{
var TAGPt_menu=UmmmO.TAGPt_menu
TAGPt_menu.bLWfh=TAGPt_current_menu
xqNRW(UmmmO.cur_menu)
wPhSk(p_obj,true)
}
}
function WA_dynmenu_onmouseover_off(p_obj,MAwSJ)
{
hide_menu();
var EuXdu=document.wa_global_menu_declaration[MAwSJ]
p_obj.obj_menu=new FEPXt(MAwSJ,EuXdu,null,0)
var TAGPt_menu=p_obj.obj_menu
document.wa_root_obj_menu=TAGPt_menu
wPhSk(p_obj,true)
}
function WA_dynmenu_onmouseout(p_obj)
{
clearTimeout(window.wa_dynmenu_timer);
window.wa_dynmenu_timer=wa_timeout("hide_menu()",1000);
wPhSk(p_obj,false)
}
function over_menu(p_obj,id_menu,CpRoQ)
{
var TAGPt_menu_root=document.wa_root_obj_menu;
var TAGPt_menu=TAGPt_menu_root.search(id_menu)
DKMjb()
var dyn_cont=document.getElementById('dynmenu-container');
var uFKkn=html_findPos(p_obj)
if(CpRoQ==false)
{
var jihxs=p_obj.offsetParent.offsetParent;
xqNRW(jihxs.cur_menu)
}
var x2=0;
var y2=uFKkn.y;
if(CpRoQ)
{
x2=CpRoQ.x
y2=CpRoQ.y
}
var par_menu=p_obj.offsetParent.offsetParent;
if(par_menu)
{
var fVEtE=par_menu.TAGPt_menu
if(fVEtE)
{
var uFKkn_par=fVEtE.axgjO
x2=uFKkn_par.x+fVEtE.dEKtK()-3
}
}

var EDieQ=(x2+TAGPt_menu.dEKtK()+40-getWindowScroll().x)-getWindowSize().width
if(EDieQ>0)
{
x2=x2-EDieQ 
}
var MENIr_dec=(y2+TAGPt_menu.lXaBT()+15-getWindowScroll().y)-getWindowSize().height
if(MENIr_dec>0)
{
y2=y2-MENIr_dec
y2=Math.max(0,y2)
}
var menu=document.getElementById(id_menu);
menu.TAGPt_menu=TAGPt_menu
TAGPt_menu.axgjO=new Point(x2,y2)
if(par_menu!=undefined)
{
REVlv(par_menu,menu)
}
html_SetVisibility(menu,true)
html_SetPosition(menu,x2,y2)
TAGPt_menu.aEbap()
wPhSk(p_obj,true)
}
function REVlv(tnHEm,UmmmO)
{
tnHEm.cur_menu=UmmmO
var fVEtE=tnHEm.TAGPt_menu
if(fVEtE)
{
fVEtE.bLWfh=UmmmO.TAGPt_menu
}
}
function WA_dynmenu_onmouseover(p_obj,DHHoI,bKWSc,CpRoQ)
{
var iDVtQ=document.wa_global_menu_declaration[DHHoI]
var id_menu="dynmenu-id-var"
var dyn_cont=document.getElementById('dynmenu-container');
var klknX=new Array();
for(var n=0;n<bKWSc.length-1;n++)
{
klknX.push(bKWSc[n])
}
var BcQET=bKWSc[bKWSc.length-1]
bKWSc=klknX 
p_obj.obj_menu=new FEPXt(id_menu,iDVtQ,bKWSc,null,BcQET)
var TAGPt_menu=p_obj.obj_menu
dyn_cont.innerHTML=TAGPt_menu.div_menu(true)
document.wa_root_obj_menu=TAGPt_menu
over_menu(p_obj,id_menu,CpRoQ)
}
function DKMjb()
{
clearTimeout(window.wa_dynmenu_timer);
window.wa_dynmenu_timer=false;
}
function CFkFB(iDVtQ,uFKkn)
{
var MENIr=0
for(var i=0;i<iDVtQ.root_sizes.length;i++)
{
var VHXOD=iDVtQ.root_sizes[i]
MENIr+=VHXOD
if(uFKkn<MENIr)
{
return i;
}
}
return iDVtQ.root_sizes.length;
}
function wPhSk(p_obj,b_over)
{
var DqTSC=p_obj.offsetParent.offsetParent
var TAGPt_menu=DqTSC.TAGPt_menu
var UlBHS_i_root=false;
if(!TAGPt_menu)
{
UlBHS_i_root=true;
TAGPt_menu=document.wa_root_obj_menu;
}
if(!TAGPt_menu) return;
var iDVtQ=TAGPt_menu.iDVtQ
var BZwpc;
var Zmfdp=false;
var OljYS=p_obj
var FCJFp=p_obj.getElementsByTagName("A")
if(FCJFp.length==1)
{
OljYS=FCJFp[0]
}
if(b_over)
{
BZwpc=(UlBHS_i_root)?iDVtQ.root_col_text_over:iDVtQ.sub_col_text_over
Zmfdp=(UlBHS_i_root)?iDVtQ.root_text_u_over:iDVtQ.sub_text_u_over
}
else
{
BZwpc=(UlBHS_i_root)?iDVtQ.root_col_text:iDVtQ.sub_col_text
Zmfdp=(UlBHS_i_root)?iDVtQ.root_text_u:iDVtQ.sub_text_u
}
OljYS.style.color=BZwpc
OljYS.style.textDecoration=(Zmfdp)?"underline":"none"
if(UlBHS_i_root)
{
WA_bg_menu(iDVtQ.id)
if(b_over)
{
var qbWSj=document.getElementById(iDVtQ.id)
if(!qbWSj)return;
var c=qbWSj.getContext('2d');
c.fillStyle=iDVtQ.root_col_bg_over
c.beginPath()
var uFKkn=html_findPos(p_obj)
var AOpsX=new Rect(0,0,0,0)
if(iDVtQ.root_vertical==false)
{
var tOgpW=html_findPos(DqTSC)
var OdLHT=CFkFB(iDVtQ,uFKkn.x-tOgpW.x+10) 
AOpsX.x=uFKkn.x-tOgpW.x
AOpsX.y=0
AOpsX.width=p_obj.offsetWidth
AOpsX.height=iDVtQ.root_ly
if(OdLHT==0)
{
AOpsX.x+=iDVtQ.root_corner
AOpsX.width-=iDVtQ.root_corner
}
if(OdLHT==iDVtQ.root_sizes.length)
{
AOpsX.width-=iDVtQ.root_corner
}
}
else
{
var tOgpW=html_findPos(DqTSC)
var ABdqP=(uFKkn.y-tOgpW.y)+p_obj.offsetHeight/2 
var MENIr=0;
AOpsX.x=0
AOpsX.width=p_obj.offsetWidth
for(var i=0;i<iDVtQ.root_sizes.length;i++)
{
var VHXOD=iDVtQ.root_sizes[i]
MENIr+=VHXOD
if(ABdqP<MENIr)
{
AOpsX.y=MENIr-VHXOD
AOpsX.height=VHXOD
break
}
}
if(AOpsX.height==0)
{
AOpsX.y=MENIr
AOpsX.height=iDVtQ.root_ly-MENIr
}
{
AOpsX.x+=iDVtQ.root_corner
AOpsX.width-=2*iDVtQ.root_corner
}
}
c.fillRect(AOpsX.x+1,AOpsX.y+1,AOpsX.width-2,AOpsX.height-2)
}
}
TAGPt_menu.uxSnK()
}
function FEPXt(id_menu,iDVtQ,bKWSc,XuHVs,GQWHJ)
{
this.toHtml=function()
{
return this.tuXrG.toHtml()
}
this.search=function(DHHoI)
{
if(this.FCJFp)
for(var i=0;i<this.FCJFp.length;i++)
{
var IVejg=this.FCJFp[i]
var GUgiK=IVejg.search(DHHoI)
if(GUgiK)return GUgiK;
}
if(this.MAwSJ==DHHoI)return this;
return false;
}
this.cqMhY=function()
{
this.tuXrG.registerDynamicCanvas()
}
this.uxSnK=function()
{
this.tuXrG.draw()
}
this.aEbap=function()
{
this.cqMhY() 
this.tuXrG.setRect(0,0,this.dEKtK(),this.lXaBT())
}
this.lXaBT=function()
{
return this.FCJFp.length*this.mJYdG_sub_menu
}
this.dEKtK=function()
{
var w2=150;
var UlBHS_hasChild=false;
if(!this.xZLXv)
{
var ZNLQr=w2;
for(var i=0;i<this.FCJFp.length;i++)
{
var dAoHO=this.FCJFp[i]
if(dAoHO.ptDkZ())UlBHS_hasChild=true
var DHHoI_sub_menu=(this.MAwSJ+"-submenu"+i)
var JecEv_menu=document.getElementById(DHHoI_sub_menu);
if(JecEv_menu)
{
if(isMSIE())
{
ZNLQr=Math.max(ZNLQr,JecEv_menu.clientWidth)
}
else
{
ZNLQr=Math.max(ZNLQr,JecEv_menu.offsetWidth)
}
}
}
if(isMSIE())
{

}
ZNLQr=(ZNLQr+6)
for(var i=0;i<this.FCJFp.length;i++)
{
var DHHoI_sub_menu=(this.MAwSJ+"-submenu"+i)
var JecEv_menu=document.getElementById(DHHoI_sub_menu);
if(JecEv_menu)
{
JecEv_menu.style.width=ZNLQr+"px";
}
}
if(UlBHS_hasChild)
{
ZNLQr+=10
}
if(this.IdiXX=="right")
{
ZNLQr+=4
}
this.xZLXv=ZNLQr
w2=ZNLQr 
var UmmmO=document.getElementById(this.MAwSJ);
UmmmO.style.width=ZNLQr+"px";
}
else
{
w2=this.xZLXv
}
return w2
}
this.ptDkZ=function()
{
return(this.nqmNX)?true:false;
}
this.div_menu=function(b_visible,FDMgo)
{
var param_menu=this.nqmNX
var design=this.iDVtQ;
if(FDMgo==undefined)FDMgo=0;
var VwlEo=this.VwlEo
var Pnlac="";
var oYsXV=400
if(isMSIE())
{
oYsXV=this.GQWHJ
}
Pnlac+="<div id=\""+this.MAwSJ+"\" ";
Pnlac+="style=\"";
if(b_visible==false)
{
Pnlac+="visibility:hidden;";
}
Pnlac+="position:absolute;";
Pnlac+="width:"+oYsXV+"px;";
Pnlac+="z-index:"+(FDMgo*10);
Pnlac+="\">";
Pnlac+=this.tuXrG.toHtml()
Pnlac+="<div style='position:absolute;left:0px;top:0px;";
Pnlac+="z-index:100;" 
Pnlac+="'>";
VwlEo+="position:relative;"
VwlEo+="height:"+this.mJYdG_sub_menu+"px;";
VwlEo+="line-height:"+this.mJYdG_sub_menu+"px;"
VwlEo+="cursor:"+this.mJYdG_sub_menu+"px;"
if(this.IdiXX=="center")
{
VwlEo+="text-align:center;";
}
else
{
VwlEo+="text-align:"+this.IdiXX+";";
VwlEo+="padding-"+this.IdiXX+":4px;";
}
this.FCJFp=new Array()
for(var i=0;i<param_menu.length;i++)
{
var DHHoI_sub_menu=this.MAwSJ+"-"+i
var o=param_menu[i];
var XuHVs=o[0]
var BcQET=XuHVs[3] 
this.FCJFp.push(new FEPXt(DHHoI_sub_menu,design,o[1],XuHVs,BcQET))
}
for(var i=0;i<param_menu.length;i++)
{
var dAoHO=this.FCJFp[i]
var info=dAoHO.XuHVs
var DXpYN=info[0] 
var AqhGH=info[1]
var PLiDd=info[2]
if(AqhGH.length>0)
{
Pnlac+="<a href='"+AqhGH+"' style='text-decoration:none;cursor:pointer;' ";
if(PLiDd.length>0)Pnlac+="target="+PLiDd;
Pnlac+=">";
}
Pnlac+="<div id='"+(this.MAwSJ+"-submenu"+i)+"' style='"+VwlEo+"' "
if(dAoHO.nqmNX)
{
Pnlac+="onmouseover=\u0022javascript:over_menu(this,'"+dAoHO.MAwSJ+"',false)\u0022 ";
}
else
{
Pnlac+="onmouseover=\u0022javascript:over_menu_off(this,'"+dAoHO.MAwSJ+"')\u0022 ";
}
Pnlac+="onmouseout=\u0022javascript:WA_dynmenu_onmouseout(this)\u0022 ";
Pnlac+=">";
Pnlac+=DXpYN;
Pnlac+="</div>";
if(AqhGH.length>0)
{
Pnlac+="</a>";
}
}
Pnlac+="</div>";
Pnlac+="</div>";
for(var i=0;i<param_menu.length;i++)
{
var dAoHO=this.FCJFp[i]
if(dAoHO.nqmNX)
{
Pnlac+=dAoHO.div_menu(false,FDMgo+1)
}
}
return Pnlac;
}

this.nqmNX=bKWSc
this.GQWHJ=GQWHJ
this.XuHVs=XuHVs
this.iDVtQ=iDVtQ
this.VHXOD_border=1
this.BZwpc_border=iDVtQ.sub_col_border
this.VwlEo=iDVtQ.sub_style_text
this.LJwaY=iDVtQ.sub_col_text
this.IdiXX=iDVtQ.sub_align_text
this.mJYdG_sub_menu=iDVtQ.sub_menu_height
this.MAwSJ=id_menu
this.tuXrG=new WA_GraphicElement(id_menu+"-bg",50,iDVtQ.sub_menu_shadow)
this.tuXrG.TAGPt_menu=this;
this.tuXrG.iDVtQ=iDVtQ;
this.tuXrG.draw=function()
{
var TAGPt=this.TAGPt_menu
var iDVtQ=this.iDVtQ
var WDiJT=this.rect().width
var vfBJG=this.rect().height
var qusNW=iDVtQ.sub_col_bg.col1
if(iDVtQ.sub_col_bg.has_gradient)
{
var QBljV=iDVtQ.sub_col_bg
var KmPXa=QBljV.pt1.x*WDiJT/100
var wVucM=QBljV.pt1.y*vfBJG/100
var GHrQf=QBljV.pt2.x*WDiJT/100
var sXthc=QBljV.pt2.y*vfBJG/100
qusNW="("+KmPXa+";"+wVucM+";"+GHrQf+";"+sXthc+";"+QBljV.col1+";"+QBljV.col2+")";
}
WA_bg(this.canvasId(),WDiJT,vfBJG,iDVtQ.sub_menu_corner,1,TAGPt.BZwpc_border,[qusNW],this.shadow(),0)
var el=document.getElementById(this.canvasId())
if(!el)return;
var c=el.getContext('2d');
c.fillStyle=TAGPt.LJwaY;
var w=TAGPt.dEKtK()
var h=TAGPt.mJYdG_sub_menu
var XwJrf=8
var ZhlVU=6
var jGUIf=Math.max(2,iDVtQ.sub_corner-2);
var mdUSw=0;
var ZNYGf=0;
if(this.shadow())
{
mdUSw+=6;
ZNYGf+=6;
}
var MENIr=ZNYGf+Math.round((h-XwJrf)/2);
var MFItB=mdUSw+w-ZhlVU-4;
c.shadowOffsetX=0;
c.shadowOffsetY=0;
c.shadowBlur=0;
for(var i=0;i<TAGPt.FCJFp.length;i++)
{
var JecEv=TAGPt.FCJFp[i]
if(TAGPt.bLWfh==JecEv) 
{
var GHrQf=MFItB-30
c.fillStyle=iDVtQ.sub_col_bg_over
c.beginPath()
c.fillRect(mdUSw+jGUIf/2,ZNYGf+jGUIf/2,w-jGUIf,TAGPt.mJYdG_sub_menu-jGUIf)
}
if(JecEv.ptDkZ())
{
c.fillStyle=TAGPt.LJwaY;
c.beginPath()
c.moveTo(MFItB,MENIr);
c.lineTo(MFItB+ZhlVU,MENIr+XwJrf/2);
c.lineTo(MFItB,MENIr+XwJrf);
c.lineTo(MFItB,MENIr);
c.fill()
}
ZNYGf+=TAGPt.mJYdG_sub_menu
MENIr+=TAGPt.mJYdG_sub_menu
}
}
}
function xqNRW(UmmmO)
{
if(UmmmO==undefined) return
if(UmmmO.cur_menu!=undefined)
{
xqNRW(UmmmO.cur_menu)
}
html_SetVisibility(UmmmO,false)
}
function hide_menu()
{
DKMjb()
var KeLhu=document.getElementById('dynmenu-container');
KeLhu.innerHTML=""
}

-->
