var menu=function(){var t=15,z=50,s=6,a;function dd(n){this.n=n;this.h=[];this.c=[]}
dd.prototype.init=function(p,c){a=c;var w=document.getElementById(p),s=w.getElementsByTagName('ul'),l=s.length,i=0;for(i;i<l;i++){var h=s[i].parentNode;this.h[i]=h;this.c[i]=s[i];h.onmouseover=new Function(this.n+'.st('+i+',true)');h.onmouseout=new Function(this.n+'.st('+i+')');}}
dd.prototype.st=function(x,f){var c=this.c[x],h=this.h[x],p=h.getElementsByTagName('a')[0];clearInterval(c.t);c.style.overflow='hidden';if(f){p.className+=' '+a;if(!c.mh){c.style.display='block';c.style.height='';c.mh=c.offsetHeight;c.style.height=0}
if(c.mh==c.offsetHeight){c.style.overflow='visible'}
else{c.style.zIndex=z;z++;c.t=setInterval(function(){sl(c,1)},t)}}else{p.className=p.className.replace(a,'');c.t=setInterval(function(){sl(c,-1)},t)}}
function sl(c,f){var h=c.offsetHeight;if((h<=0&&f!=1)||(h>=c.mh&&f==1)){if(f==1){c.style.filter='';c.style.opacity=1;c.style.overflow='visible'}
clearInterval(c.t);return}
var d=(f==1)?Math.ceil((c.mh-h)/s):Math.ceil(h/s),o=h/c.mh;c.style.opacity=o;c.style.filter='alpha(opacity='+(o*100)+')';c.style.height=h+(d*f)+'px'}
return{dd:dd}}();function simple_tooltip(target_items,name){$(target_items).each(function(i){$("body").append("<div class='"+name+"' id='"+name+i+"'><p>"+$(this).attr('title')+"</p></div>");var my_tooltip=$("#"+name+i);if($(this).attr("title")!=""&&$(this).attr("title")!="undefined"){$(this).removeAttr("title").mouseover(function(){my_tooltip.css({opacity:0.9,display:"none"}).fadeIn(400);}).mousemove(function(kmouse){var border_top=$(window).scrollTop();var border_right=$(window).width();var left_pos;var top_pos;var offset=20;if(border_right-(offset*2)>=my_tooltip.width()+kmouse.pageX){left_pos=kmouse.pageX+offset;}else{left_pos=border_right-my_tooltip.width()-offset;}
if(border_top+(offset*2)>=kmouse.pageY-my_tooltip.height()){top_pos=border_top+offset;}else{top_pos=kmouse.pageY-my_tooltip.height()-offset;}
my_tooltip.css({left:left_pos,top:top_pos});}).mouseout(function(){my_tooltip.css({left:"-9999px"});});}});}
(function(jQuery)
{jQuery.extend({noticeAdd:function(options)
{var defaults={inEffect:{opacity:'show'},inEffectDuration:600,stayTime:3000,text:'',stay:false,type:'notice'}
var options,noticeWrapAll,noticeItemOuter,noticeItemInner,noticeItemClose;options=jQuery.extend({},defaults,options);noticeWrapAll=(!jQuery('.notice-wrap').length)?jQuery('<div></div>').addClass('notice-wrap').appendTo('body'):jQuery('.notice-wrap');noticeItemOuter=jQuery('<div></div>').addClass('notice-item-wrapper');noticeItemInner=jQuery('<div></div>').hide().addClass('notice-item '+options.type).appendTo(noticeWrapAll).html('<p>'+options.text1+'</p><p>'+options.text2+'</p><p>'+options.text3+'</p>').animate(options.inEffect,options.inEffectDuration).wrap(noticeItemOuter);noticeItemClose=jQuery('<div></div>').addClass('notice-item-close').prependTo(noticeItemInner).html('x').click(function(){jQuery.noticeRemove(noticeItemInner)});if(navigator.userAgent.match(/MSIE 6/i))
{noticeWrapAll.css({top:document.documentElement.scrollTop});}
if(!options.stay)
{setTimeout(function()
{jQuery.noticeRemove(noticeItemInner);},options.stayTime);}},noticeRemove:function(obj)
{obj.animate({opacity:'0'},600,function()
{obj.parent().animate({height:'0px'},300,function()
{obj.parent().remove();});});}});})(jQuery);
