﻿Type.registerNamespace("Telerik.Web.UI");
Telerik.Web.UI.RadToolTipControllerClass=function(){this._tooltipToShow=null;
this._activeToolTip=null;
this._registerGlobalBodyEventHandlers()
};
Telerik.Web.UI.RadToolTipControllerClass.prototype={_registerGlobalBodyEventHandlers:function(){var c=Function.createDelegate(this,function(a){if(a.keyCode==27){if(this._activeToolTip&&!this._activeToolTip.isModal()){this._hideCurrentToolTipNoAnimation()
}}});
var d=Function.createDelegate(this,function(a){this._hideOnBodyClick(a)
});
Sys.Application.add_init(function(){$addHandler(document.body,"keydown",c);
$addHandler(document.body,"click",d)
});
Sys.Application.add_unload(function(){$removeHandler(document.body,"keydown",c);
$removeHandler(document.body,"click",d)
})
},_hideOnBodyClick:function(f){var d=false;
if(this._activeToolTip!=null&&!this._activeToolTip.isModal()){var e=this._activeToolTip;
if($telerik.isMouseOverElementEx(e._tableElement,f)){return
}d=this._activeToolTip._hideIfNotManualCloseOrFromCode()
}if(d){this._activeToolTip=null
}},_cancelLastShowRequest:function(){if(this._tooltipToShow){var b=this._tooltipToShow;
this._tooltipToShow=null;
b.cancelShowDelay()
}},_hideCurrentToolTipNoAnimation:function(){this._cancelLastShowRequest();
if(this._activeToolTip!=null){this._activeToolTip._hideNoAnimation()
}this._activeToolTip=null
},requestShow:function(c){this._cancelLastShowRequest();
var d=this._activeToolTip;
if(d==c){return
}else{if(d){d._hideIfNotManualCloseOrFromCode()
}}this._tooltipToShow=c
},cancelSpecificShowRequest:function(b){if(this._tooltipToShow==b){this._cancelLastShowRequest()
}},showTooltip:function(b){if(!b||b.isVisible()){return
}this._cancelLastShowRequest();
this.set_activeToolTip(b);
b.show()
},notifyToolTipClosed:function(b){if(this._activeToolTip==b){this._activeToolTip=null
}},set_activeToolTip:function(b){if(b!=this._activeToolTip){this._hideCurrentToolTipNoAnimation()
}this._activeToolTip=b
},get_activeToolTip:function(){return this._activeToolTip
},getInstance:function(){return this
}};
Telerik.Web.UI.RadToolTipControllerClass.registerClass("Telerik.Web.UI.RadToolTipControllerClass",null);
if(!Telerik.Web.UI.RadToolTipController){Telerik.Web.UI.RadToolTipController=new Telerik.Web.UI.RadToolTipControllerClass()
}Type.registerNamespace("Telerik.Web.UI");
Telerik.Web.UI.RadToolTip=function(b){Telerik.Web.UI.RadToolTip.initializeBase(this,[b]);
this._offsetX=0;
this._offsetY=6;
this._position=Telerik.Web.UI.ToolTipPosition.BottomCenter;
this._horizontalPosition=null;
this._verticalPosition=null;
this._targetControlID=null;
this._serverTargetControlID=null;
this._serverValue="";
this._formID=null;
this._targetControl=null;
this._popupElement=null;
this._tableElement=null;
this._contentCell=null;
this._titleElement=null;
this._contentElement=null;
this._calloutElement=null;
this._closeLink=null;
this._popupBehavior=null;
this._modal=false;
this._onModalShowHandler=null;
this._onModalCloseHandler=null;
this._skin="Default";
this._title="";
this._text="";
this._width="";
this._height="";
this._relativeTo=Telerik.Web.UI.ToolTipRelativeDisplay.Mouse;
this._contentScrolling=Telerik.Web.UI.ToolTipScrolling.Default;
this._showEvent=Telerik.Web.UI.ToolTipShowEvent.OnMouseOver;
this._hideEvent=Telerik.Web.UI.ToolTipHideEvent.Default;
this._visibleOnPageLoad=false;
this._sticky=false;
this._manualClose=false;
this._mouseTrailing=false;
this._showCallout=true;
this._renderInPageRoot=false;
this._showDelayRef=null;
this._autoCloseRef=null;
this._showDelay=400;
this._autoCloseDelay=3000;
this._hideDelay=300;
this._animation=Telerik.Web.UI.ToolTipAnimation.None;
this._tooltipAnimation=null;
this._zIndex=8000
};
Telerik.Web.UI.RadToolTip.getCurrent=function(){var b=Telerik.Web.UI.RadToolTipController.getInstance();
if(!b){return null
}return b.get_activeToolTip()
};
Telerik.Web.UI.RadToolTip.prototype={get_zIndex:function(){return this._zIndex
},set_zIndex:function(c){var d=parseInt(c);
if(isNaN(c)){return
}if(this._zIndex!=c){this._zIndex=c
}},initialize:function(){Telerik.Web.UI.RadToolTip.callBaseMethod(this,"initialize");
this.set_position(this._position);
var m=this.get_targetControl();
if(m!=null){var n=m.getAttribute("_rfddecoratedID");
if(n){this.set_targetControl($get(n))
}}var h=this.get_targetControlID();
var l=$get(h+"_text");
if(l&&h){var k=$find(h);
if(k&&Object.getType(k).inheritsFrom(Telerik.Web.UI.RadInputControl)){this.set_targetControlID(h+"_text")
}}var j=this.get_text();
if(this._targetControl&&!j){j=this._targetControl.getAttribute("title");
if(j){this._targetControl.removeAttribute("title")
}this._text=j
}var i=$telerik.getCurrentStyle(this.get_element(),"zIndex");
if(null!=i){this.set_zIndex(i)
}if(this._visibleOnPageLoad){setTimeout(Function.createDelegate(this,function(){this.show()
}),0)
}},dispose:function(){if(this._tooltipAnimation){this._tooltipAnimation.dispose()
}if(this._popupBehavior){this._popupBehavior.dispose();
this._popupBehavior=null
}this._registerPopupHandlers(false);
this._registerMouseHandlers(this._targetControl,false);
this._makeModal(false);
if(this._closeLinkHandler&&this._closeLink){$clearHandlers(this._closeLink);
this._closeLinkHandler=null
}if(this._popupElement){var d=this.get_id();
if(d){var c=$get(d);
if(c){c.appendChild(this._popupElement)
}}}Telerik.Web.UI.RadToolTip.callBaseMethod(this,"dispose")
},isCreated:function(){return this._popupElement!=null
},get_leaveTargetAndToolTip:function(){return this.isHideEventEnabled(Telerik.Web.UI.ToolTipHideEvent.LeaveTargetAndToolTip)
},isHideEventEnabled:function(b){return b&this._hideEvent
},hide:function(){this._hideUnconditionally()
},_hideIfNotManualCloseOrFromCode:function(){var c=this.isHideEventEnabled(Telerik.Web.UI.ToolTipHideEvent.FromCode);
var d=this.get_manualClose();
if(d||c){return false
}this._hideUnconditionally();
return true
},_hideUnconditionally:function(){if(!this.isVisible()){return
}this._hide()
},_hideNoAnimation:function(){this._hide(false)
},_hide:function(d){if(this._animation!=Telerik.Web.UI.ToolTipAnimation.None){$telerik.$(this._popupElement).stop()
}this.cancelHideDelay();
this.cancelShowDelay();
this.cancelAutoCloseDelay();
var f=new Sys.CancelEventArgs();
this.raiseEvent("beforeHide",f);
if(f.get_cancel()){return
}if(this._animation!=Telerik.Web.UI.ToolTipAnimation.None){this._calloutElement.style.display="none";
var e=Function.createDelegate(this,this._afterHide);
$telerik.$(this._popupElement).fadeOut(500,e)
}else{this._afterHide()
}},_afterHide:function(){try{if(this._popupBehavior){this._popupBehavior.hide();
this._popupBehavior.pin(false)
}}catch(b){}this._getToolTipController().notifyToolTipClosed(this);
this.raiseEvent("hide");
this._registerPopupHandlers(false)
},clone:function(d){var c=document.createElement("SPAN");
if(d){c.setAttribute("id",d)
}return $telerik.cloneControl(this,Telerik.Web.UI.RadToolTip,c)
},show:function(){this._createUI();
var b=new Sys.CancelEventArgs();
this.raiseEvent("beforeShow",b);
if(b.get_cancel()){return
}this._popupBehavior.pin(false);
window.setTimeout(Function.createDelegate(this,function(){this._getToolTipController().set_activeToolTip(this);
if(this._animation==Telerik.Web.UI.ToolTipAnimation.None){this._show();
this._afterShow()
}else{window.setTimeout(Function.createDelegate(this,function(){this._playAnimation()
}),500)
}}),0)
},updateLocation:function(){this._show()
},showLoadingMessage:function(e){var d=this._getFullSkinName();
var f="rtLoading";
if(e){Sys.UI.DomElement.addCssClass(this._contentCell,d);
Sys.UI.DomElement.addCssClass(this._contentCell,f)
}else{Sys.UI.DomElement.removeCssClass(this._contentCell,d);
Sys.UI.DomElement.removeCssClass(this._contentCell,f)
}},isModal:function(){return this._modal
},set_contentElement:function(b){this._contentCell.innerHTML="";
if(b.parentNode&&b.parentNode.removeChild){b.parentNode.removeChild(b)
}this._contentCell.appendChild(b);
b.style.display="";
this._contentElement=b;
this._setOverflow();
this.showLoadingMessage(false)
},get_contentElement:function(){return this._contentElement
},set_content:function(d){this._text=d;
if(this.isCreated()){var c=document.createElement("DIV");
c.innerHTML=d;
this.set_contentElement(c)
}},get_content:function(){return this._contentElement?this._contentElement.innerHTML:""
},cancelHideDelay:function(){if(this._hideDelayRef){window.clearTimeout(this._hideDelayRef);
this._hideDelayRef=0
}},cancelAutoCloseDelay:function(){if(this._autoCloseRef){window.clearTimeout(this._autoCloseRef);
this._autoCloseRef=0
}},cancelShowDelay:function(){if(this._showDelayRef){window.clearTimeout(this._showDelayRef);
this._showDelayRef=null
}this._getToolTipController().cancelSpecificShowRequest(this)
},_getToolTipController:function(){return Telerik.Web.UI.RadToolTipController.getInstance()
},_resetAutoCloseDelay:function(){this.cancelAutoCloseDelay();
if(this.get_manualClose()||this.get_sticky()){return
}if(this._autoCloseDelay){this._autoCloseRef=window.setTimeout(Function.createDelegate(this,function(){this._hideIfNotManualCloseOrFromCode()
}),this._autoCloseDelay)
}},_resetShowDelay:function(){this.cancelShowDelay();
var b=Function.createDelegate(this,function(){this._getToolTipController().showTooltip(this);
this.cancelShowDelay()
});
this._showDelayRef=window.setTimeout(b,this._showDelay)
},_resetHideDelay:function(){this.cancelHideDelay();
if(this._hideDelay>0){this._hideDelayRef=window.setTimeout(Function.createDelegate(this,function(){this._hideIfNotManualCloseOrFromCode()
}),this._hideDelay)
}else{this._hideIfNotManualCloseOrFromCode()
}},_show:function(){var d=null;
try{d=this.getToolTipBounds()
}catch(e){var f=this;
window.setTimeout(function(){f._addToolTipToDocument()
},10);
return
}this._setPopupVisible(d.x,d.y)
},_afterShow:function(){this._registerPopupHandlers(true);
this._popupBehavior.pin(this._isRelativeToBrowserWindow());
this._resetAutoCloseDelay();
this._adjustCallout();
this.raiseEvent("show")
},_isRelativeToBrowserWindow:function(){if(!this._targetControl||this._relativeTo==Telerik.Web.UI.ToolTipRelativeDisplay.BrowserWindow){return true
}return false
},_playAnimation:function(){if(this!=Telerik.Web.UI.RadToolTip.getCurrent()){return
}var l=Function.createDelegate(this,function(){var a=this.getToolTipBounds();
this._setPopupVisible(a.x,a.y);
var b=$telerik.getBounds(this._tableElement);
$telerik.$(this._popupElement).hide();
return b
});
var p=l();
var t=Function.createDelegate(this,function(){if(this._isRelativeToBrowserWindow()){this._documentOverflowX=document.documentElement.style.overflowX;
document.documentElement.style.overflowX="hidden"
}if(this.get_showCallout()&&this._calloutElement){this._calloutElement.style.display="none"
}});
var n=Function.createDelegate(this,function(){this._popupElement.style.filter="";
this.get_popupElement().style.opacity="";
if(this.get_showCallout()&&this._calloutElement){this._calloutElement.style.display=""
}this._show();
if(null!=this._documentOverflowX){document.documentElement.style.overflowX=this._documentOverflowX;
this._documentOverflowX=null
}this._afterShow()
});
var s=this._popupElement;
var q=this._animation;
var o=""+this._position;
var m=this._isRelativeToBrowserWindow();
if(m&&this._verticalPosition!=2){vp=(this._verticalPosition==1?3:1);
o=parseInt(vp+""+this._horizontalPosition)
}var r=m?document.documentElement:this._targetControl;
var k=r?$telerik.getBounds(r):new Sys.UI.Bounds(1,1,1,1);
window.setTimeout(function(){Telerik.Web.UI.Animations.playJQueryAnimation(s,q,k,p,o,t,n)
},0)
},_makeModal:function(b){if(this._onModalShowHandler){this.remove_show(this._onModalShowHandler);
this._onModalShowHandler=null
}if(this._onModalCloseHandler){this.remove_hide(this._onModalCloseHandler);
this._onModalCloseHandler=null
}if(this._modalExtender){this._modalExtender.dispose();
this._modalExtender=null
}if(!b){return
}this._onModalShowHandler=function(a){if(!a._modalExtender){a._modalExtender=new Telerik.Web.UI.ModalExtender(a._popupElement)
}a._modalExtender.show()
};
this.add_show(this._onModalShowHandler);
this._onModalCloseHandler=function(a){if(a._modalExtender){a._modalExtender.hide()
}};
this.add_hide(this._onModalCloseHandler)
},_onMouseOver:function(b){this._logMousePosition(b);
this._resetShowDelay();
this.cancelHideDelay();
this.cancelAutoCloseDelay();
this._getToolTipController().requestShow(this)
},_onMouseMove:function(b){this._logMousePosition(b);
this._resetAutoCloseDelay();
if(this._mouseTrailing&&this.isVisible()){this._show()
}},_onMouseOut:function(d){if(!this.isVisible()){this.cancelShowDelay();
return
}var c=$telerik.isMouseOverElementEx(this._targetControl,d);
if(!c){this.cancelShowDelay();
if(!this.get_sticky()){this._resetHideDelay()
}}},_onClick:function(b){this._onMouseOver(b);
return $telerik.cancelRawEvent(b)
},_onRightClick:function(b){this._onMouseOver(b);
return $telerik.cancelRawEvent(b)
},_registerMouseHandlers:function(k,p){if(true==p){var e={};
var n=Telerik.Web.UI.ToolTipShowEvent;
if(this._showEvent==n.OnMouseOver){this._onMouseOverDelegate=Function.createDelegate(this,this._onMouseOver);
this._onMouseMoveDelegate=Function.createDelegate(this,this._onMouseMove);
this._onMouseOutDelegate=Function.createDelegate(this,this._onMouseOut);
$telerik.addExternalHandler(k,"mouseover",this._onMouseOverDelegate);
$telerik.addExternalHandler(k,"mousemove",this._onMouseMoveDelegate);
$telerik.addExternalHandler(k,"mouseout",this._onMouseOutDelegate)
}if(this._showEvent==n.OnClick){this._onClickDelegate=Function.createDelegate(this,this._onClick);
$telerik.addExternalHandler(k,"click",this._onClickDelegate)
}if(this._showEvent==n.OnRightClick){this._onRightClickDelegate=Function.createDelegate(this,this._onRightClick);
$telerik.addExternalHandler(k,"contextmenu",this._onRightClickDelegate)
}if(this._showEvent==n.OnFocus){this._onFocusDelegate=Function.createDelegate(this,this._onMouseOver);
this._onBlurDelegate=Function.createDelegate(this,this._onMouseOut);
$telerik.addExternalHandler(k,"focus",this._onFocusDelegate);
$telerik.addExternalHandler(k,"blur",this._onBlurDelegate)
}}else{if(k){var l=[["mouseover",this._onMouseOverDelegate],["mousemove",this._onMouseMoveDelegate],["mouseout",this._onMouseOutDelegate],["click",this._onClickDelegate],["contextmenu",this._onRightClickDelegate],["focus",this._onFocusDelegate],["blur",this._onBlurDelegate]];
for(var i=0;
i<l.length;
i++){var m=l[i];
try{if(null!=m[1]){$telerik.removeExternalHandler(k,m[0],m[1])
}}catch(o){}}this._onMouseOverDelegate=null;
this._onMouseMoveDelegate=null;
this._onMouseOutDelegate=null;
this._onClickDelegate=null;
this._onRightClickDelegate=null;
this._onFocusDelegate=null;
this._onBlurDelegate=null
}}},_registerPopupHandlers:function(b){if(true==b){if(this.get_sticky()){this._popupStickyHandler=Function.createDelegate(this,this._onPopupStickyMouseOut);
$addHandler(this._tableElement,"mouseout",this._popupStickyHandler)
}else{if(this.get_leaveTargetAndToolTip()){this._popupEnterHandler=Function.createDelegate(this,this._onPopupEnterToolTip);
$addHandler(this._tableElement,"mouseover",this._popupEnterHandler);
this._popupLeaveHandler=Function.createDelegate(this,this._onPopupLeaveToolTip);
$addHandler(this._tableElement,"mouseout",this._popupLeaveHandler)
}}}else{if(this._popupStickyHandler||this._popupEnterHandler||this._popupLeaveHandler){$clearHandlers(this._tableElement);
this._popupStickyHandler=null;
this._popupEnterHandler=null;
this._popupLeaveHandler=null
}}},_onPopupStickyMouseOut:function(d){var c=$telerik.isMouseOverElementEx(this._tableElement,d);
if(!c){this._hideIfNotManualCloseOrFromCode()
}},_onPopupEnterToolTip:function(d){var c=$telerik.isMouseOverElementEx(this._tableElement,d);
if(c){this.cancelHideDelay();
this.cancelAutoCloseDelay()
}},_onPopupLeaveToolTip:function(d){var c=$telerik.isMouseOverElementEx(this._tableElement,d);
if(!c){this._resetHideDelay();
this._resetAutoCloseDelay()
}},_getPosRelativeToMouse:function(q){var o=q.x;
var n=q.y;
var p=this._getMousePosition();
var r=p.clientX;
var k=p.clientY;
var l=$telerik.standardsMode;
if(!$telerik.isIE&&document.compatMode!="CSS1Compat"){l=false
}else{if($telerik.isSafari){l=false
}}if(l){o-=$telerik.getCorrectScrollLeft(document.documentElement);
n-=document.documentElement.scrollTop
}else{o-=$telerik.getCorrectScrollLeft(document.body);
n-=document.body.scrollTop
}var m=r-o;
var j=k-n;
return{x:m,y:j}
},_logMousePosition:function(b){if(!b){return
}this._mouseX=b.clientX;
this._mouseY=b.clientY
},_getMousePosition:function(){var b={};
b.clientX=this._mouseX;
b.clientY=this._mouseY;
return b
},_getCalloutBounds:function(){var d={width:0,height:0,marginLeft:0,marginTop:0};
if(this._showCallout&&this._calloutElement){d.marginLeft=parseInt($telerik.getCurrentStyle(this._calloutElement,"marginLeft"));
d.marginTop=parseInt($telerik.getCurrentStyle(this._calloutElement,"marginTop"));
if(isNaN(d.marginLeft)){d.marginLeft=0
}if(isNaN(d.marginTop)){d.marginTop=0
}var c=$telerik.getBounds(this._calloutElement);
if(c){if(c.width){d.width=c.width
}if(c.height){d.height=c.height
}}}return d
},_getBoundsRelativeToBrowser:function(p,o,i){var k=this._horizontalPosition;
var j=this._verticalPosition;
var l=0;
var m=0;
if(!i){i=$telerik.getClientBounds()
}var n=$telerik.getScrollOffset(document.compatMode&&document.compatMode!="BackCompat"?document.documentElement:document.body);
if("fixed"!=this._popupElement.style.position){l+=n.x;
m+=n.y
}switch(k){case 2:l+=-parseInt(p.width/2-i.width/2);
l+=this._offsetX;
break;
case 3:l+=i.width;
l-=p.width;
l-=this._offsetX;
break;
case 1:default:l+=-p.width;
l+=(-o.width-o.marginLeft);
l+=this._offsetX;
break
}switch(j){case 2:m+=-parseInt((p.height-i.height)/2);
break;
case 1:m+=this._offsetY;
break;
case 3:default:m+=i.height;
m-=this._offsetY;
m-=p.height;
break
}return new Sys.UI.Bounds(l,m,p.width,p.height)
},_getBoundsRelativeToElement:function(k,h,j){var l=this._horizontalPosition;
var n=this._verticalPosition;
var i=0;
var m=0;
if(!j){j=$telerik.getBounds(this._targetControl)
}switch(l){case 2:i+=-parseInt(k.width/2-j.width/2);
i+=this._offsetX;
break;
case 3:i+=j.width;
i-=h.marginLeft;
i+=this._offsetX;
break;
case 1:default:i+=-k.width;
i+=(-h.width-h.marginLeft);
i-=this._offsetX;
break
}switch(n){case 2:m+=-parseInt(k.height/2-j.height/2);
m+=this._offsetY;
break;
case 1:m-=k.height;
m-=h.height+h.marginTop;
m-=this._offsetY;
break;
case 3:default:m+=j.height;
m-=h.marginTop;
m+=this._offsetY;
break
}return new Sys.UI.Bounds(i,m,k.width,k.height)
},_getBoundsRelativeToMouse:function(j,g,i){var i=this._targetControl?$telerik.getBounds(this._targetControl):$telerik.getClientBounds();
var k=this._getPosRelativeToMouse(i);
if(isNaN(k.x)){k.x=0;
k.y=0
}else{i.width=0;
i.height=0
}var h=this._getBoundsRelativeToElement(j,g,i);
var l=new Sys.UI.Bounds(k.x+h.x,k.y+h.y,j.width,j.height);
return l
},getToolTipBounds:function(){var i=this._popupElement;
var j=(i.style.display=="none")?true:false;
if(j){i.style.visibility="hidden"
}i.style.display="";
this._setOverflow();
if(this._firstShow!=true){this._fixIeHeight(this._tableElement,this._height);
this._firstShow=true
}var o=this._isRelativeToBrowserWindow()?document.documentElement:this._targetControl;
this._popupBehavior.set_parentElement(o);
var p=$telerik.getBounds(this._tableElement);
var n=this._getCalloutBounds();
if(j){this._popupElement.style.display="none";
i.style.visibility=""
}var m=Telerik.Web.UI.ToolTipRelativeDisplay;
var k=Telerik.Web.UI.ToolTipShowEvent;
var l=null;
if(this._relativeTo==m.BrowserWindow){l=this._getBoundsRelativeToBrowser(p,n)
}else{if(!this._targetControl&&this._showEvent==k.FromCode){l=this._getBoundsRelativeToBrowser(p,n)
}else{if(this._targetControl&&this._showEvent==k.FromCode){l=this._getBoundsRelativeToElement(p,n)
}else{if((this._mouseTrailing||this._relativeTo==m.Mouse)){l=this._getBoundsRelativeToMouse(p,n)
}else{if(this._relativeTo==m.Element){l=this._getBoundsRelativeToElement(p,n)
}}}}}return l
},_fixIeHeight:function(e,f){if("CSS1Compat"==document.compatMode){var h=(e.offsetHeight-parseInt(f));
if(h>0){var g=(parseInt(e.style.height)-h);
if(g>0){e.style.height=g+"px"
}}}},_refreshTitle:function(){if(null==this._titleElement){return
}this._titleElement.innerHTML=this._title;
this._titleElement.style.display=(this._title)?"":"none"
},_createManualCloseButton:function(f){if(this.get_manualClose()){var e=document.createElement("A");
e.href="javascript: void(0);";
e.className="rtCloseButton";
this._closeLinkHandler=Function.createDelegate(this,function(a){this._hideUnconditionally();
return $telerik.cancelRawEvent(a)
});
$addHandler(e,"click",this._closeLinkHandler);
this._closeLink=e;
var d=document.createElement("SPAN");
d.innerHTML="Close";
e.title="Close";
e.appendChild(d);
f.appendChild(e)
}},_createUI:function(){if(!this._popupElement){var G=this.get_id();
var N="RadToolTipWrapper_"+G;
var K=document.createElement("DIV");
K.id=N;
var B=this.get_element();
var D=B.parentNode?B:this._getDefaultParent();
var E=$telerik.isRightToLeft(D);
K.className=this._getFullSkinName()+(this.get_showCallout()?" rtVisibleCallout":"")+(E?" RadToolTip_"+this._skin+"_rtl":"");
K.setAttribute("unselectable","on");
this._popupElement=K;
var i=document.createElement("DIV");
i.className="rtCallout "+this._getCalloutPosition(this._position);
i.innerHTML="&nbsp;";
this._calloutElement=i;
var H=document.createElement("TABLE");
H.className="rtWrapper";
H.style.width=this._width;
H.style.height=this._height;
this._tableElement=H;
var A=[];
if(E){A=["rtWrapperTopRight","rtWrapperTopCenter","rtWrapperTopLeft","rtWrapperRightMiddle","rtWrapperContent","rtWrapperLeftMiddle","rtWrapperBottomRight","rtWrapperBottomCenter","rtWrapperBottomLeft"]
}else{A=["rtWrapperTopLeft","rtWrapperTopCenter","rtWrapperTopRight","rtWrapperLeftMiddle","rtWrapperContent","rtWrapperRightMiddle","rtWrapperBottomLeft","rtWrapperBottomCenter","rtWrapperBottomRight"]
}var I=0;
for(var M=1;
M<=3;
M++){var z=H.insertRow(-1);
for(var C=1;
C<=3;
C++){var L=z.insertCell(-1);
L.innerHTML="&nbsp;";
L.className=A[I];
I++
}}var j=H.rows[0].cells[1];
j.innerHTML="";
if(E){this._createManualCloseButton(j)
}var y=document.createElement("DIV");
y.className="rtTitlebar";
y.style.display="none";
this._titleElement=y;
this._refreshTitle();
j.appendChild(y);
if(!E){this._createManualCloseButton(j)
}var F=H.rows[1].cells[1];
F.vAlign="top";
F.innerHTML="";
this._contentCell=F;
var J=null;
var J=null;
if(this._text){this.set_content(this._text)
}else{var w=this.get_id();
if(w){J=$get(w)
}if(J&&J.innerHTML){var x=this._transferNodeChildren(J);
this.set_contentElement(x)
}}K.appendChild(i);
K.appendChild(H);
this._popupElement.style.display="none";
this._popupElement.style.position="absolute";
this._addToolTipToDocument(J)
}if(!this._popupBehavior){this._popupBehavior=$create(Telerik.Web.PopupBehavior,{id:(new Date()-100)+"PopupBehavior",parentElement:this._targetControl},null,null,this._popupElement)
}},_transferNodeChildren:function(e){if(!e){return null
}var h=e.ownerDocument.createElement(e.tagName);
var g=0;
while(e.childNodes&&e.childNodes.length>g){var f=e.childNodes[g];
if(this._clientStateFieldID&&f.id==this._clientStateFieldID){g=1;
continue
}e.removeChild(f);
h.appendChild(f)
}return h
},_getDefaultParent:function(){var b=this._formID?document.getElementById(this._formID):null;
if(!b){if(document.forms&&document.forms.length>0){b=document.forms[0]
}else{b=document.body
}}return b
},_addToolTipToDocument:function(d){if(null!=d&&!this.get_renderInPageRoot()){d.parentNode.insertBefore(this._popupElement,d);
return
}var c=this._getDefaultParent();
c.appendChild(this._popupElement)
},_getParentByTagName:function(e,f){var d=e;
f=f.toUpperCase();
while(d.tagName.toUpperCase()!=f){d=d.parentNode;
if(!d){break
}}return d
},_getFullSkinName:function(){return"RadToolTip_"+this._skin
},_getUniqueString:function(){return""+(new Date()-100)
},_getCalloutPosition:function(oPos){with(Telerik.Web.UI.ToolTipPosition){switch(oPos){case TopLeft:return"rtCalloutBottomRight";
case TopCenter:return"rtCalloutBottomCenter";
case TopRight:return"rtCalloutBottomLeft";
case MiddleLeft:return"rtCalloutMiddleRight";
case Center:return"rtCalloutCenter";
case MiddleRight:return"rtCalloutMiddleLeft";
case BottomLeft:return"rtCalloutTopRight";
case BottomCenter:return"rtCalloutTopCenter";
case BottomRight:return"rtCalloutTopLeft"
}}return""
},_getHorizontalSide:function(b){return parseInt((b+"").charAt(1))
},_getVerticalSide:function(b){return parseInt((b+"").charAt(0))
},_setPopupVisible:function(c,d){this._popupElement.style.zIndex=this._zIndex;
this._popupBehavior.set_x(c);
this._popupBehavior.set_y(d);
this._popupBehavior.show();
if(!this.get_width()){this._popupElement.style.width=""
}},_setOverflow:function(){var flow=this._contentScrolling;
if(flow==Telerik.Web.UI.ToolTipScrolling.Default){return
}var el=this._contentElement;
if(!el||el.parentNode!=this._contentCell||((!el.document||!el.document.documentElement)&&$telerik.isIE)){return
}var overflow="";
with(Telerik.Web.UI.ToolTipScrolling){switch(flow){case Auto:overflow="auto";
break;
case None:overflow="hidden";
break;
case X:overflow="";
el.style.overflowX="scroll";
el.style.overflowY="hidden";
break;
case Y:overflow="";
el.style.overflowY="scroll";
el.style.overflowX="hidden";
break;
case Both:overflow="scroll"
}}var parent=el.parentNode;
el.style.display="none";
var bounds=$telerik.getBounds(parent);
el.style.width=bounds.width+"px";
el.style.height=bounds.height+"px";
if(!el.style.overflowX&&!el.style.overflowY){el.style.overflow=overflow
}el.style.display=""
},_getLeftOffset:function(){var b=Telerik.Web.UI.ToolTipPosition;
if(b.Left==this._position){return(-1*this._targetControl.offsetWidth)+this._offsetX
}else{if(b.Right==this._position){return this._targetControl.offsetWidth+this._offsetX
}else{return this._offsetX
}}},_getTopOffset:function(){var c;
var d=Telerik.Web.UI.ToolTipPosition;
if(d.Top==this._position){c=(-1*this._targetControl.offsetHeight)+this._offsetY
}else{if(d.Bottom==this._position){c=this._targetControl.offsetHeight+this._offsetY
}else{c=this._offsetY
}}return c
},_adjustCallout:function(){if(this.get_showCallout()&&this.get_position()!=22){var u=this.get_targetControl();
if(!u){return
}var w=$telerik.getBounds(u);
var t=this.get_popupElement();
var x=$telerik.getBounds(t);
var n=t.getElementsByTagName("DIV")[0];
n.style.left="";
n.style.top="";
var o=$telerik.getBounds(n);
var v=this.get_position();
var m=false;
n.style.visibility="hidden";
if(w.x>o.x){m=(v==13||v==23||v==33)
}else{m=(v==11||v==21||v==31)
}if(m){return
}if(w.y>o.y){m=(v==32)
}else{m=(v==12)
}if(m){return
}n.style.visibility="visible";
var r=null;
var s=null;
if(this._verticalPosition==2){if(w.y<o.y&&(w.y+w.height)>o.y){return
}var p=x.y-w.y;
s=(Math.abs(p)+Math.floor(n.offsetHeight))
}else{if(w.x<o.x&&(w.x+w.width)>o.x){return
}var p=x.x-w.x;
var q=this._horizontalPosition;
if((q==3&&p<0)||(q==1&&p>0)||q==2){r=(Math.abs(p)+Math.floor(n.offsetWidth))
}}if(s){n.style.top=s+"px"
}if(r){n.style.left=r+"px"
}}},isVisible:function(){var b=this._popupElement;
return(b&&b.style.display!="none")
},get_targetControlID:function(){return this._targetControlID
},set_targetControlID:function(c){if(this._targetControlID!=c){this._targetControlID=c;
var d=(this._targetControlID?$get(this._targetControlID):null);
this.set_targetControl(d)
}},get_serverTargetControlID:function(){return this._serverTargetControlID
},set_serverTargetControlID:function(b){this._serverTargetControlID=b
},get_serverValue:function(){return this._serverValue
},set_serverValue:function(b){this._serverValue=b
},get_value:function(){return this.get_serverValue()
},set_value:function(b){this.set_serverValue(b)
},get_formID:function(){return this._formID
},set_formID:function(b){if(this._formID!=b){this._formID=b
}},get_position:function(){return this._position
},set_position:function(b){if(this._position!=b){this._position=b;
if(this._calloutElement){this._calloutElement.className="rtCallout "+this._getCalloutPosition(this._position)
}}this._horizontalPosition=this._getHorizontalSide(this._position);
this._verticalPosition=this._getVerticalSide(this._position)
},get_offsetX:function(){return this._offsetX
},set_offsetX:function(b){if(this._offsetX!=b){this._offsetX=b
}},get_offsetY:function(){return this._offsetY
},set_offsetY:function(b){if(this._offsetY!=b){this._offsetY=b
}},get_title:function(){return this._title
},set_title:function(b){if(this._title!=b){this._title=b
}this._refreshTitle()
},get_text:function(){return this._text
},set_text:function(b){if(this._text!=b){this._text=b
}if(this.isCreated()){this.set_content(this._text)
}},get_width:function(){return this._width
},set_width:function(b){if(this._width!=b){this._width=b
}},get_height:function(){return this._height
},set_height:function(b){if(this._height!=b){this._height=b
}},get_relativeTo:function(){return this._relativeTo
},set_relativeTo:function(b){if(this._relativeTo!=b){this._relativeTo=b
}},get_contentScrolling:function(){return this._contentScrolling
},set_contentScrolling:function(b){if(this._contentScrolling!=b){this._contentScrolling=b
}},get_sticky:function(){return this.isHideEventEnabled(Telerik.Web.UI.ToolTipHideEvent.LeaveToolTip)
},set_sticky:function(b){if(this._sticky!=b){this._sticky=b
}if(this._sticky){this.set_hideEvent(Telerik.Web.UI.ToolTipHideEvent.LeaveToolTip)
}},get_manualClose:function(){return this.isHideEventEnabled(Telerik.Web.UI.ToolTipHideEvent.ManualClose)
},set_manualClose:function(b){if(this._manualClose!=b){this._manualClose=b
}if(this._manualClose){this.set_hideEvent(Telerik.Web.UI.ToolTipHideEvent.ManualClose)
}},get_showCallout:function(){return this._showCallout
},set_showCallout:function(b){if(this._showCallout!=b){this._showCallout=b
}},get_renderInPageRoot:function(){return this._renderInPageRoot
},set_renderInPageRoot:function(b){if(this._renderInPageRoot!=b){this._renderInPageRoot=b
}},get_showDelay:function(){return this._showDelay
},set_showDelay:function(b){if(this._showDelay!=b){this._showDelay=b
}},get_autoCloseDelay:function(){return this._autoCloseDelay
},set_autoCloseDelay:function(b){if(this._autoCloseDelay!=b){this._autoCloseDelay=b
}},get_hideDelay:function(){return this._hideDelay
},set_hideDelay:function(b){if(this._hideDelay!=b){this._hideDelay=b
}},get_mouseTrailing:function(){return this._mouseTrailing
},set_mouseTrailing:function(b){if(this._mouseTrailing!=b){this._mouseTrailing=b;
if(true==b){this.set_relativeTo(Telerik.Web.UI.ToolTipRelativeDisplay.Mouse)
}}},get_visibleOnPageLoad:function(){return this._visibleOnPageLoad
},set_visibleOnPageLoad:function(b){if(this._visibleOnPageLoad!=b){this._visibleOnPageLoad=b
}},get_animation:function(){return this._animation
},set_animation:function(b){if(this._animation!=b){this._animation=b
}},get_showEvent:function(){return this._showEvent
},set_showEvent:function(b){if(this._showEvent!=b){this._showEvent=b
}},get_hideEvent:function(){return this._hideEvent
},set_hideEvent:function(b){if(this._hideEvent!=b){this._hideEvent=b
}},get_modal:function(){return this._modal
},set_modal:function(b){if(this._modal!=b){this._modal=b
}this._makeModal(this._modal)
},get_skin:function(){return this._skin
},set_skin:function(b){if(b&&this._skin!=b){this._skin=b
}},get_targetControl:function(){return this._targetControl
},set_targetControl:function(c){if(this._targetControl!=c){if(this._targetControl&&(this._targetControl!=c)){this._registerMouseHandlers(this._targetControl,false)
}this._targetControl=c;
var d=this._targetControl;
if(d){if($telerik.isIE&&d){d.removeAttribute("alt")
}this._registerMouseHandlers(d,true);
if(this._popupBehavior){this._popupBehavior.set_parentElement(d)
}}}},get_popupElement:function(){return this._popupElement
},add_beforeShow:function(b){this.get_events().addHandler("beforeShow",b)
},remove_beforeShow:function(b){this.get_events().removeHandler("beforeShow",b)
},add_show:function(b){this.get_events().addHandler("show",b)
},remove_show:function(b){this.get_events().removeHandler("show",b)
},add_beforeHide:function(b){this.get_events().addHandler("beforeHide",b)
},remove_beforeHide:function(b){this.get_events().removeHandler("beforeHide",b)
},add_hide:function(b){this.get_events().addHandler("hide",b)
},remove_hide:function(b){this.get_events().removeHandler("hide",b)
}};
Telerik.Web.UI.RadToolTip.registerClass("Telerik.Web.UI.RadToolTip",Telerik.Web.UI.RadWebControl);
Telerik.Web.UI.ToolTipPosition=function(){throw Error.invalidOperation()
};
Telerik.Web.UI.ToolTipPosition.prototype={TopLeft:11,TopCenter:12,TopRight:13,MiddleLeft:21,Center:22,MiddleRight:23,BottomLeft:31,BottomCenter:32,BottomRight:33};
Telerik.Web.UI.ToolTipPosition.registerEnum("Telerik.Web.UI.ToolTipPosition",false);
Telerik.Web.UI.ToolTipRelativeDisplay=function(){throw Error.invalidOperation()
};
Telerik.Web.UI.ToolTipRelativeDisplay.prototype={Mouse:0,Element:1,BrowserWindow:2};
Telerik.Web.UI.ToolTipRelativeDisplay.registerEnum("Telerik.Web.UI.ToolTipRelativeDisplay",false);
Telerik.Web.UI.ToolTipScrolling=function(){throw Error.invalidOperation()
};
Telerik.Web.UI.ToolTipScrolling.prototype={Auto:0,None:1,X:2,Y:3,Both:4,Default:5};
Telerik.Web.UI.ToolTipScrolling.registerEnum("Telerik.Web.UI.ToolTipScrolling",false);
Telerik.Web.UI.ToolTipAnimation=function(){throw Error.invalidOperation()
};
Telerik.Web.UI.ToolTipAnimation.prototype={None:0,Resize:1,Fade:2,Slide:4,FlyIn:8};
Telerik.Web.UI.ToolTipAnimation.registerEnum("Telerik.Web.UI.ToolTipAnimation",false);
Telerik.Web.UI.ToolTipShowEvent=function(){throw Error.invalidOperation()
};
Telerik.Web.UI.ToolTipShowEvent.prototype={OnMouseOver:1,OnClick:2,OnRightClick:4,OnFocus:8,FromCode:16};
Telerik.Web.UI.ToolTipShowEvent.registerEnum("Telerik.Web.UI.ToolTipShowEvent",false);
Telerik.Web.UI.ToolTipHideEvent=function(){throw Error.invalidOperation()
};
Telerik.Web.UI.ToolTipHideEvent.prototype={Default:1,LeaveToolTip:2,ManualClose:4,LeaveTargetAndToolTip:8,FromCode:16};
Telerik.Web.UI.ToolTipHideEvent.registerEnum("Telerik.Web.UI.ToolTipHideEvent",false);
if(typeof(Sys)!=='undefined')Sys.Application.notifyScriptLoaded();