﻿Type.registerNamespace("Telerik.Web");
Telerik.Web.BehaviorBase=function(_1){
Telerik.Web.BehaviorBase.initializeBase(this,[_1]);
this._clientStateFieldID=null;
this._pageRequestManager=null;
this._partialUpdateBeginRequestHandler=null;
this._partialUpdateEndRequestHandler=null;
};
Telerik.Web.BehaviorBase.prototype={initialize:function(){
Telerik.Web.BehaviorBase.callBaseMethod(this,"initialize");
},dispose:function(){
var _2=this.get_element();
Telerik.Web.BehaviorBase.callBaseMethod(this,"dispose");
if(_2&&_2._behaviors&&_2._behaviors.length==0){
_2._behaviors=null;
}
_2=null;
if(this._pageRequestManager){
if(this._partialUpdateBeginRequestHandler){
this._pageRequestManager.remove_beginRequest(this._partialUpdateBeginRequestHandler);
this._partialUpdateBeginRequestHandler=null;
}
if(this._partialUpdateEndRequestHandler){
this._pageRequestManager.remove_endRequest(this._partialUpdateEndRequestHandler);
this._partialUpdateEndRequestHandler=null;
}
this._pageRequestManager=null;
}
},get_ClientStateFieldID:function(){
return this._clientStateFieldID;
},set_ClientStateFieldID:function(_3){
if(this._clientStateFieldID!=_3){
this._clientStateFieldID=_3;
this.raisePropertyChanged("ClientStateFieldID");
}
},get_ClientState:function(){
if(this._clientStateFieldID){
var _4=document.getElementById(this._clientStateFieldID);
if(_4){
return _4.value;
}
}
return null;
},set_ClientState:function(_5){
if(this._clientStateFieldID){
var _6=document.getElementById(this._clientStateFieldID);
if(_6){
_6.value=_5;
}
}
},registerPartialUpdateEvents:function(){
if(Sys&&Sys.WebForms&&Sys.WebForms.PageRequestManager){
this._pageRequestManager=Sys.WebForms.PageRequestManager.getInstance();
if(this._pageRequestManager){
this._partialUpdateBeginRequestHandler=Function.createDelegate(this,this._partialUpdateBeginRequest);
this._pageRequestManager.add_beginRequest(this._partialUpdateBeginRequestHandler);
this._partialUpdateEndRequestHandler=Function.createDelegate(this,this._partialUpdateEndRequest);
this._pageRequestManager.add_endRequest(this._partialUpdateEndRequestHandler);
}
}
},_partialUpdateBeginRequest:function(_7,_8){
},_partialUpdateEndRequest:function(_9,_a){
}};
Telerik.Web.BehaviorBase.registerClass("Telerik.Web.BehaviorBase",Sys.UI.Behavior);
Type.registerNamespace("Telerik.Web");
Type.registerNamespace("Telerik.Web.UI");
Telerik.Web.UI.ModalExtender=function(_b){
this._windowResizeDelegate=null;
this._windowScrollDelegate=null;
this._xCoordinate=-1;
this._yCoordinate=-1;
this._backgroundElement=null;
this._foregroundElement=_b;
this._saveTabIndexes=new Array();
this._saveDesableSelect=new Array();
this._tagWithTabIndex=new Array("A","AREA","BUTTON","INPUT","OBJECT","SELECT","TEXTAREA","IFRAME");
};
Telerik.Web.UI.ModalExtender.prototype={dispose:function(){
this.hide();
this._backgroundElement=null;
this._foregroundElement=null;
},show:function(){
this._attachWindowHandlers(true);
var _c=this._getModalOverlay();
this._foregroundElement.parentNode.appendChild(_c);
_c.style.zIndex=$telerik.getCurrentStyle(this._foregroundElement,"zIndex",this._foregroundElement.style.zIndex)-1;
_c.style.display="";
this._disableTab();
this._updatePageLayout();
this._updatePageLayout();
},_storeBrowserPosition:function(){
var _d=document.body;
var _e=document.documentElement;
this._browserTop=_d.scrollTop>_e.scrollTop?_d.scrollTop:_e.scrollTop;
this._browserLeft=_d.scrollLeft>_e.scrollLeft?_d.scrollTop:_e.scrollLeft;
},_restoreBrowserPosition:function(_f,top){
try{
if(null==_f){
_f=this._browserLeft;
}
if(null==top){
top=this._browserTop;
}
var _11=document.body;
var _12=document.documentElement;
_11.scrollTop=top;
_11.scrollLeft=_f;
_12.scrollTop=top;
_12.scrollLeft=_f;
}
catch(ex){
}
},hide:function(){
this._backgroundElement.style.display="none";
this._restoreTab();
this._attachWindowHandlers(false);
},_enableScroll:function(_13){
if(_13){
document.body.style.overflow=null!=this._overflow?this._overflow:"";
document.documentElement.style.overflow=null!=this._documentOverflow?this._documentOverflow:"";
document.body.style.marginRight="";
}else{
this._overflow=document.body.style.overflow;
document.body.style.overflow="hidden";
this._documentOverflow=document.documentElement.style.overflow;
document.documentElement.style.overflow="hidden";
document.body.style.marginRight="18px";
}
},_getModalOverlay:function(){
if(!this._backgroundElement){
var div=document.createElement("div");
div.style.display="none";
div.style.position="absolute";
if($telerik.isRightToLeft(this._foregroundElement)){
div.style.right="0px";
}else{
div.style.left="0px";
}
div.style.top="0px";
div.style.zIndex=10000;
div.style.backgroundColor="#aaaaaa";
div.style.filter="progid:DXImageTransform.Microsoft.Alpha(style=0,opacity=50)";
div.style.opacity=".5";
div.style.mozOpacity=".5";
div.className="TelerikModalOverlay";
this._backgroundElement=div;
}
return this._backgroundElement;
},_attachWindowHandlers:function(_15){
var _16=window;
if(true==_15){
this._windowResizeDelegate=Function.createDelegate(this,this._updatePageLayout);
$addHandler(_16,"resize",this._windowResizeDelegate);
this._windowScrollDelegate=Function.createDelegate(this,this._updatePageLayout);
$addHandler(_16,"scroll",this._windowScrollDelegate);
}else{
if(this._windowResizeDelegate){
$removeHandler(_16,"resize",this._windowResizeDelegate);
}
this._windowResizeDelegate=null;
if(this._windowScrollDelegate){
$removeHandler(_16,"scroll",this._windowScrollDelegate);
}
this._windowScrollDelegate=null;
}
},_updatePageLayout:function(){
var _17=(document.documentElement.scrollLeft?$telerik.getCorrectScrollLeft(document.documentElement):$telerik.getCorrectScrollLeft(document.body));
var _18=(document.documentElement.scrollTop?document.documentElement.scrollTop:document.body.scrollTop);
var _19=$telerik.getClientBounds();
var _1a=_19.width;
var _1b=_19.height;
var _1c=this._getModalOverlay();
_1c.style.width=Math.max(Math.max(document.documentElement.scrollWidth,document.body.scrollWidth),_1a)+"px";
_1c.style.height=Math.max(Math.max(document.documentElement.scrollHeight,document.body.scrollHeight),_1b)+"px";
},_disableTab:function(){
var i=0;
var _1e;
var _1f=new Array();
Array.clear(this._saveTabIndexes);
for(var j=0;j<this._tagWithTabIndex.length;j++){
_1e=this._foregroundElement.getElementsByTagName(this._tagWithTabIndex[j]);
for(var k=0;k<_1e.length;k++){
_1f[i]=_1e[k];
i++;
}
}
i=0;
for(var j=0;j<this._tagWithTabIndex.length;j++){
_1e=document.getElementsByTagName(this._tagWithTabIndex[j]);
for(var k=0;k<_1e.length;k++){
if(Array.indexOf(_1f,_1e[k])==-1){
this._saveTabIndexes[i]={tag:_1e[k],index:_1e[k].tabIndex};
_1e[k].tabIndex="-1";
i++;
}
}
}
i=0;
if((Sys.Browser.agent===Sys.Browser.InternetExplorer)&&(Sys.Browser.version<7)){
var _22=new Array();
for(var j=0;j<this._tagWithTabIndex.length;j++){
_1e=this._foregroundElement.getElementsByTagName("SELECT");
for(var k=0;k<_1e.length;k++){
_22[i]=_1e[k];
i++;
}
}
i=0;
Array.clear(this._saveDesableSelect);
_1e=document.getElementsByTagName("SELECT");
for(var k=0;k<_1e.length;k++){
if(Array.indexOf(_22,_1e[k])==-1){
this._saveDesableSelect[i]={tag:_1e[k],visib:$telerik.getCurrentStyle(_1e[k],"visibility")};
_1e[k].style.visibility="hidden";
i++;
}
}
}
},_restoreTab:function(){
for(var i=0;i<this._saveTabIndexes.length;i++){
this._saveTabIndexes[i].tag.tabIndex=this._saveTabIndexes[i].index;
}
if((Sys.Browser.agent===Sys.Browser.InternetExplorer)&&(Sys.Browser.version<7)){
for(var k=0;k<this._saveDesableSelect.length;k++){
this._saveDesableSelect[k].tag.style.visibility=this._saveDesableSelect[k].visib;
}
}
}};
Telerik.Web.UI.ModalExtender.registerClass("Telerik.Web.UI.ModalExtender",null);
Type.registerNamespace("Telerik.Web");
Telerik.Web.PositioningMode=function(){
throw Error.invalidOperation();
};
Telerik.Web.PositioningMode.prototype={Absolute:0,Center:1,BottomLeft:2,BottomRight:3,TopLeft:4,TopRight:5};
Telerik.Web.PositioningMode.registerEnum("Telerik.Web.PositioningMode");
Telerik.Web.PopupBehavior=function(_25){
Telerik.Web.PopupBehavior.initializeBase(this,[_25]);
this._x=0;
this._y=0;
this._positioningMode=Telerik.Web.PositioningMode.Absolute;
this._parentElement=null;
this._parentElementID=null;
this._moveHandler=null;
this._firstPopup=true;
this._originalParent=null;
this._overlay=false;
this._keepInScreenBounds=true;
this._manageVisibility=true;
};
Telerik.Web.PopupBehavior._ie6pinnedList={};
Telerik.Web.PopupBehavior.prototype={getPageOffset:function(){
var _26={x:($telerik.getCorrectScrollLeft(document.documentElement)||$telerik.getCorrectScrollLeft(document.body)),y:(document.documentElement.scrollTop||document.body.scrollTop)};
return _26;
},pin:function(_27){
var _28=this.get_element();
var _29=this.getPageOffset();
if($telerik.isIE6){
var id=this.get_id();
if(_27){
if(Telerik.Web.PopupBehavior._ie6pinnedList[id]){
return;
}
var _2b=$telerik.getBounds(_28);
Telerik.Web.PopupBehavior._ie6pinnedList[id]=window.setInterval(Function.createDelegate(this,function(){
var _2c=this.getPageOffset();
var x=_2b.x-_29.x+_2c.x;
var y=_2b.y-_29.y+_2c.y;
var _2f=this.get_parentElement();
this.set_parentElement(document.documentElement);
this.set_x(x);
this.set_y(y);
this.show();
this.set_parentElement(_2f);
}),130);
}else{
var _30=Telerik.Web.PopupBehavior._ie6pinnedList[id];
if(_30){
window.clearInterval(_30);
}
delete Telerik.Web.PopupBehavior._ie6pinnedList[id];
}
}else{
var _31=_27?"fixed":"absolute";
if(_28.style.position==_31){
return;
}
var _2b=$telerik.getBounds(_28);
if(_27&&(_29.x||_29.y)){
this._x=_2b.x-_29.x;
this._y=_2b.y-_29.y;
$telerik.setLocation(_28,{x:this._x,y:this._y});
}
_28.style.position=_31;
}
},center:function(){
var _32=this.get_element();
if(this._manageVisibility){
$telerik.setVisible(_32,true);
}
var _33=$telerik.getClientBounds();
var _34=$telerik.getBounds(_32);
var x=parseInt((_33.width-_34.width)/2);
var y=parseInt((_33.height-_34.height)/2);
var _37=this.get_parentElement();
this.set_parentElement(document.documentElement);
this.set_x(x);
this.set_y(y);
this.show();
this.set_parentElement(_37);
},get_parentElement:function(){
if(!this._parentElement&&this._parentElementID){
this.set_parentElement($get(this._parentElementID));
Sys.Debug.assert(this._parentElement!=null,String.format("Couldn't find parent element \"{0}\"",this._parentElementID));
}
return this._parentElement;
},set_parentElement:function(_38){
this._parentElement=_38;
},get_parentElementID:function(){
if(this._parentElement){
return this._parentElement.id;
}
return this._parentElementID;
},set_parentElementID:function(_39){
this._parentElementID=_39;
if(this.get_isInitialized()){
this.set_parentElement($get(_39));
}
},get_positioningMode:function(){
return this._positioningMode;
},set_positioningMode:function(_3a){
this._positioningMode=_3a;
},get_x:function(){
return this._x;
},set_x:function(_3b){
if(_3b!=this._x){
this._x=_3b;
if($telerik.getVisible(this.get_element())&&this._manageVisibility){
this.show();
}
}
},get_y:function(){
return this._y;
},set_y:function(_3c){
if(_3c!=this._y){
this._y=_3c;
if($telerik.getVisible(this.get_element())&&this._manageVisibility){
this.show();
}
}
},get_overlay:function(){
return this._overlay;
},set_overlay:function(_3d){
this._overlay=_3d;
this._attachWindowHandlers(false);
if(this._overlay){
this._attachWindowHandlers(true);
}else{
if(!((Sys.Browser.agent===Sys.Browser.InternetExplorer)&&(Sys.Browser.version<7))){
var elt=this.get_element();
var _3f=elt._hideWindowedElementsIFrame;
if(_3f){
_3f.style.display="none";
}
}
}
},get_manageVisibility:function(){
return this._manageVisibility;
},set_manageVisibility:function(_40){
this._manageVisibility=_40;
},get_keepInScreenBounds:function(){
return this._keepInScreenBounds;
},set_keepInScreenBounds:function(_41){
this._keepInScreenBounds=_41;
},hide:function(){
var elt=this.get_element();
if(this._manageVisibility){
$telerik.setVisible(elt,false);
}
if(elt.originalWidth){
elt.style.width=elt.originalWidth+"px";
elt.originalWidth=null;
}
if(Sys.Browser.agent===Sys.Browser.InternetExplorer||this._overlay){
var _43=elt._hideWindowedElementsIFrame;
if(_43){
_43.style.display="none";
}
}
},show:function(){
var elt=this.get_element();
if($telerik.isFirefox){
var doc=document.documentElement;
var _46=$telerik.getCurrentStyle(doc,"overflow");
if("hidden"==_46){
elt.style.left=doc.scrollLeft+"px";
elt.style.top=doc.scrollLeft+"px";
}
}
if(this._manageVisibility){
$telerik.setVisible(elt,true);
}
var _47=elt.offsetParent||document.documentElement;
var _48;
var _49;
if(this._parentElement){
_49=$telerik.getBounds(this._parentElement);
if(_47.tagName.toUpperCase()!="BODY"&&_47.tagName.toUpperCase()!="HTML"){
var _4a=$telerik.getLocation(_47);
var _4b=$telerik.getBorderBox(_47);
_4a.x+=_4b.top;
_4a.y+=_4b.left;
_48={x:_49.x-_4a.x+_47.scrollLeft,y:_49.y-_4a.y+_47.scrollTop};
}else{
_48={x:_49.x,y:_49.y};
}
}else{
_49=$telerik.getBounds(_47);
_48={x:0,y:0};
}
var _4c=elt.offsetWidth-(elt.clientLeft?elt.clientLeft*2:0);
var _4d=elt.offsetHeight-(elt.clientTop?elt.clientTop*2:0);
var _4e;
switch(this._positioningMode){
case Telerik.Web.PositioningMode.Center:
_4e={x:Math.round(_49.width/2-_4c/2),y:Math.round(_49.height/2-_4d/2)};
break;
case Telerik.Web.PositioningMode.BottomLeft:
_4e={x:0,y:_49.height};
break;
case Telerik.Web.PositioningMode.BottomRight:
_4e={x:_49.width-_4c,y:_49.height};
break;
case Telerik.Web.PositioningMode.TopLeft:
_4e={x:0,y:-elt.offsetHeight};
break;
case Telerik.Web.PositioningMode.TopRight:
_4e={x:_49.width-_4c,y:-elt.offsetHeight};
break;
default:
_4e={x:0,y:0};
}
_4e.x+=this._x+_48.x;
_4e.y+=this._y+_48.y;
$telerik.setLocation(elt,_4e);
if(this._firstPopup){
elt.style.width=_4c+"px";
}
this._firstPopup=false;
var _4f=$telerik.getBounds(elt);
var _50=this._getViewportBounds();
if(this._keepInScreenBounds){
var _51=false;
var _52=self.innerWidth?self.innerWidth:document.documentElement.clientWidth;
if(!_52){
_52=document.body.clientWidth;
}
if($telerik.isRightToLeft(document.body)){
_52=document.documentElement.scrollWidth?document.documentElement.scrollWidth:document.body.scrollWidth;
}
if(_4f.x+_4f.width-_50.scrollLeft>_52){
_4e.x=_52-_4f.width+_50.scrollLeft;
_51=true;
}
if(_4f.x<0){
_4e.x-=_4f.x;
_51=true;
}
if(_4f.y<0){
_4e.y-=_4f.y;
_51=true;
}
if(_50.height<_4f.y+_4f.height-_50.scrollTop){
if(_50.height-_4f.height>0){
_4e.y=_50.height-_4f.height+_50.scrollTop;
_51=true;
}
}
if(_51){
$telerik.setLocation(elt,_4e);
_4f=$telerik.getBounds(elt);
}
}
elt.zIndex=1000;
if(((Sys.Browser.agent===Sys.Browser.InternetExplorer)&&(Sys.Browser.version<7))||this._overlay){
var _53=elt._hideWindowedElementsIFrame;
if(!_53){
_53=document.createElement("iframe");
_53.src="javascript:'<html></html>';";
_53.style.position="absolute";
_53.style.display="none";
_53.scrolling="no";
_53.frameBorder="0";
_53.tabIndex="-1";
_53.style.filter="progid:DXImageTransform.Microsoft.Alpha(style=0,opacity=0)";
elt.parentNode.insertBefore(_53,elt);
elt._hideWindowedElementsIFrame=_53;
this._moveHandler=Function.createDelegate(this,this._onMove);
$telerik.addExternalHandler(elt,"move",this._moveHandler);
}
$telerik.setBounds(_53,_4f);
if(Sys.Browser.agent===Sys.Browser.Firefox){
_53.style.top=parseInt(_4f.y)-_50.scrollTop+"px";
_53.style.left=parseInt(_4f.x)-_50.scrollLeft+"px";
_53.style.position="fixed";
}
if($telerik.quirksMode){
return;
}
_53.style.display=elt.style.display;
if(elt.currentStyle&&elt.currentStyle.zIndex){
_53.style.zIndex=elt.currentStyle.zIndex;
}else{
if(elt.style.zIndex){
_53.style.zIndex=elt.style.zIndex;
}
}
}
},_getViewportBounds:function(){
var _54=$telerik.getClientBounds();
var _55=$telerik.getCorrectScrollLeft(document.documentElement)||$telerik.getCorrectScrollLeft(document.body);
var _56=document.documentElement.scrollTop||document.body.scrollTop;
_54.scrollLeft=_55;
_54.scrollTop=_56;
return _54;
},_setCoordinates:function(x,y){
var _59=false;
if(x!=this._x){
this._x=x;
_59=true;
}
if(y!=this._y){
this._y=y;
_59=true;
}
if($telerik.getVisible(this.get_element())&&_59&&this._manageVisibility){
this.show();
}
},initialize:function(){
Telerik.Web.PopupBehavior.callBaseMethod(this,"initialize");
this.hide();
this.get_element().style.position="absolute";
},dispose:function(){
var elt=this.get_element();
if(elt){
if(this._moveHandler){
$telerik.removeExternalHandler(elt,"move",this._moveHandler);
this._moveHandler=null;
}
this._attachWindowHandlers(false);
if($telerik.getVisible(elt)&&this._manageVisibility){
this.hide();
}
if(this._originalParent){
elt.parentNode.removeChild(elt);
this._originalParent.appendChild(elt);
this._originalParent=null;
}
var _5b=elt._hideWindowedElementsIFrame;
if(_5b){
var _5c=_5b.parentNode;
var _5d=_5b.nextSibling;
if(_5c){
_5c.removeChild(_5b);
if(_5d){
_5c.insertBefore(document.createElement("SPAN"),_5d);
}else{
_5c.appendChild(document.createElement("SPAN"));
}
}
}
}
this._parentElement=null;
Telerik.Web.PopupBehavior.callBaseMethod(this,"dispose");
},_onMove:function(){
var elt=this.get_element();
var _5f=elt._hideWindowedElementsIFrame;
if(_5f){
if(Sys.Browser.agent===Sys.Browser.Firefox){
var _60=this._getViewportBounds();
_5f.style.top=parseInt(elt.style.top)-_60.scrollTop+"px";
_5f.style.left=parseInt(elt.style.left)-_60.scrollLeft+"px";
_5f.style.position="fixed";
}else{
_5f.style.top=elt.style.top;
_5f.style.left=elt.style.left;
}
}
},_handleElementResize:function(){
var elt=this.get_element();
var _62=elt._hideWindowedElementsIFrame;
if(_62){
var _63=$telerik.getBounds(elt);
$telerik.setBounds(_62,_63);
}
},_attachWindowHandlers:function(_64){
if(!Sys.Browser.agent===Sys.Browser.Firefox){
return;
}
var _65=window;
if(true==_64){
this._windowResizeDelegate=Function.createDelegate(this,this._onMove);
$telerik.addExternalHandler(_65,"resize",this._windowResizeDelegate);
this._windowScrollDelegate=Function.createDelegate(this,this._onMove);
$telerik.addExternalHandler(_65,"scroll",this._windowScrollDelegate);
}else{
if(this._windowResizeDelegate){
$telerik.removeExternalHandler(_65,"resize",this._windowResizeDelegate);
}
this._windowResizeDelegate=null;
if(this._windowScrollDelegate){
$telerik.removeExternalHandler(_65,"scroll",this._windowScrollDelegate);
}
this._windowScrollDelegate=null;
}
}};
Telerik.Web.PopupBehavior.registerClass("Telerik.Web.PopupBehavior",Telerik.Web.BehaviorBase);
Type.registerNamespace("Telerik.Web.UI");
Telerik.Web.UI.ResizeExtender=function(_66,_67,_68,_69,doc,_6b,_6c){
this._document=doc?doc:document;
this._documentMouseMoveDelegate=null;
this._documentMouseUpDelegate=null;
this._element=null;
this._tableElement=null;
this._moveCursorType="move";
this._enabled=true;
this._jsOwner=null;
this._hideIframes=true;
this._autoScrollEnabled=true;
this._saveDelegates={};
this.makeResizable(_66,_67,_68,_69,_6b,_6c);
};
Telerik.Web.UI.ResizeExtender.containsBounds=function(_6d,_6e){
if(!_6d||!_6e){
return false;
}
var _6f=$telerik.containsPoint(_6d,_6e.x,_6e.y);
if(_6f){
var x=_6e.x+_6e.width;
var y=_6e.y+_6e.height;
_6f=$telerik.containsPoint(_6d,x,y);
}
return _6f;
};
Telerik.Web.UI.ResizeExtender.prototype={dispose:function(){
this._attachDocumentHandlers(false);
this._configureHandleElements(false);
this._jsOwner=null;
},enable:function(_72){
this._enabled=_72;
},set_hideIframes:function(_73){
this._hideIframes=_73;
},get_hideIframes:function(){
return this._hideIframes;
},makeResizable:function(_74,_75,_76,_77,_78,_79){
if(!_75){
return;
}
if(this._element){
alert("Element "+_75.getAttribute("id")+" cannot be made resizable, as the resizeExtender already has the element "+this._element.getAttribute("id")+" associated with it. You must create a new extender resizer object");
return;
}
this._jsOwner=_74;
this._element=_75;
this._tableElement=_77;
this._resizeHandles=_76;
if(_78){
this._moveCursorType=_78;
}
if(_79!=null){
this._autoScrollEnabled=_79;
}
this._startX=0;
this._startY=0;
this._cancelResize=true;
this._configureHandleElements(true);
},_raiseDragEvent:function(_7a,ev,_7c){
if(this._jsOwner&&this._jsOwner["on"+_7a]){
var _7d=ev;
if(!_7d){
_7d={};
}
_7d.element=this._element;
_7d.ownerEvent=_7c;
return this._jsOwner["on"+_7a](_7d);
}
return true;
},_raiseEvent:function(_7e,ev){
if(this._jsOwner&&this._jsOwner["on"+_7e]){
if(!ev){
ev=new Sys.EventArgs();
}else{
if(_7e=="Resize"){
ev=this._resizeDir;
}else{
if(_7e=="Resizing"){
ev=this._getProposedBounds(ev);
}
}
}
return this._jsOwner["on"+_7e](ev);
}
return true;
},_getProposedBounds:function(b1){
var b2=$telerik.getBounds(this._element);
return {x:b1.x||b2.x,y:b1.y||b2.y,width:b1.width||b2.width,height:b1.height||b2.height};
},_resize:function(e){
if(!this._enabled||this._cancelResize){
return false;
}
var _83=0;
var _84=0;
var _85=0;
var _86=0;
var _87=this._originalBounds;
var _88=this._resizeDir.move;
if(_88){
_85=_87.x+(e.clientX-this._startX);
_86=_87.y+(e.clientY-this._startY);
}else{
if(this._resizeDir.east){
_83=_87.width+(e.clientX-this._startX);
}else{
if(this._resizeDir.west){
_85=e.clientX-this._leftHandleMouseDelta;
_83=_87.width-(e.clientX-this._startX);
}
}
if(this._resizeDir.south){
_84=_87.height+(e.clientY-this._startY);
}else{
if(this._resizeDir.north){
_86=_87.y+(e.clientY-this._startY);
_84=_87.height-(e.clientY-this._startY);
}
}
}
if(this._offsetLocation){
_85-=this._offsetLocation.x;
_86-=this._offsetLocation.y;
}
var _89=new Sys.UI.Bounds(_85,_86,_83,_84);
var _8a=_88?this._raiseDragEvent("Drag",_89,e):this._raiseEvent("Resizing",_89);
if(false==_8a){
return true;
}
if(_88||_89.x>0){
this._element.style.left=_89.x+"px";
}
if(_88||_89.y>0){
this._element.style.top=_89.y+"px";
}
if(_89.width>0){
this._element.style.width=_89.width+"px";
}
if(_89.height>0){
this._element.style.height=_89.height+"px";
}
if(!_88){
this._updateInnerTableSize();
}
return true;
},_storeStartCoords:function(e){
if(!this._enabled){
return;
}
this._cancelResize=false;
this._startX=e.clientX;
this._startY=e.clientY;
var _8c=$telerik.getBounds(this._element);
this._originalBounds=_8c;
var _8d=e.target?e.target:e.srcElement;
if(_8d&&_8d.type==3){
_8d=_8d.parentNode;
}
this._resizeType=$telerik.getCurrentStyle(_8d,"cursor");
this._resizeDir={north:this._resizeType.match(/n.?-/)?1:0,east:this._resizeType.match(/e-/)?1:0,south:this._resizeType.match(/s.?-/)?1:0,west:this._resizeType.match(/w-/)?1:0,move:new RegExp(this._moveCursorType).test(this._resizeType)?1:0};
this._leftHandleMouseDelta=0;
if(this._resizeDir.west){
this._leftHandleMouseDelta=Math.abs($telerik.getBounds(_8d).x-this._startX);
}
var _8e=this._resizeDir.move?this._raiseDragEvent("DragStart",null,e):this._raiseEvent("ResizeStart");
this._cancelResize=(_8e==false);
var _8f=$telerik.getCurrentStyle(this._element.parentNode,"position");
var _90=("relative"==_8f)||("absolute"==_8f);
this._offsetLocation=_90?$telerik.getLocation(this._element.parentNode):null;
if(!this._cancelResize){
this._clearSelection();
this._setIframesVisible(false);
this._attachDocumentHandlers(false);
this._attachDocumentHandlers(true);
}
},_updateInnerTableSize:function(){
var dir=this._resizeDir;
if(dir.south||dir.north){
var _92=this._element.style.height;
var _93=this._tableElement;
if(_93){
_93.style.height=_92;
this._fixIeHeight(_93,_92);
}
}
},_setIframesVisible:function(_94){
if(!this._hideIframes){
return;
}
var _95=this._document.getElementsByTagName("IFRAME");
for(var i=0;i<_95.length;i++){
var _97=_95[i];
_97.style.visibility=_94?"":"hidden";
if($telerik.isIE){
try{
_97.contentWindow.document.body.style.visibility=_94?"":"hidden";
}
catch(ex){
}
}
}
},_configureHandleElements:function(_98){
var _99=["nw","n","ne","w","e","sw","s","se",this._moveCursorType];
for(var i=0;i<_99.length;i++){
var _9b=_99[i];
var _9c=this._resizeHandles[_9b];
if(_9c){
if(_9c instanceof Array){
for(var j=0;j<_9c.length;j++){
this._configureHandle("id"+i+"_"+j,_98,_9c[j],_9b);
}
}else{
this._configureHandle("id"+i,_98,_9c,_9b);
}
}
}
if(!_98){
this._saveDelegates={};
}
},_configureHandle:function(_9e,_9f,_a0,_a1){
if(_9f){
var _a2=Function.createDelegate(this,this._onHandleMouseDown);
$telerik.addExternalHandler(_a0,"mousedown",_a2);
this._saveDelegates[_9e]={delegate:_a2,element:_a0};
var _a3=(_a1==this._moveCursorType?this._moveCursorType:_a1+"-resize");
_a0.style.cursor=_a3;
}else{
$telerik.removeExternalHandler(_a0,"mousedown",this._saveDelegates[_9e].delegate);
_a0.style.cursor="";
}
},_attachDocumentHandlers:function(_a4){
var _a5=this._document;
if(true==_a4){
this._documentMouseMoveDelegate=Function.createDelegate(this,this._onDocumentMouseMove);
$telerik.addExternalHandler(_a5,"mousemove",this._documentMouseMoveDelegate);
this._documentMouseUpDelegate=Function.createDelegate(this,this._onDocumentMouseUp);
$telerik.addExternalHandler(_a5,"mouseup",this._documentMouseUpDelegate);
}else{
if(this._documentMouseMoveDelegate){
$telerik.removeExternalHandler(_a5,"mousemove",this._documentMouseMoveDelegate);
}
this._documentMouseMoveDelegate=null;
if(this._documentMouseUpDelegate){
$telerik.removeExternalHandler(_a5,"mouseup",this._documentMouseUpDelegate);
}
this._documentMouseUpDelegate=null;
}
},_onDocumentMouseMove:function(e){
var _a7=this._resize(e);
if(this._autoScrollEnabled){
this._autoScroll(e);
}
if(_a7){
return $telerik.cancelRawEvent(e);
}
},_onDocumentMouseUp:function(e){
var _a9=!this._cancelResize;
this._cancelResize=true;
if(_a9){
this._clearSelection();
this._setIframesVisible(true);
if(this._resizeDir&&this._resizeDir.move){
this._raiseDragEvent("DragEnd",null,e);
}else{
this._raiseEvent("ResizeEnd");
}
this._attachDocumentHandlers(false);
if(this._scroller){
this._scroller.set_enabled(false);
}
}
},_onHandleMouseDown:function(e){
this._storeStartCoords(e);
return $telerik.cancelRawEvent(e);
},_clearSelection:function(){
if(this._document.selection&&this._document.selection.empty){
this._document.selection.empty();
}
},_fixIeHeight:function(_ab,_ac){
if("CSS1Compat"==document.compatMode){
var _ad=(_ab.offsetHeight-parseInt(_ac));
if(_ad>0){
var _ae=(parseInt(_ab.style.height)-_ad);
if(_ae>0){
_ab.style.height=_ae+"px";
}
}
}
},_initializeAutoScroll:function(){
if(this._autoScrollInitialized){
return;
}
this._scrollEdgeConst=40;
this._scrollByConst=10;
this._scroller=null;
this._scrollDeltaX=0;
this._scrollDeltaY=0;
this._scrollerTickHandler=Function.createDelegate(this,this._onScrollerTick);
this._scroller=new Telerik.Web.Timer();
this._scroller.set_interval(10);
this._scroller.add_tick(this._scrollerTickHandler);
this._autoScrollInitialized=true;
},_autoScroll:function(ev){
this._initializeAutoScroll();
var _b0=$telerik.getClientBounds();
if(_b0.width>0){
this._scrollDeltaX=this._scrollDeltaY=0;
if(ev.clientX<_b0.x+this._scrollEdgeConst){
this._scrollDeltaX=-this._scrollByConst;
}else{
if(ev.clientX>_b0.width-this._scrollEdgeConst){
this._scrollDeltaX=this._scrollByConst;
}
}
if(ev.clientY<_b0.y+this._scrollEdgeConst){
this._scrollDeltaY=-this._scrollByConst;
}else{
if(ev.clientY>_b0.height-this._scrollEdgeConst){
this._scrollDeltaY=this._scrollByConst;
}
}
var _b1=this._scroller;
if(this._scrollDeltaX!=0||this._scrollDeltaY!=0){
this._originalStartX=this._startX;
this._originalStartY=this._startY;
_b1.set_enabled(true);
}else{
if(_b1.get_enabled()){
this._startX=this._originalStartX;
this._startY=this._originalStartY;
}
_b1.set_enabled(false);
}
}
},_onScrollerTick:function(){
var _b2=document.documentElement.scrollLeft||document.body.scrollLeft;
var _b3=document.documentElement.scrollTop||document.body.scrollTop;
window.scrollBy(this._scrollDeltaX,this._scrollDeltaY);
var _b4=document.documentElement.scrollLeft||document.body.scrollLeft;
var _b5=document.documentElement.scrollTop||document.body.scrollTop;
var _b6=_b4-_b2;
var _b7=_b5-_b3;
var _b8=this._element;
var _b9={x:parseInt(_b8.style.left)+_b6,y:parseInt(_b8.style.top)+_b7};
this._startX-=_b6;
this._startY-=_b7;
$telerik.setLocation(_b8,_b9);
}};
Telerik.Web.UI.ResizeExtender.registerClass("Telerik.Web.UI.ResizeExtender",null);


if(typeof(Sys)!=='undefined')Sys.Application.notifyScriptLoaded();