﻿Type.registerNamespace("Telerik.Web.UI");
(function(){$telerik.toSlidingZone=function(b){return b;
};
$telerik.findSlidingZone=$find;
var a=Telerik.Web.UI;
a.SplitterSlideDirection=function(){};
a.SplitterSlideDirection.prototype={Right:1,Left:2,Top:3,Bottom:4};
a.SplitterSlideDirection.registerEnum("Telerik.Web.UI.SplitterSlideDirection",false);
a.RadSlidingZone=function(b){a.RadSlidingZone.initializeBase(this,[b]);
this._width=null;
this._height=null;
this._clickToOpen=false;
this._resizeStep=0;
this._slideDuration=300;
this._splitter=null;
this._slideDirection=a.SplitterSlideDirection.Right;
this._slidingPanes=null;
this._slidingPanesById=null;
this._initiallyDockedPaneId=null;
this._dockedPaneId=null;
this._initiallyExpandedPaneId=null;
this._expandedPaneId=null;
this.GetPaneById=this.getPaneById;
this.GetTabsContainer=this.getTabsContainer;
this.DockPane=this.dockPane;
this.UndockPane=this.undockPane;
this.GetPanes=this.getPanes;
this.ExpandPane=this.expandPane;
this.CollapsePane=this.collapsePane;
this.IsLeftDirection=this.isLeftDirection;
this.IsRightDirection=this.isRightDirection;
this.IsTopDirection=this.isTopDirection;
this.IsBottomDirection=this.isBottomDirection;
};
a.RadSlidingZone.prototype={endUpdate:function(){if(this._width.toString().indexOf("px")>-1){this._width=parseInt(this._width,10);
}if(this._height.toString().indexOf("px")>-1){this._height=parseInt(this._height,10);
}a.RadSlidingZone.callBaseMethod(this,"endUpdate");
},dispose:function(){var e=this.getPanes();
for(var b=0,c=e.length;
b<c;
b++){var d=e[b];
if(d){d._moveRootToParent(true);
}}if(this._paneTabMoutTimeout){window.clearTimeout(this._paneTabMoutTimeout);
this._paneTabMoutTimeout=null;
}a.RadSplitterController.getInstance()._removeSlidingZone(this.get_id());
a.RadSlidingZone.callBaseMethod(this,"dispose");
},initialize:function(){a.RadSlidingZone.callBaseMethod(this,"initialize");
var b=this._getPanesContainer();
var c=this.get_element();
if(this._isVerticalSlide()){b=b.parentNode;
if(this.isTopDirection()&&$telerik.isIE&&Sys.Browser.version<8){c.style.marginTop="-1px";
}}else{if(this.isLeftDirection()&&$telerik.isSafari){c.style.marginLeft="-1px";
}}b.style.display="";
},set_clickToOpen:function(b){this._clickToOpen=b;
this.updateClientState();
},get_clickToOpen:function(){return this._clickToOpen;
},set_resizeStep:function(b){this._resizeStep=b;
this.updateClientState();
},get_resizeStep:function(){return this._resizeStep;
},set_slideDuration:function(b){this._slideDuration=b;
this.updateClientState();
},get_slideDuration:function(){return this._slideDuration;
},get_width:function(){return this._width;
},get_height:function(){return this._height;
},get_expandedPaneId:function(){return this._expandedPaneId;
},get_dockedPaneId:function(){return this._dockedPaneId;
},get_parent:function(){return this._getParentPane();
},_getParentPane:function(){var b=this._parent;
if(!b){b=this._parent=a.RadSplitterController.getInstance()._getParentPane(this.get_id());
}return b;
},get_splitter:function(){var b=this._splitter;
if(!b){b=this._splitter=a.RadSplitterController.getInstance()._getSplitter(this.get_id());
}return b;
},set_splitter:function(b){this._splitter=b;
},add_loaded:function(b){this.add_load(b);
},remove_loaded:function(b){this.remove_load(b);
},add_load:function(b){this.get_events().addHandler("load",b);
},remove_load:function(b){this.get_events().removeHandler("load",b);
},getPaneById:function(b){return this._getSlidingPanesById()[b];
},getTabsContainer:function(){return $get("RAD_SLIDING_ZONE_TABS_CONTAINER_"+this.get_id());
},_getPanesContainer:function(){return $get("RAD_SLIDING_ZONE_PANES_CONTAINER_"+this.get_id());
},dockPane:function(h){var c=this.getPaneById(h);
if(!c||!c.get_enableDock()){return false;
}var j=new Sys.CancelEventArgs();
c.raiseEvent("docking",j);
if(j.get_cancel()){return false;
}var i=this._dockedPaneId;
if(i&&!this.undockPane(i)){return false;
}c._moveRootToParent(true);
var g=this._getPanesContainer();
var l=this.isLeftDirection();
var n=this.isTopDirection();
this._dockingMode=true;
var f=this._getTabsContainerSize();
var b=f+c[this._isHorizontalSlide()?"get_width":"get_height"]();
var p=this.get_parent();
var e=p.getVarSize();
var d=(l||n)?a.SplitterDirection.Backward:a.SplitterDirection.Forward;
var o=e+this.get_splitter()._getAvailIncreaseDelta(p.get_indexInPanes(),d);
b=Math.min(b,o);
var k=b-e;
if(k!=0){p.resize(k,d);
}c._dock();
c._setTabDockedState();
var m=this.get_element();
if(n&&$telerik.isIE&&Sys.Browser.version<8){m.style.marginTop="0";
}else{if(l&&$telerik.isSafari){g.style.width="1px";
setTimeout(function(){g.style.width="";
},0);
m.style.marginLeft="0";
}}this._dockedPaneId=h;
this._dockingMode=false;
this.updateClientState();
c.raiseEvent("docked",new Sys.EventArgs());
return true;
},undockPane:function(d){var c=this.getPaneById(d);
if(!c){return false;
}var k=new Sys.CancelEventArgs();
c.raiseEvent("undocking",k);
if(k.get_cancel()){return false;
}if(!d){d=this._dockedPaneId;
}var g=this.get_parent();
if(g.get_collapsed()){return false;
}c._moveRootToParent(false);
this._dockingMode=true;
c._undock();
c._setTabDefaultState();
this._dockedPaneId=null;
var f=this.isTopDirection();
var h=this.isLeftDirection();
var e=this._getPanesContainer();
var b=this.get_element();
if(f&&$telerik.isIE&&Sys.Browser.version<8){b.style.marginTop="-1px";
}else{if(h&&$telerik.isSafari){e.style.width="1px";
setTimeout(function(){e.style.width="";
},0);
b.style.marginLeft="-1px";
}}var j=g.getVarSize();
var i=j-this._getTabsContainerSize();
var l=(h||f)?a.SplitterDirection.Backward:a.SplitterDirection.Forward;
g.resize(i*(-1),l);
this.updateClientState();
this._dockingMode=false;
c.raiseEvent("undocked",new Sys.EventArgs());
this._paneTabInMover=null;
return true;
},getPanes:function(){var b=this._slidingPanes;
if(!b){var c=this.get_id();
b=this._slidingPanes=a.RadSplitterController.getInstance()._getSlidingPanes(c);
}return b;
},_getSlidingPanesById:function(){var d=this._slidingPanesById;
if(!d){d=[];
var b=this.getPanes();
for(var c=0,f=b.length;
c<f;
c++){var e=b[c];
d[e.get_id()]=e;
}this._slidingPanesById=d;
}return d;
},expandPane:function(d){if(!d){return false;
}var e=this.getPaneById(d);
if(!e){return false;
}if(e._dockOnOpen){this.dockPane(d);
this._dockedPaneId=d;
this.updateClientState();
return false;
}var c=this._expandedPaneId;
if((d==this._paneTabInMover)||(c&&d==c)){return false;
}if(c&&!this.collapsePane(c)){this._paneTabInMover=null;
return;
}if(d==this._dockedPaneId){return false;
}var b=new Sys.CancelEventArgs();
e.raiseEvent("expanding",b);
if(b.get_cancel()){return false;
}this._paneTabInMover=d;
e._setTabExpandedState();
e._expand();
this._expandedPaneId=d;
this.updateClientState();
return true;
},collapsePane:function(f,c){if(this._expandedPaneId!=f){return true;
}if(this._dockedPaneId==f){return false;
}var e=this.getPaneById(f);
if(!e){return false;
}var d=new Sys.CancelEventArgs();
e.raiseEvent("collapsing",d);
if(d.get_cancel()){return false;
}e._setTabDefaultState();
var b=e._animation;
if(b){b._stopAnimation();
}if(!c){e._tableElement.style.position="";
}e._collapse();
this._expandedPaneId=null;
this.updateClientState();
this._paneTabInMover=null;
return true;
},isLeftDirection:function(){return(this._slideDirection==a.SplitterSlideDirection.Left);
},isRightDirection:function(){return(this._slideDirection==a.SplitterSlideDirection.Right);
},isTopDirection:function(){return(this._slideDirection==a.SplitterSlideDirection.Top);
},isBottomDirection:function(){return(this._slideDirection==a.SplitterSlideDirection.Bottom);
},_paneTab_OnMouseOver:function(c){if(this._clickToOpen){return;
}window.clearTimeout(this._paneTabMoutTimeout);
var b=this._getPaneIdFromTabElement(c.target);
this.expandPane(b);
},_paneTab_OnMouseOut:function(c){if(this._clickToOpen){return;
}var b=this._getPaneIdFromTabElement(c.target);
if(!b){return;
}if($telerik.isMouseOverElementEx(this.getPaneById(b).getTabContainer(),c)){return $telerik.cancelRawEvent(c);
}this._paneTabMoutTimeout=setTimeout(Function.createDelegate(this,function(){this._paneTabInMover=null;
this.collapsePane(b);
}),100);
},_paneTab_OnMouseDown:function(d){if(!this._clickToOpen){return;
}var f=d.target;
var b=this._getPaneIdFromTabElement(f);
var c=this._expandedPaneId;
if(c==b){this.collapsePane(b);
}else{this.expandPane(b);
}},_isHorizontalSlide:function(){return(this._slideDirection==a.SplitterSlideDirection.Left||this._slideDirection==a.SplitterSlideDirection.Right);
},_isVerticalSlide:function(){return !this._isHorizontalSlide();
},_getPaneIdFromTabElement:function(b){while(b&&b.tagName!="DIV"){b=b.parentNode;
}if(!b||b.id.indexOf("RAD_SLIDING_PANE_TAB_")==-1){return"";
}return b.id.substr("RAD_SLIDING_PANE_TAB_".length);
},_handleParentPaneResizing:function(g,l){if(this._dockingMode){return;
}var f=l.get_delta();
if(this._dockedPaneId){var c=this.getPaneById(this._dockedPaneId);
if(!c.get_enableResize()){l.set_cancel(true);
return;
}var j=this._getTabsContainerSize();
var d=j+(this._isHorizontalSlide())?c.get_minWidth():c.get_minHeight();
var i=j+(this._isHorizontalSlide())?c.get_maxWidth():c.get_maxHeight();
var e=c.get_slidingPaneBounds();
var k=(this._isHorizontalSlide())?e.width:e.height;
var b=k+f;
if(b>i||b<d){l.set_cancel(true);
return;
}var h=new a.PaneResizingEventArgs(f);
c.raiseEvent("resizing",h);
l.set_cancel(h.get_cancel());
}},_getTabsContainerSize:function(){var b=this.getTabsContainer();
return(this._isHorizontalSlide())?b.offsetWidth:b.offsetHeight;
},_handleParentPaneResized:function(h,m){var c=this._dockedPaneId;
if(this._dockingMode||!c){return;
}var c=this.getPaneById(c);
if(!c.get_enableResize()){return;
}var f=c.get_slidingPaneBounds();
var b=f.width;
var j=h.get_width()-m.get_oldWidth();
var k=b+j;
var d=f.height;
var l=h.get_height()-m.get_oldHeight();
var e=d+l;
c._setSlidingContainerSize(k,e);
var g=c.get_width();
var i=m.get_oldHeight();
var e=h.get_height();
c.set_width(k);
c.set_height(e);
c.raiseEvent("resized",new a.PaneResizedEventArgs(g,i));
},_handleSplitterResized:function(d,c){if(this._expandedPaneId){if(d.get_width()!=c.get_oldWidth()||d.get_height()!=c.get_oldHeight()){var b=this._expandedPaneId;
this.collapsePane(b);
this.expandPane(b);
}}},_splitterLoadHandler:function(){var e=this.get_parent();
e.add_resizing(Function.createDelegate(this,this._handleParentPaneResizing));
e.add_resized(Function.createDelegate(this,this._handleParentPaneResized));
var k=this.get_splitter();
k.add_resized(Function.createDelegate(this,this._handleSplitterResized));
if($telerik.quirksMode){var g=this.getPanes();
for(var b=0,j=g.length;
b<j;
b++){var h=g[b];
var c=h.get_element();
c.className=k.getContainerElement().className+" RadSlidingPaneQuirksMode "+c.className;
h._originalParent=h.get_element().parentNode;
h._moveRootToParent(false);
}}var d=this._initiallyDockedPaneId;
if(d!=null){this.dockPane(d);
}var f=this._initiallyExpandedPaneId;
if(f!=null){this.expandPane(f);
}this.updateClientState();
this.raiseEvent("load");
},saveClientState:function(){if(this.get_isUpdating()){return null;
}var f={dockedPaneId:this._dockedPaneId||"",expandedPaneId:this._expandedPaneId||""};
var b=["clickToOpen","resizeStep","slideDuration"];
for(var e=0,c=b.length;
e<c;
e++){var d=b[e];
f[d]=this["get_"+d]();
}return Sys.Serialization.JavaScriptSerializer.serialize(f);
}};
a.RadSlidingZone._preInitialize=function(b,d,c){a.RadSplitterController.getInstance()._addSlidingZone(b,d,c);
};
a.RadSlidingZone.registerClass("Telerik.Web.UI.RadSlidingZone",a.RadWebControl);
})();
Type.registerNamespace("Telerik.Web.UI");
(function(){$telerik.toSlidingPane=function(b){return b;
};
$telerik.findSlidingPane=$find;
var a=Telerik.Web.UI;
a.RadSlidingPane=function(b){a.RadSlidingPane.initializeBase(this,[b]);
this._title="";
this._enableResize=true;
this._enableDock=true;
this._dockOnOpen=false;
this._parentPane=null;
this._clickToOpen=false;
this._slideDirection=a.SplitterSlideDirection.Right;
this._slideDuration=300;
this._resizeBarSize=null;
this._isExpanded=false;
this._isDocked=false;
this._width=150;
this._height=150;
this._minWidth=60;
this._minHeight=60;
this._overlay=false;
this._isInitialSizeApplied=false;
this._popupBehavior=null;
this._popupElement=null;
this._contentElement=null;
this._tableElement=null;
this._tabContainer=null;
this._resizeElement=null;
this._originalParent=null;
this.GetContentContainer=this.getContentContainer;
this.GetContent=this.getContent;
this.SetContent=this.setContent;
this.GetDockIconElement=this.getDockIconElement;
this.GetUndockIconElement=this.getUndockIconElement;
this.GetCollapseIconElement=this.getCollapseIconElement;
this.GetSlidingContainerTitle=this.getSlidingContainerTitle;
this.GetSlidingPaneResizeContainer=this.getSlidingPaneResizeContainer;
this.GetTabContainer=this.getTabContainer;
this.HideTab=this.hideTab;
this.ShowTab=this.showTab;
this.IsTabDisplayed=this.isTabDisplayed;
};
a.RadSlidingPane.prototype={initialize:function(){a.RadSlidingPane.callBaseMethod(this,"initialize");
this._popupElement=this.get_element();
this._contentElement=this.getContentContainer();
this._tableElement=this._popupElement.getElementsByTagName("TABLE")[0];
this._tabContainer=this.getTabContainer();
this._resizeElement=this.getSlidingPaneResizeContainer();
var g=this._tabContainer;
$addHandlers(g,{mousedown:this._paneTab_OnMouseDown,mouseover:this._paneTab_OnMouseOver,mouseout:this._paneTab_OnMouseOut},this);
var b=this._popupElement;
$addHandlers(b,{mouseover:this._slidingContainer_OnMouseOver,mouseout:this._slidingContainer_OnMouseOut},this);
var c=this._resizeElement;
$addHandlers(c,{mouseover:this._resizeSlidePane_OnMouseOver,mouseout:this._resizeSlidePane_OnMouseOut,mousedown:this._resizeSlidePane_OnMouseDown},this);
c.setAttribute("unselectable","on");
var e=this.getDockIconElement();
$addHandlers(e,{mouseover:this._dockElement_OnMouseOver,mouseout:this._dockElement_OnMouseOut,mousedown:this._dockElement_OnMouseDown},this);
var f=this.getUndockIconElement();
$addHandlers(f,{mouseover:this._undockElement_OnMouseOver,mouseout:this._undockElement_OnMouseOut,mousedown:this._undockElement_OnMouseDown},this);
var d=this.getCollapseIconElement();
$addHandlers(d,{mouseover:this._collapseElement_OnMouseOver,mouseout:this._collapseElement_OnMouseOut,mousedown:this._collapseElement_OnMouseDown},this);
if(this._scrollingEnabled==null){this._scrollingEnabled=(this._scrolling!=a.SplitterPaneScrolling.None);
}if(this._scrollingEnabled&&this._persistScrollPosition){this._attachScrollHandler();
}this.updateClientState();
},dispose:function(){this._moveRootToParent(true);
this._originalParent=null;
var i=this._popupBehavior;
if(i){i.dispose();
this._popupBehavior=null;
}var f=this._animation;
if(this._expandAnimationEndedDelegate){if(f){f.remove_expandAnimationEnded(this._expandAnimationEndedDelegate);
}this._expandAnimationEndedDelegate=null;
}if(f){f.dispose();
this._animation=null;
}var j=this._tabContainer;
if(j){$clearHandlers(j);
}var b=this._popupElement;
if(b){$clearHandlers(b);
}this._popupElement=null;
var c=this._resizeElement;
if(c){$clearHandlers(c);
}this._resizeElement=null;
var e=this.getDockIconElement();
if(e){$clearHandlers(e);
}var h=this.getUndockIconElement();
if(h){$clearHandlers(h);
}var d=this.getCollapseIconElement();
if(d){$clearHandlers(d);
}var g=this._contentElement;
if(this._onScrollAttached&&g){$clearHandlers(g);
}this._contentElement=null;
a.RadSplitterController.getInstance()._removeSlidingPane(this.get_id());
a.RadSlidingPane.callBaseMethod(this,"dispose");
},get_parent:function(){return this._getSlidingZone();
},_getSlidingZone:function(){var b=this._parent;
if(!b){b=this._parent=a.RadSplitterController.getInstance()._getSlidingZone(this.get_id());
}return b;
},get_enableResize:function(){return this._enableResize;
},set_enableResize:function(b){this._enableResize=b;
this.updateClientState();
},get_enableDock:function(){return this._enableDock;
},set_enableDock:function(b){this._enableDock=b;
this.updateClientState();
},get_dockOnOpen:function(){return this._dockOnOpen;
},set_dockOnOpen:function(b){this._dockOnOpen=b;
this.updateClientState();
},set_title:function(b){this._title=b;
var d=this._getTitleContainerElement();
if(d!=null){d.innerHTML=(!$telerik.isIE&&this._isHorizontalSlide())?b.split("").join("<br/>"):b;
}var c=this.getSlidingContainerTitle();
if(c){c.innerHTML=b;
}this.updateClientState();
},get_title:function(){return this._title;
},get_expanded:function(){return this._isExpanded;
},get_docked:function(){return this._isDocked;
},get_overlay:function(){return this._overlay;
},set_overlay:function(c){this._overlay=c;
var b=this._popupBehavior;
if(b){b.set_overlay(this._overlay);
}},get_parentPane:function(){var b=this._parentPane;
if(!b){b=this._parentPane=a.RadSplitterController.getInstance()._getParentPane(this.get_id());
}return b;
},set_parentPane:function(b){this._parentPane=b;
},add_docked:function(b){this.get_events().addHandler("docked",b);
},remove_docked:function(b){this.get_events().removeHandler("docked",b);
},add_undocked:function(b){this.get_events().addHandler("undocked",b);
},remove_undocked:function(b){this.get_events().removeHandler("undocked",b);
},add_beforeDock:function(b){this.add_docking(b);
},remove_beforeDock:function(b){this.remove_docking(b);
},add_docking:function(b){this.get_events().addHandler("docking",b);
},remove_docking:function(b){this.get_events().removeHandler("docking",b);
},add_beforeUndock:function(b){this.add_undocking(b);
},remove_beforeUndock:function(b){this.remove_undocking(b);
},add_undocking:function(b){this.get_events().addHandler("undocking",b);
},remove_undocking:function(b){this.get_events().removeHandler("undocking",b);
},getContentContainer:function(){if(!this._contentElement){this._contentElement=$get("RAD_SLIDING_PANE_CONTENT_"+this.get_id());
}return this._contentElement;
},get_pane:function(){return this.get_parentPane().get_element();
},get_paneBounds:function(){var b=this.get_pane();
return $telerik.getBounds(b);
},_show:function(c,d){var b=this._popupBehavior;
b._setCoordinates(c,d);
b.show();
},get_slidingPaneBounds:function(){var c=this._popupElement;
var b=(c.style.top==""&&!this._isDocked);
if(b){this._setSlidingContainerSize();
}var d=$telerik.getBounds(c);
return d;
},_fixIeHeight:function(c,b){if($telerik.standardsMode){var d=(c.offsetHeight-parseInt(b));
if(d>0){var e=(parseInt(c.style.height)-d);
if(e>0){c.style.height=e+"px";
}}}},getContent:function(){return this._contentElement.innerHTML;
},setContent:function(b){this._contentElement.innerHTML=b;
},getDockIconElement:function(){return $get("RAD_SPLITTER_SLIDING_PANE_DOCK_"+this.get_id());
},getDockIconWrapperElement:function(){return this.getDockIconElement().parentNode;
},getUndockIconElement:function(){return $get("RAD_SPLITTER_SLIDING_PANE_UNDOCK_"+this.get_id());
},getUnDockIconWrapperElement:function(){return this.getUndockIconElement().parentNode;
},getCollapseIconElement:function(){return $get("RAD_SPLITTER_SLIDING_PANE_COLLAPSE_"+this.get_id());
},getCollapseIconWrapperElement:function(){return this.getCollapseIconElement().parentNode;
},getSlidingContainerTitle:function(){return $get("RAD_SPLITTER_SLIDING_TITLE_"+this.get_id());
},getSlidingPaneResizeContainer:function(){if(!this._resizeElement){this._resizeElement=$get("RAD_SPLITTER_SLIDING_ZONE_RESIZE_"+this.get_id());
}return this._resizeElement;
},getTabContainer:function(){if(!this._tabContainer){this._tabContainer=$get("RAD_SLIDING_PANE_TAB_"+this.get_id());
}return this._tabContainer;
},hideTab:function(){var b=this._tabContainer;
if(b==null){return;
}b.style.display="none";
},showTab:function(){var b=this._tabContainer;
if(b==null){return;
}b.style.display="";
},isTabDisplayed:function(){var b=this._tabContainer;
if(b==null){return false;
}return(b.style.display!="none");
},_getIsLeftDirection:function(){var b=$telerik.isRightToLeft(this.get_element());
return(this._isLeftDirection()&&!b)||(b&&this._isRightDirection());
},_getIsRightDirection:function(){var b=$telerik.isRightToLeft(this.get_element());
return(this._isRightDirection()&&!b)||(b&&this._isLeftDirection());
},_setTabDefaultState:function(){var b=this._tabContainer;
if(b==null){return false;
}Sys.UI.DomElement.removeCssClass(b,"rspPaneTabContainerDocked");
Sys.UI.DomElement.removeCssClass(b,"rspPaneTabContainerExpanded");
},_setTabDockedState:function(){var b=this._tabContainer;
if(b==null){return false;
}Sys.UI.DomElement.addCssClass(b,"rspPaneTabContainerDocked");
},_setTabExpandedState:function(){var b=this._tabContainer;
if(b==null){return false;
}Sys.UI.DomElement.addCssClass(b,"rspPaneTabContainerExpanded");
},_resizeSlidePane_OnMouseOver:function(c){var b=(this._isHorizontalSlide())?"rspSlideContainerResizeOver":"rspSlideContainerResizeOverHorizontal";
Sys.UI.DomElement.addCssClass(this._resizeElement,b);
},_resizeSlidePane_OnMouseOut:function(c){var b=(this._isHorizontalSlide())?"rspSlideContainerResizeOver":"rspSlideContainerResizeOverHorizontal";
Sys.UI.DomElement.removeCssClass(this._resizeElement,b);
},_resizeSlidePane_OnMouseDown:function(k){k.preventDefault();
k.stopPropagation();
var j=this._isHorizontalSlide();
this._maxDecreaseDelta=(j)?this.get_width()-this.get_minWidth():this.get_height()-this.get_minHeight();
var p=(j)?this.get_maxWidth()-this.get_width():this.get_maxHeight()-this.get_height();
var n=this.get_parentPane();
var d=n._getAvailIncreaseDelta();
var g=this.get_splitter()._getAvailDecreaseDelta(n.get_indexInPanes(),a.SplitterDirection.Forward);
var l=Math.min(g,d);
var i=this._getSlidingZone();
var h=i.get_dockedPaneId();
if(h!=null){var c=i.getPaneById(h);
l+=(j)?c.get_width():c.get_height();
}l-=(j)?this.get_width():this.get_height();
this._maxIncreaseDelta=Math.min(p,l);
if(this._getIsLeftDirection()||this._isTopDirection()){var f=this._maxIncreaseDelta;
this._maxIncreaseDelta=this._maxDecreaseDelta;
this._maxDecreaseDelta=f;
}var m=this._resizeElement;
var b=$telerik.getLocation(m);
if($telerik.isSafari&&j){var o=$telerik.getLocation(m.parentNode);
b.y=o.y;
}this._mouseStartX=k.clientX;
this._mouseStartY=k.clientY;
this._handlerStartLeftPos=b.x;
this._handlerStartTopPos=b.y;
this._currentDelta=0;
if(!this._helperBar){this._createResizeHelper();
}this._mouseUpResizeHandler=Function.createDelegate(this,this._resizeSlidePane_OnMouseUp);
this._mouseMoveResizeHandler=Function.createDelegate(this,this._resizeSlidePane_OnMouseMove);
$addHandler(document,"mouseup",this._mouseUpResizeHandler);
$addHandler(document,"mousemove",this._mouseMoveResizeHandler);
this._resizeMode=true;
return false;
},_resizeSlidePane_OnMouseUp:function(n){$telerik.cancelRawEvent(n);
$removeHandler(document,"mouseup",this._mouseUpResizeHandler);
$removeHandler(document,"mousemove",this._mouseMoveResizeHandler);
this._resizeMode=false;
var p=this._helperBar;
if(p){p.parentNode.removeChild(p);
this._helperBar=null;
this._helperBarDecoration=null;
}var d=this._isTopDirection();
var l=this._getIsLeftDirection();
if(l||d){this._currentDelta*=-1;
}if(!this.get_expanded()){return false;
}var m=this._currentDelta;
if(m&&m!=0){var g=new a.PaneResizingEventArgs(m);
this.raiseEvent("resizing",g);
if(!g.get_cancel()){var h=null;
var o=null;
var j=this._isHorizontalSlide();
var f=this.get_slidingPaneBounds();
if(j){h=f.width+m;
}else{o=f.height+m;
}this._setSlidingContainerSize(h,o);
var b=this._popupBehavior.get_x();
var c=this._popupBehavior.get_y();
if(l){b-=m;
}else{if(d){c-=m;
}}this._show(b,c);
var i=this.get_width();
var k=this.get_height();
if(j){this.set_width(h);
}else{this.set_height(o);
}$telerik.repaintChildren(this);
this.raiseEvent("resized",new a.PaneResizedEventArgs(i,k));
}}return false;
},_createResizeHelper:function(){var e=this._isHorizontalSlide();
var i=e?"w-resize":"n-resize";
var j=document.createElement("table");
var g=150;
j.style.position="absolute";
j.style.left=this._handlerStartLeftPos-(e?g:0)+"px";
j.style.top=this._handlerStartTopPos-(!e?g:0)+"px";
j.style.zIndex=this._popupElement.style.zIndex+1;
j.style.cursor=i;
j.style.border="0px none";
j.cellSpacing=0;
j.cellPadding=0;
j.unselectable="on";
document.body.insertBefore(j,document.body.firstChild);
Sys.UI.DomElement.addCssClass(j,"RadSplitter");
var f=document.createElement("tbody");
j.appendChild(f);
var c=document.createElement("tr");
f.appendChild(c);
var d=document.createElement("td");
c.appendChild(d);
var k=document.createElement("div");
k.style.margin=this._isSplitterVertical()?"0 150px":"150px 0";
k.style.cursor=i;
k.unselectable="on";
k.innerHTML="<!-- / -->";
d.appendChild(k);
Sys.UI.DomElement.addCssClass(k,"rspHelperBarSlideDrag");
var b={width:4,height:4};
var h=this.get_parentPane();
if(e){b.height=h.get_height();
}else{b.width=h.get_width();
}$telerik.setSize(k,b);
this._helperBar=j;
this._helperBarDecoration=k;
},_resizeSlidePane_OnMouseMove:function(i){this._resizeMode=true;
var j=this._helperBarDecoration;
Sys.UI.DomElement.removeCssClass(j,"rspHelperBarSlideError");
var d=this._isHorizontalSlide();
var h=(d)?i.clientX-this._mouseStartX:i.clientY-this._mouseStartY;
var b=false;
if(h<((-1)*this._maxDecreaseDelta)){b=true;
h=this._maxDecreaseDelta*(-1);
}else{if(h>this._maxIncreaseDelta){b=true;
h=this._maxIncreaseDelta;
}}var f=this._resizeStep;
if(f>0){h-=h%f;
}this._currentDelta=h;
var g=this._helperBar;
var c=150;
if(d){g.style.left=this._handlerStartLeftPos+h-c+"px";
}else{g.style.top=this._handlerStartTopPos+h-c+"px";
}if(b){Sys.UI.DomElement.addCssClass(j,"rspHelperBarSlideError");
}return $telerik.cancelRawEvent(i);
},_paneTab_OnMouseDown:function(b){var c=this._getSlidingZone();
c._paneTab_OnMouseDown(b);
},_paneTab_OnMouseOver:function(b){var c=this._getSlidingZone();
c._paneTab_OnMouseOver(b);
},_paneTab_OnMouseOut:function(b){var c=this._getSlidingZone();
c._paneTab_OnMouseOut(b);
},_slidingContainer_OnMouseOut:function(g){if(this.get_docked()||this._resizeMode||this._clickToOpen||!this.get_expanded()){return;
}if($telerik.isMouseOverElementEx(this._popupElement,g)){return;
}var d=this;
var b=function(){var e=d._getSlidingZone();
e._paneTabInMover=null;
e.collapsePane(d.get_id());
};
var c=this._getSlidingZone();
window.clearTimeout(c._paneTabMoutTimeout);
c._paneTabMoutTimeout=window.setTimeout(b,1000);
},_slidingContainer_OnMouseOver:function(b){if(this.get_docked()||this._resizeMode){return;
}window.clearTimeout(this._getSlidingZone()._paneTabMoutTimeout);
},_dockElement_OnMouseDown:function(b){if(b.button&&b.button!=1){return true;
}if(!this.get_expanded()){return;
}var c=this._getSlidingZone();
if(!c.collapsePane(this.get_id(),true)){return;
}c.dockPane(this.get_id());
this.getDockIconElement().className="rspSlideHeaderDockIcon";
},_dockElement_OnMouseOver:function(b){if(b.button&&b.button!=1){return true;
}Sys.UI.DomElement.addCssClass(this.getDockIconElement(),"rspSlideHeaderDockIconOver");
},_dockElement_OnMouseOut:function(b){if(b.button&&b.button!=1){return true;
}Sys.UI.DomElement.removeCssClass(this.getDockIconElement(),"rspSlideHeaderDockIconOver");
},_undockElement_OnMouseDown:function(b){if(b.button&&b.button!=1){return true;
}if(!this.get_docked()){return;
}this._getSlidingZone().undockPane(this.get_id());
},_undockElement_OnMouseOver:function(b){if(b.button&&b.button!=1){return true;
}Sys.UI.DomElement.addCssClass(this.getUndockIconElement(),"rspSlideHeaderUndockIconOver");
},_undockElement_OnMouseOut:function(b){if(b.button&&b.button!=1){return true;
}Sys.UI.DomElement.removeCssClass(this.getUndockIconElement(),"rspSlideHeaderUndockIconOver");
},_collapseElement_OnMouseDown:function(b){if(b.button&&b.button!=1){return true;
}if(!this.get_expanded()){return;
}var c=this._getSlidingZone();
c._paneTabInMover=null;
c.collapsePane(this.get_id());
},_collapseElement_OnMouseOver:function(b){if(b.button&&b.button!=1){return true;
}Sys.UI.DomElement.addCssClass(this.getCollapseIconElement(),"rspSlideHeaderCollapseIconOver");
},_collapseElement_OnMouseOut:function(b){if(b.button&&b.button!=1){return true;
}Sys.UI.DomElement.removeCssClass(this.getCollapseIconElement(),"rspSlideHeaderCollapseIconOver");
},_onExpandAnimationEnded:function(){this._tableElement.style.position="static";
if($telerik.isFirefox){this._configureScrolling();
Sys.UI.DomElement.removeCssClass(this._contentElement,"rspHideContentOverflow");
}if($telerik.getVisible(this.get_element())){this._showOverlayElement(true);
}this.setScrollPos(this._scrollLeft,this._scrollTop);
$telerik.repaintChildren(this);
this.raiseEvent("expanded",new Sys.EventArgs());
},_expandSlidingContainer:function(){this._showOverlayElement(false);
if($telerik.isFirefox){var b=this._contentElement;
b.style.overflow="hidden";
Sys.UI.DomElement.addCssClass(b,"rspHideContentOverflow");
}var d=this._tableElement;
var c=$telerik.getOuterSize(d);
var e=a.jSlideDirection.Right;
if(this._getIsLeftDirection()){e=a.jSlideDirection.Left;
d.style.left=c.width+"px";
}else{if(this._isBottomDirection()){e=a.jSlideDirection.Down;
d.style.top=-c.height+"px";
}else{if(this._isTopDirection()){e=a.jSlideDirection.Up;
d.style.top=c.height+"px";
}else{d.style.left=-c.width+"px";
}}}if(!this._animation){var f=new a.AnimationSettings({duration:this._slideDuration});
var g=new a.jSlide(d,f,null,false);
g.initialize();
g.set_direction(e);
this._expandAnimationEndedDelegate=Function.createDelegate(this,this._onExpandAnimationEnded);
g.add_expandAnimationEnded(this._expandAnimationEndedDelegate);
this._animation=g;
}this._animation.expand();
},_collapseSlidingContainer:function(){try{this._animation.stop();
}catch(b){}this._hideSlidingContainer();
this.raiseEvent("collapsed",new Sys.EventArgs());
},_setSlidingContainerSize:function(e,d){var b=$telerik.getSize(this.get_parentPane()._contentElement);
var i=this._isVerticalSlide();
if(e==null){e=(!i)?this.get_width():b.width;
}if(d==null){d=i?this.get_height():b.height;
}var c=this._contentElement;
if($telerik.isSafari){c.style.width=e+"px";
c.style.height=d+"px";
}var f=this._popupElement;
if(parseInt(f.style.width)!=e){f.style.width=e+"px";
}if(parseInt(f.style.height)!=d){f.style.height=d+"px";
}var h=this._getResizeElementSize();
var g={height:(d-this._getHeaderHeight()-(i?h.height:0)),width:(e-(!i?h.width:0))};
this._setContentOuterSize(g);
this._isInitialSizeApplied=true;
},_getHeaderHeight:function(){var c=0;
var b=$telerik.getElementByClassName(this._tableElement,"rspSlideTitleContainer","td");
if(b){c=$telerik.getOuterSize(b).height;
}return c;
},_getResizeElementSize:function(){var c={width:0,height:0};
if(this._enableResize){var b=this._resizeElement;
if("none"!=$telerik.getCurrentStyle(b,"display","")){c=$telerik.getOuterSize(b);
}}return c;
},_setContentOuterSize:function(d){var f=this._contentElement;
var c=$telerik.getBorderBox(f);
var b=$telerik.getPaddingBox(f);
var e=$telerik.getMarginBox(f);
d.height-=(c.vertical+b.vertical+e.vertical);
if(parseInt(f.style.height)!=d.height&&d.height>=0){f.style.height=d.height+"px";
}d.width-=(c.horizontal+b.horizontal+e.horizontal);
if(parseInt(f.style.width)!=d.width&&d.width>=0){f.style.width=d.width+"px";
}},_hideSlidingContainer:function(){var b=this._popupElement;
b.style.top="";
b.style.left="";
this._showOverlayElement(false);
},_dockSlidingContainer:function(){this._popupElement.style.position="static";
this._tableElement.style.position="static";
this._showOverlayElement(false);
},_unDockSlidingContainer:function(){this._popupElement.style.position="";
this._tableElement.style.position="";
this._showOverlayElement(true);
},_setSlidingContainerResizable:function(c){var e=this._resizeElement;
var b=this._isVerticalSlide();
if(b){e=e.parentNode;
}if(c&&e.style.display==""){return;
}if(this._enableResize){var f=this._resizeBarSize;
if(null==f){f=this._getResizeElementSize()[b?"height":"width"];
if(f>0){this._resizeBarSize=f;
}}if(c){f*=-1;
}var d=this._contentElement;
if(b){d.style.height=parseInt(d.style.height)+f+"px";
}else{d.style.width=parseInt(d.style.width)+f+"px";
}}e.style.display=(c)?"":"none";
},_setIconsExpandedState:function(){this._hideAllIcons();
this.getDockIconWrapperElement().style.display=(this.get_enableDock())?"":"none";
this.getCollapseIconWrapperElement().style.display="";
},_setIconsDockedState:function(){this._hideAllIcons();
this.getUnDockIconWrapperElement().style.display="";
},_hideAllIcons:function(){this.getDockIconWrapperElement().style.display="none";
this.getUnDockIconWrapperElement().style.display="none";
this.getCollapseIconWrapperElement().style.display="none";
},_getTitleContainerElement:function(){return $get("RAD_SLIDING_PANE_TEXT_"+this.get_id());
},_dock:function(){if(!this._isInitialSizeApplied){this._setSlidingContainerSize();
}this._setIconsDockedState();
this._setSlidingContainerResizable(false);
this._dockSlidingContainer();
this.setScrollPos(this._scrollLeft,this._scrollTop);
$telerik.repaintChildren(this);
this._isExpanded=false;
this._isDocked=true;
},_undock:function(){this._isExpanded=false;
this._isDocked=false;
this._setSlidingContainerResizable(this._enableResize);
this._unDockSlidingContainer();
this._hideSlidingContainer();
},_expand:function(){var f=this._getSlidingZone().getTabsContainer();
var g=this._popupElement;
if(!this._popupBehavior){var h=(new Date()-100)+"PopupBehavior";
this._popupBehavior=$create(Telerik.Web.PopupBehavior,{id:h,parentElement:f,overlay:this._overlay,keepInScreenBounds:false,manageVisibility:false},null,null,g);
}this._setSlidingContainerResizable(this._enableResize);
this._setIconsExpandedState();
var b=0;
var c=0;
var d=this.get_slidingPaneBounds();
var e=$telerik.getSize(f);
if(this._getIsRightDirection()){b=e.width;
}else{if(this._getIsLeftDirection()){b=-d.width;
}else{if(this._isBottomDirection()){c=e.height;
}else{if(this._isTopDirection()){c=-d.height;
}}}}this._show(b,c);
this._expandSlidingContainer();
this._isExpanded=true;
this._isDocked=false;
},_collapse:function(){this._isExpanded=false;
this._isDocked=false;
this._collapseSlidingContainer();
},_isLeftDirection:function(){return(this._slideDirection==a.SplitterSlideDirection.Left);
},_isRightDirection:function(){return(this._slideDirection==a.SplitterSlideDirection.Right);
},_isTopDirection:function(){return(this._slideDirection==a.SplitterSlideDirection.Top);
},_isBottomDirection:function(){return(this._slideDirection==a.SplitterSlideDirection.Bottom);
},_isHorizontalSlide:function(){return(this._slideDirection==a.SplitterSlideDirection.Left||this._slideDirection==a.SplitterSlideDirection.Right);
},_isVerticalSlide:function(){return !this._isHorizontalSlide();
},saveClientState:function(){var e=this.getScrollPos();
var d={_scrollLeft:e.left,_scrollTop:e.top};
var f=["width","height","title","enableResize","minWidth","maxWidth","minHeight","maxHeight","enableDock"];
for(var b=0,g=f.length;
b<g;
b++){var c=f[b];
d[c]=this["get_"+c]();
}return Sys.Serialization.JavaScriptSerializer.serialize(d);
},_getOverlayElement:function(){return this._popupElement._hideWindowedElementsIFrame;
},_showOverlayElement:function(b){var c=this._getOverlayElement();
if(!c){return;
}c.style.display=b?"":"none";
},_getRadioButtons:function(){var c=this._contentElement.getElementsByTagName("input");
var d=[];
for(var b=0,f=c.length;
b<f;
b++){var e=c[b];
if(e.type=="radio"){d.push(e);
}}return d;
},_getRadioButtonsStatus:function(c){var e=[];
for(var b=0,d=c.length;
b<d;
b++){e.push(c[b].getAttribute("checked"));
}return e;
},_restoreRadioButtonsStatus:function(d,c){for(var b=c.length-1;
b>=0;
b--){if(d.length==0){break;
}c[b].setAttribute("checked",d.pop());
}},_moveRootToParent:function(f){if(!$telerik.quirksMode){return;
}var b=(f)?this._originalParent:this.get_splitter().get_element();
var d=this._popupElement;
if(!d){return;
}var e=d.parentNode;
if(!b||!e||b.id==e.id){return;
}if($telerik.isIE){var c=this._getRadioButtons();
var g=this._getRadioButtonsStatus(c);
}e.removeChild(d);
b.appendChild(d);
if($telerik.isIE){this._restoreRadioButtonsStatus(g,c);
}}};
a.RadSlidingPane._preInitialize=function(b,f,c,d,e){a.RadSplitterController.getInstance()._addSlidingPane(b,f,c,d,e);
};
a.RadSlidingPane.registerClass("Telerik.Web.UI.RadSlidingPane",a.SplitterPaneBase);
})();
