
var disp=null;var disp_metadata=null;function SetupRegularElem(elem){elem=Element.extend(elem);elem.observe("mouseover",function(){elem.style.textDecoration="underline";});elem.observe("mouseout",function(){elem.style.textDecoration="";});}
document.observe("dom:loaded",function(){$$(".nav_button_inside a").each(function(a){var elem=a;SetupRegularElem(elem);var data=Element.select(elem.parentNode,".navdata")[0];if(data){var dat=data;data=[];Element.select(dat,"a").each(function(anchor){data.push([((anchor.innerText&&anchor.innerText!="")?anchor.innerText:anchor.textContent),anchor.href]);});}
if(data){var overMain=false;var overMenu=false;elem.observe("mouseover",function(){overMenu=true;if(disp){if(disp_metadata==elem.innerText||disp_metadata==elem.textContent)
return;document.body.removeChild(disp);disp=null;}
disp=Element.extend(document.createElement("div"));disp_metadata=elem.innerText;if(!disp_metadata||disp_metadata=="")
disp_metadata=elem.textContent;disp.style.position="absolute";disp.className="navmenu";var pos=Element.cumulativeOffset(elem.parentNode.parentNode);disp.style.top=pos.top+Element.getHeight(elem.parentNode.parentNode)+"px";disp.style.left=pos.left+"px";disp.style.margin="0px";disp.style.padding="0px";var wid=Element.getWidth(elem.parentNode.parentNode);disp.style.width=wid+"px";var buffer=document.createElement("span");buffer.style.font="normal normal bold 9pt/normal verdana";document.body.appendChild(buffer);data.each(function(datum){var itm=document.createElement("div");itm.className="nav_button_outside";itm.style.width="100%";itm.style.textAlign="left";var span=document.createElement("div");span.className="nav_button_inside";span.style.textAlign="left";var a=document.createElement("a");a.style.textAlign="left";a.href=datum[1];a.innerText=datum[0];a.textContent=datum[0];SetupRegularElem(a);span.appendChild(a);itm.appendChild(span);disp.appendChild(itm);buffer.innerText=datum[0];buffer.textContent=datum[0];wid=Math.max(wid,buffer.offsetWidth+10);});disp.observe("mouseover",function(){overMenu=true;});disp.observe("mouseout",function(){overMenu=false;setTimeout(function(){if(disp&&!(overMenu||overMain)){document.body.removeChild(disp);disp=null;}},100);});disp.style.width=wid+"px";disp.style.left=((pos.left+Element.getWidth(elem.parentNode.parentNode))-wid)+"px";document.body.appendChild(disp);document.body.removeChild(buffer);});elem.observe("mouseout",function(){overMain=false;setTimeout(function(){if(disp&&!(overMenu||overMain)){document.body.removeChild(disp);disp=null;}},100);});}else{elem.observe("mouseover",function(){if(disp){document.body.removeChild(disp);disp=null;}});}});});
