﻿Type.registerNamespace("Telerik.Web.UI");
Telerik.Web.UI.RadToolTipControllerClass=function(){
this._tooltipToShow=null;
this._currentToolTip=null;
this._registerGlobalBodyEventHandlers();
};
Telerik.Web.UI.RadToolTipControllerClass.prototype={getInstance:function(){
return this;
},_registerGlobalBodyEventHandlers:function(){
var _1=Function.createDelegate(null,function(e){
if(e.keyCode==27){
Telerik.Web.UI.RadToolTipController.hideCurrentToolTipUnconditionally();
}
});
$addHandler(document.body,"keydown",_1);
var _3=Function.createDelegate(null,function(){
Telerik.Web.UI.RadToolTipController.hideCurrentToolTip();
});
$addHandler(document.body,"click",_3);
Sys.Application.add_unload(function(){
$removeHandler(document.body,"keydown",_1);
$removeHandler(document.body,"click",_3);
});
},cancelSpecificShowRequest:function(_4){
if(this._tooltipToShow==_4){
this.cancelLastShowRequest();
}
},cancelLastShowRequest:function(){
if(this._tooltipToShow){
var _5=this._tooltipToShow;
this._tooltipToShow=null;
_5.cancelShowDelay();
}
},hideCurrentToolTip:function(){
var _6=true;
if(this._currentToolTip!=null){
_6=this._currentToolTip.hide(true);
}
if(_6){
this._currentToolTip=null;
}
},hideCurrentToolTipUnconditionally:function(){
this.cancelLastShowRequest();
if(this._currentToolTip!=null){
this._currentToolTip.hide();
}
this._currentToolTip=null;
},requestShow:function(_7){
this.cancelLastShowRequest();
this._tooltipToShow=_7;
},showTootlip:function(_8){
if(!_8||_8.isVisible()){
return;
}
this.cancelLastShowRequest();
this.setCurrentToolTip(_8);
_8.show();
},setCurrentToolTip:function(_9){
if(_9!=this._currentToolTip){
this.hideCurrentToolTipUnconditionally();
}
this._currentToolTip=_9;
},notifyToolTipClosed:function(_a){
if(this._currentToolTip==_a){
this._currentToolTip=null;
}
}};
Telerik.Web.UI.RadToolTipControllerClass.registerClass("Telerik.Web.UI.RadToolTipControllerClass",null);
if(!Telerik.Web.UI.RadToolTipController){
Telerik.Web.UI.RadToolTipController=new Telerik.Web.UI.RadToolTipControllerClass();
}


if(typeof(Sys)!=='undefined')Sys.Application.notifyScriptLoaded();