﻿
Type.registerNamespace('Interhome.Web.BL.WebFramework.Ajax');Interhome.Web.BL.WebFramework.Ajax.LanguageFloatBehavior=function(element){Interhome.Web.BL.WebFramework.Ajax.LanguageFloatBehavior.initializeBase(this,[element]);this._targetDivControlID=null;this._targetDivControl=null;this._mouseOverHandler=null;this._mouseOutHandler=null;this._mouseMoveHandler=null;this._closingLanguage=null;this._isIE7OrLess=null;};Interhome.Web.BL.WebFramework.Ajax.LanguageFloatBehavior.prototype={initialize:function(){Interhome.Web.BL.WebFramework.Ajax.LanguageFloatBehavior.callBaseMethod(this,'initialize');this._isIE7OrLess=(Sys.Browser.agent==Sys.Browser.InternetExplorer&&Sys.Browser.version<8);var e=this.get_element();this._targetDivControl=$get(this._targetDivControlID);this._mouseOverHandler=Function.createDelegate(this,this._onMouseOver);$addHandler(e,"mouseover",this._mouseOverHandler);this._mouseOutHandler=Function.createDelegate(this,this._onMouseOut);$addHandler(e,"mouseout",this._mouseOutHandler);this._mouseMoveHandler=Function.createDelegate(this,this._onMouseMove);$addHandler(e,"mousemove",this._mouseMoveHandler);},removeHandler:function(element,eventName,handler){try{$removeHandler(element,eventName,handler);}catch(e){}},dispose:function(){var e=this.get_element();if(this._mouseOverHandler){this.removeHandler(e,"mouseover",this._mouseOverHandler);this._mouseOverHandler=null;}
if(this._mouseOutHandler){this.removeHandler(e,"mouseout",this._mouseOutHandler);this._mouseOutHandler=null;}
if(this._mouseMoveHandler){this.removeHandler(e,"mousemove",this._mouseMoveHandler);this._mouseMoveHandler=null;}
Interhome.Web.BL.WebFramework.Ajax.LanguageFloatBehavior.callBaseMethod(this,'dispose');},_onMouseOver:function(){this.showDiv();},_onMouseOut:function(){this.hideDiv();},_onMouseMove:function(){this.showDiv();},showDiv:function(){$common.setVisible(this._targetDivControl,true);if(this._closingLanguage!==null){window.clearTimeout(this._closingLanguage);}
this._closingLanguage=null;},hideDiv:function(){if(this._isIE7OrLess){this._closingLanguage=window.setTimeout(function(control){return function(){$common.setVisible(control,false);};}(this._targetDivControl),1500);}else{this._closingLanguage=window.setTimeout(this.actualHideDiv,1500,this._targetDivControl);}},actualHideDiv:function(control){$common.setVisible(control,false);},get_TargetDivControlID:function(){return this._targetDivControlID;},set_TargetDivControlID:function(value){this._targetDivControlID=value;}};Interhome.Web.BL.WebFramework.Ajax.LanguageFloatBehavior.registerClass('Interhome.Web.BL.WebFramework.Ajax.LanguageFloatBehavior',AjaxControlToolkit.BehaviorBase);
if(typeof(Sys)!=='undefined')Sys.Application.notifyScriptLoaded();