var ToolTips={current:null,timeout:null,element:null,attachBehavior:function(){links=document.getElementsByTagName("a");for(var a=0;a<links.length;a++){if(links[a].title){links[a].setAttribute("nicetitle",links[a].title);links[a].removeAttribute("title");addEvent(links[a],"mouseover",ToolTips.onMouseover);addEvent(links[a],"mouseout",ToolTips.out);addEvent(links[a],"focus",ToolTips.onFocus);addEvent(links[a],"blur",ToolTips.out)}}},onMouseover:function(a){if(typeof ToolTips=="undefined"){return}if(ToolTips.timeout){clearTimeout(ToolTips.timeout)}if(a.srcElement){ToolTips.element=a.srcElement}else{if(a.target){ToolTips.element=a.target}}var b=mousePos(a);ToolTips.timeout=setTimeout(function(){ToolTips.show(b)},300)},onFocus:function(a){if(typeof ToolTips=="undefined"){return}if(ToolTips.timeout){clearTimeout(ToolTips.timeout)}if(a.srcElement){ToolTips.element=a.srcElement}else{if(a.target){ToolTips.element=a.target}}var b=eltPos(ToolTips.element);ToolTips.timeout=setTimeout(function(){ToolTips.show(b)},300)},out:function(){if(typeof ToolTips=="undefined"){return}if(ToolTips.timeout){clearTimeout(ToolTips.timeout)}if(ToolTips.current){document.getElementsByTagName("body")[0].removeChild(ToolTips.current);ToolTips.current=null;var a=document.getElementById("iframe_tt");if(a!=null){a.style.display="none"}}},show:function(p){try{if(ToolTips.current){ToolTips.out()}var q=ToolTips.element;while(!q.getAttribute("nicetitle")&&q.nodeName.toLowerCase()!="body"){q=q.parentNode}var a=q.getAttribute("nicetitle");if(!a){return}var n=document.createElement("div");n.className="nicetitle";n.innerHTML=a;var m=100;var g=600;if(window.innerWidth){g=Math.min(g,window.innerWidth-20)}if(document.body&&document.body.scrollWidth){g=Math.min(g,document.body.scrollWidth-20)}var b=0;var t=a.replace(/<br ?\/>/g,"\n").split("\n");for(var k=0;k<t.length;++k){b=Math.max(b,t[k].length)}var f=b*7;var s=b*10;var r;if(f>m){r=f}else{if(m>s){r=s}else{r=m}}var c=p[0]+20,o=window.innerWidth||document.documentElement.clientWidth||document.body.offsetWidth,h=window.pageXOffset||document.documentElement.scrollLeft;if(o&&((c+r)>(o+h))){c=o-r-40+h}if(document.body.scrollWidth&&((c+r)>(document.body.scrollWidth+h))){c=document.body.scrollWidth-r-25+h}n.id="toolTip";n.style.left=c+"px";n.style.width=Math.min(r,g)+"px";n.style.top=(p[1]+10)+"px";n.style.display="";document.getElementsByTagName("body")[0].appendChild(n);ToolTips.current=n;if(typeof ToolTips_Option_Windowed_Controls!="undefined"){var j=document.getElementById("iframe_tt");if(j==null){j=document.createElement('<iframe src="javascript:false;" name="iframe_tt" id="iframe_tt" scrolling="no" frameborder="0" style="position:absolute;top:0;left:0;display:none"></iframe>');document.getElementsByTagName("body")[0].appendChild(j)}j.style.width=n.offsetWidth;j.style.height=n.offsetHeight;j.style.top=n.style.top;j.style.left=n.style.left;j.style.position="absolute";j.style.display="block";n.style.zIndex=100;j.style.zIndex=99}}catch(l){}}};function mousePos(a){return[a.pageX||(a.clientX+(document.documentElement.scrollLeft||document.body.scrollLeft)),a.pageY||(a.clientY+(document.documentElement.scrollTop||document.body.scrollTop))]}function eltPos(a){if(a.offsetParent){for(posX=0,posY=0;a.offsetParent;a=a.offsetParent){posX+=a.offsetLeft;posY+=a.offsetTop}return[posX,posY]}else{return[a.x,a.y]}}function addEvent(d,c,a){if(d.addEventListener){d.addEventListener(c,a,true);return true}else{if(d.attachEvent){var b=d.attachEvent("on"+c,a);EventCache.add(d,c,a);return b}else{return false}}}var EventCache=function(){var a=[];return{listEvents:a,add:function(c,e,d,b){a.push(arguments)},flush:function(){var b,c;for(b=a.length-1;b>=0;b=b-1){c=a[b];if(c[0].removeEventListener){c[0].removeEventListener(c[1],c[2],c[3])}if(c[1].substring(0,2)!="on"){c[1]="on"+c[1]}if(c[0].detachEvent){c[0].detachEvent(c[1],c[2])}c[0][c[1]]=null}}}}();if(document.createElement&&document.getElementsByTagName){addEvent(window,"load",ToolTips.attachBehavior);addEvent(window,"unload",ToolTips.out);addEvent(window,"unload",EventCache.flush)};