jQuery.extend(jQuery.expr[":"],{hover:"a==document.hoverElement"});jQuery(function(){jQuery(document.body).mouseover(function(A){document.hoverElement=A.target})});(function(F){var C={},L,O,Q,M,K=F.browser.msie&&/MSIE\s(5\.5|6\.)/.test(navigator.userAgent),B=false;F.tooltip={blocked:false,defaults:{delay:200,ddelay:0,showURL:true,extraClass:"",top:15,left:15,id:"tooltip"},block:function(){F.tooltip.blocked=!F.tooltip.blocked}};F.fn.extend({tooltip:function(R){R=F.extend({},F.tooltip.defaults,R);I(R);return this.each(function(){F.data(this,"tooltip-settings",R);this.tooltipText=this.title;F(this).removeAttr("title");this.alt=""}).hover(N,G).click(G)},fixPNG:K?function(){return this.each(function(){var R=F(this).css("backgroundImage");if(R.match(/^url\(["']?(.*\.png)["']?\)$/i)){R=RegExp.$1;F(this).css({backgroundImage:"none",filter:"progid:DXImageTransform.Microsoft.AlphaImageLoader(enabled=true, sizingMethod=crop, src='"+R+"')"}).each(function(){var S=F(this).css("position");if(S!="absolute"&&S!="relative"){F(this).css("position","relative")}})}})}:function(){return this},unfixPNG:K?function(){return this.each(function(){F(this).css({filter:"",backgroundImage:""})})}:function(){return this},hideWhenEmpty:function(){return this.each(function(){F(this)[F(this).html()?"show":"hide"]()})},url:function(){return this.attr("href")||this.attr("src")}});function I(R){if(C.parent){return }C.parent=F('<div id="'+R.id+'"><h3></h3><div class="body"></div><div class="url"></div></div>').appendTo(document.body).hide();if(F.fn.bgiframe){C.parent.bgiframe()}C.title=F("h3",C.parent);C.body=F("div.body",C.parent);C.url=F("div.url",C.parent)}function D(R){return F.data(R,"tooltip-settings")}function H(R){if(D(this).delay){Q=setTimeout(P,D(this).delay)}else{P()}B=!!D(this).track;F(document.body).bind("mousemove",E);E(R)}function N(){var T,S,R,U;if(F.tooltip.blocked||this==L||(!this.tooltipText&&!D(this).bodyHandler)){return }L=this;O=this.tooltipText;if(D(this).bodyHandler){C.title.hide();U=D(this).bodyHandler.call(this);if(U.nodeType||U.jquery){C.body.empty().append(U)}else{C.body.html(U)}C.body.show()}else{if(D(this).showBody){T=O.split(D(this).showBody);C.title.html(T.shift()).show();C.body.empty();for(S=0;R=T[S];S++){if(S>0){C.body.append("<br/>")}C.body.append(R)}C.body.hideWhenEmpty()}else{C.title.html(O).show();C.body.hide()}}if(D(this).showURL&&F(this).url()){C.url.html(F(this).url().replace("http://","")).show()}else{C.url.hide()}C.parent.addClass(D(this).extraClass);if(D(this).fixPNG){C.parent.fixPNG()}H.apply(this,arguments)}function P(){Q=null;C.parent.show();E()}function E(T){if(F.tooltip.blocked){return }if(!B&&C.parent.is(":visible")){F(document.body).unbind("mousemove",E)}if(L==null){F(document.body).unbind("mousemove",E);return }C.parent.removeClass("viewport-right").removeClass("viewport-bottom");var V=C.parent[0].offsetLeft,U=C.parent[0].offsetTop,R=J(),S=C.parent[0];if(T){V=T.pageX+D(L).left;U=T.pageY+D(L).top;C.parent.css({left:V+"px",top:U+"px"})}if(R.x+R.cx<S.offsetLeft+S.offsetWidth){V-=S.offsetWidth+20+D(L).left;C.parent.css({left:V+"px"}).addClass("viewport-right")}if(R.y+R.cy<S.offsetTop+S.offsetHeight){U-=S.offsetHeight+20+D(L).top;C.parent.css({top:U+"px"}).addClass("viewport-bottom")}}function J(){return{x:F(window).scrollLeft(),y:F(window).scrollTop(),cx:F(window).width(),cy:F(window).height()}}function A(){if((F("div#tooltip:hover").size()==1)||(F(":hover").parents("div#tooltip").size()==1)){F("div#tooltip").hover(function(){},function(){if(M){clearTimeout(M)}C.parent.hide()})}else{if(M){clearTimeout(M)}C.parent.hide()}}function G(R){if(F.tooltip.blocked){return }if(Q){clearTimeout(Q)}if(D(this).ddelay){M=setTimeout(A,D(this).ddelay)}else{A()}L=null;if(D(this).fixPNG){C.parent.unfixPNG()}}F.fn.Tooltip=F.fn.tooltip})(jQuery);