Telerik.Web.UI.RadMenuItemEventArgs=function(_1,_2){
Telerik.Web.UI.RadMenuItemEventArgs.initializeBase(this);
this._item=_1;
this._domEvent=_2||null;
};
Telerik.Web.UI.RadMenuItemEventArgs.prototype={get_item:function(){
return this._item;
},get_domEvent:function(){
return this._domEvent;
}};
Telerik.Web.UI.RadMenuItemEventArgs.registerClass("Telerik.Web.UI.RadMenuItemEventArgs",Sys.EventArgs);
Telerik.Web.UI.RadMenuItemCancelEventArgs=function(_3,_4){
Telerik.Web.UI.RadMenuItemCancelEventArgs.initializeBase(this);
this._item=_3;
this._domEvent=_4||null;
};
Telerik.Web.UI.RadMenuItemCancelEventArgs.prototype={get_item:function(){
return this._item;
},get_domEvent:function(){
return this._domEvent;
}};
Telerik.Web.UI.RadMenuItemCancelEventArgs.registerClass("Telerik.Web.UI.RadMenuItemCancelEventArgs",Sys.CancelEventArgs);
Telerik.Web.UI.RadMenuMouseOverEventArgs=function(_5,_6){
Telerik.Web.UI.RadMenuMouseOverEventArgs.initializeBase(this,[_5,_6||null]);
};
Telerik.Web.UI.RadMenuMouseOverEventArgs.registerClass("Telerik.Web.UI.RadMenuMouseOverEventArgs",Telerik.Web.UI.RadMenuItemEventArgs);
Telerik.Web.UI.RadMenuMouseOutEventArgs=function(_7,_8){
Telerik.Web.UI.RadMenuMouseOutEventArgs.initializeBase(this,[_7,_8||null]);
};
Telerik.Web.UI.RadMenuMouseOutEventArgs.registerClass("Telerik.Web.UI.RadMenuMouseOutEventArgs",Telerik.Web.UI.RadMenuItemEventArgs);
Telerik.Web.UI.RadMenuItemFocusEventArgs=function(_9,_a){
Telerik.Web.UI.RadMenuItemFocusEventArgs.initializeBase(this,[_9,_a||null]);
};
Telerik.Web.UI.RadMenuItemFocusEventArgs.registerClass("Telerik.Web.UI.RadMenuItemFocusEventArgs",Telerik.Web.UI.RadMenuItemEventArgs);
Telerik.Web.UI.RadMenuItemBlurEventArgs=function(_b,_c){
Telerik.Web.UI.RadMenuItemBlurEventArgs.initializeBase(this,[_b,_c||null]);
};
Telerik.Web.UI.RadMenuItemBlurEventArgs.registerClass("Telerik.Web.UI.RadMenuItemBlurEventArgs",Telerik.Web.UI.RadMenuItemEventArgs);
Telerik.Web.UI.RadMenuItemClickingEventArgs=function(_d,_e){
Telerik.Web.UI.RadMenuItemClickingEventArgs.initializeBase(this,[_d,_e||null]);
};
Telerik.Web.UI.RadMenuItemClickingEventArgs.registerClass("Telerik.Web.UI.RadMenuItemClickingEventArgs",Telerik.Web.UI.RadMenuItemCancelEventArgs);
Telerik.Web.UI.RadMenuItemClickedEventArgs=function(_f,_10){
Telerik.Web.UI.RadMenuItemClickedEventArgs.initializeBase(this,[_f,_10||null]);
};
Telerik.Web.UI.RadMenuItemClickedEventArgs.registerClass("Telerik.Web.UI.RadMenuItemClickedEventArgs",Telerik.Web.UI.RadMenuItemEventArgs);
Telerik.Web.UI.RadMenuItemOpeningEventArgs=function(_11,_12){
Telerik.Web.UI.RadMenuItemOpeningEventArgs.initializeBase(this,[_11,_12||null]);
};
Telerik.Web.UI.RadMenuItemOpeningEventArgs.registerClass("Telerik.Web.UI.RadMenuItemOpeningEventArgs",Telerik.Web.UI.RadMenuItemCancelEventArgs);
Telerik.Web.UI.RadMenuItemOpenedEventArgs=function(_13,_14){
Telerik.Web.UI.RadMenuItemOpenedEventArgs.initializeBase(this,[_13,_14||null]);
};
Telerik.Web.UI.RadMenuItemOpenedEventArgs.registerClass("Telerik.Web.UI.RadMenuItemOpenedEventArgs",Telerik.Web.UI.RadMenuItemEventArgs);
Telerik.Web.UI.RadMenuItemClosingEventArgs=function(_15,_16){
Telerik.Web.UI.RadMenuItemClosingEventArgs.initializeBase(this,[_15,_16||null]);
};
Telerik.Web.UI.RadMenuItemClosingEventArgs.registerClass("Telerik.Web.UI.RadMenuItemClosingEventArgs",Telerik.Web.UI.RadMenuItemCancelEventArgs);
Telerik.Web.UI.RadMenuItemClosedEventArgs=function(_17,_18){
Telerik.Web.UI.RadMenuItemClosedEventArgs.initializeBase(this,[_17,_18||null]);
};
Telerik.Web.UI.RadMenuItemClosedEventArgs.registerClass("Telerik.Web.UI.RadMenuItemClosedEventArgs",Telerik.Web.UI.RadMenuItemEventArgs);
Telerik.Web.UI.RadMenuItemPopulatingEventArgs=function(_19,_1a){
Telerik.Web.UI.RadMenuItemPopulatingEventArgs.initializeBase(this,[_19]);
this._context=_1a;
};
Telerik.Web.UI.RadMenuItemPopulatingEventArgs.prototype={get_context:function(){
return this._context;
}};
Telerik.Web.UI.RadMenuItemPopulatingEventArgs.registerClass("Telerik.Web.UI.RadMenuItemPopulatingEventArgs",Telerik.Web.UI.RadMenuItemCancelEventArgs);
Telerik.Web.UI.RadMenuItemPopulatedEventArgs=function(_1b){
Telerik.Web.UI.RadMenuItemPopulatedEventArgs.initializeBase(this,[_1b]);
};
Telerik.Web.UI.RadMenuItemPopulatedEventArgs.registerClass("Telerik.Web.UI.RadMenuItemPopulatedEventArgs",Telerik.Web.UI.RadMenuItemEventArgs);
Telerik.Web.UI.RadMenuItemPopulationFailedEventArgs=function(_1c,_1d){
Telerik.Web.UI.RadMenuItemPopulationFailedEventArgs.initializeBase(this,[_1c]);
this._errorMessage=_1d;
};
Telerik.Web.UI.RadMenuItemPopulationFailedEventArgs.prototype={get_errorMessage:function(){
return this._errorMessage;
}};
Telerik.Web.UI.RadMenuItemPopulationFailedEventArgs.registerClass("Telerik.Web.UI.RadMenuItemPopulationFailedEventArgs",Telerik.Web.UI.RadMenuItemCancelEventArgs);
Type.registerNamespace("Telerik.Web.UI");
Telerik.Web.UI.ItemFlow=function(){
};
Telerik.Web.UI.ItemFlow.prototype={Vertical:0,Horizontal:1};
Telerik.Web.UI.ItemFlow.registerEnum("Telerik.Web.UI.ItemFlow");
Telerik.Web.UI.ExpandDirection=function(){
};
Telerik.Web.UI.ExpandDirection.prototype={Auto:0,Up:1,Down:2,Left:3,Right:4};
Telerik.Web.UI.ExpandDirection.registerEnum("Telerik.Web.UI.ExpandDirection");
Telerik.Web.UI.RadMenu=function(_1e){
Telerik.Web.UI.RadMenu.initializeBase(this,[_1e]);
this._childTypeName="Telerik.Web.UI.RadMenuItem";
this._itemData=null;
this._expandAnimation=new Telerik.Web.UI.AnimationSettings({});
this._expandDelay=100;
this._collapseAnimation=new Telerik.Web.UI.AnimationSettings({});
this._collapseDelay=500;
this._flow=Telerik.Web.UI.ItemFlow.Horizontal;
this._defaultGroupSettings=new Telerik.Web.UI.RadMenuItemGroupSettings({});
this._enableAutoScroll=false;
this._autoScrollMinimumHeight=50;
this._autoScrollMinimumWidth=50;
this._enableScreenBoundaryDetection=true;
this._clickToOpen=false;
this._childListElement=null;
this._postBackReference=null;
this._onClickDelegate=null;
this._webServiceSettings=new Telerik.Web.UI.WebServiceSettings({});
this._persistLoadOnDemandItems=true;
this._enableOverlay=true;
this._enabled=true;
this._visible=true;
this._openedItem=null;
this._lastOpenedItem=null;
this._childrenDetached=false;
this._originalZIndex=null;
this._defaultZIndex=7000;
this._zIndexIncrementDepth=0;
this._fireEvents=true;
this._webServiceLoader=null;
this._loadingTemplate="";
this._onMouseOutDelegate=null;
this._onClickDelegate=null;
this._onResizeDelegate=null;
this._aboutToCollapse=false;
this._rightToLeft=null;
this._skin=null;
};
Telerik.Web.UI.RadMenu._createChildControls=function(_1f,_20){
var _21=_1f.get_itemData();
if(!_21){
return;
}
var _22=$telerik.getChildrenByTagName(_1f.get_childListElement(),"li");
Sys.Debug.assert(_21.length==_22.length,"Length of elements and json must be the same!");
for(var i=0;i<_21.length;i++){
var _24=new Telerik.Web.UI.RadMenuItem();
_20.add(_24);
_24._initialize(_21[i],_22[i]);
}
};
Telerik.Web.UI.RadMenu._adjustChildrenWidth=function(_25,_26){
var _27=_25._getControl();
var _28=_25.get_items();
var _29=_28.get_count();
if(_26){
for(var i=0;i<_29;i++){
_28.getItem(i)._clearWidth();
}
}
var _2b=Telerik.Web.UI.RadMenu._getMaxChildWidth(_25)+"px";
Telerik.Web.UI.RadMenu._setChildrenWidth(_25,_2b);
};
Telerik.Web.UI.RadMenu._getMaxChildWidth=function(_2c){
var _2d=0;
var _2e=_2c._getControl();
var _2f=_2c.get_items();
var _30=_2f.get_count();
for(var i=0;i<_30;i++){
if(_2e.get_rightToLeft()){
var _32=_2f.getItem(i).get_imageElement();
if(_32){
_32.style.styleFloat="left";
_32.style.cssFloat="left";
}
}
var _33=_2f.getItem(i)._getWidth();
_2d=Math.max(_33,_2d);
}
if(_2c.get_groupSettings){
groupWidth=_2c.get_groupSettings().get_width();
if(groupWidth){
_2d=groupWidth;
}
}
return _2d;
};
Telerik.Web.UI.RadMenu._setChildrenWidth=function(_34,_35){
var _36=_34._getControl();
var _37=_34.get_items();
var _38=_37.get_count();
for(var i=0;i<_38;i++){
if(_36.get_rightToLeft()){
var _3a=_37.getItem(i).get_imageElement();
if(_3a){
_3a.style.styleFloat="right";
_3a.style.cssFloat="right";
}
}
_37.getItem(i)._setWidth(_35);
}
if($telerik.isSafari){
var _3b=_34.get_childListElement();
_3b.style.width=_35;
}
};
Telerik.Web.UI.RadMenu._adjustRootItemWidth=function(_3c,_3d){
var _3e=$get(_3c);
var _3f=Telerik.Web.UI.RadMenu._getMaxRootItemWidth(_3e,_3d||null);
Telerik.Web.UI.RadMenu._setRootItemWidth(_3e,_3f,_3d||null);
};
Telerik.Web.UI.RadMenu._getChildListElement=function(_40){
var _41=$telerik.getFirstChildByTagName(_40,"ul",0);
if(!_41){
var _42=$telerik.getFirstChildByTagName(_40,"div",0);
_41=$telerik.getFirstChildByTagName(_42,"ul",0);
if(!_41){
var _43=_42;
_42=$telerik.getFirstChildByTagName(_43,"div",0);
_41=$telerik.getFirstChildByTagName(_42,"ul",0);
}
}
return _41;
};
Telerik.Web.UI.RadMenu._getMaxRootItemWidth=function(_44,_45){
if(!_45){
_45=Telerik.Web.UI.RadMenu._getChildListElement(_44);
}
var _46=_45.childNodes;
var _47=_46.length;
var _48=0;
for(var i=0;i<_47;i++){
var _4a=_46[i];
if(_4a.nodeType===3){
continue;
}
var _4b=$telerik.getFirstChildByTagName(_4a,"a",0);
var _4c;
if(_4b){
_4c=_4b.offsetWidth;
}else{
_4c=_4a.offsetWidth;
}
_48=Math.max(_48,_4c);
}
return _48;
};
Telerik.Web.UI.RadMenu._setRootItemWidth=function(_4d,_4e,_4f){
if(!_4f){
_4f=Telerik.Web.UI.RadMenu._getChildListElement(_4d);
}
var _50=_4f.childNodes;
var _51=_50.length;
if($telerik.isOpera){
_4f.style.cssFloat="none";
}
if(_4e==0){
return;
}
for(var i=0;i<_51;i++){
var _53=_50[i];
if(_53.nodeType==3){
continue;
}
var _54=$telerik.getFirstChildByTagName(_53,"a",0);
if(!_54){
_54=_53;
}
var _55=_4e;
var _56=$telerik.getPaddingBox(_54).horizontal;
var _57=$telerik.getBorderBox(_54).horizontal;
_55-=_56+_57;
var _58=_54.style.width;
if(!_58||_55!=_58){
_54.style.width=_55+"px";
}
}
if($telerik.isSafari){
_4f.style.width=_4e;
}
if(_4d.style.width===""&&Telerik.Web.UI.RadMenu._requiresRightToLeft(_4d)){
_4d.style.width=_4e+"px";
}
};
Telerik.Web.UI.RadMenu._requiresRightToLeft=function(_59){
var _5a=_59;
while(_5a.nodeType!==9){
if(_5a.dir=="rtl"){
return true;
}
_5a=_5a.parentNode;
}
return false;
};
Telerik.Web.UI.RadMenu._adjustListWidth=function(_5b){
var _5c=_5b._getControl();
if(_5c.get_rightToLeft()){
Telerik.Web.UI.RadMenu._adjustChildrenWidth(_5b);
}
var _5d=_5b.get_childListElement();
var _5e=0;
for(var i=0;i<_5d.childNodes.length;i++){
var _60=_5d.childNodes[i];
if(_60.nodeType==3){
continue;
}
_5e+=_60.offsetWidth;
_60.style.clear="none";
}
_5d.style.width=_5e+"px";
};
Telerik.Web.UI.RadMenu.prototype={initialize:function(){
Telerik.Web.UI.RadMenu.callBaseMethod(this,"initialize");
var _61=this.get_element();
if(this.get_rightToLeft()){
this._initRightToLeft();
}
if(this._flow==Telerik.Web.UI.ItemFlow.Vertical){
var _62=this.get_element().id;
Telerik.Web.UI.RadMenu._adjustRootItemWidth(_62,this.get_childListElement());
}
this._originalZIndex=parseInt($telerik.getCurrentStyle(_61,"zIndex"));
if(!this._originalZIndex){
_61.style.zIndex=this._defaultZIndex;
this._originalZIndex=this._defaultZIndex;
}
this._onClickDelegate=Function.createDelegate(this,this._onClick);
$addHandler(document,"click",this._onClickDelegate);
if(!this.get_clickToOpen()){
if($telerik.isIE){
this._onMouseOutDelegate=Function.createDelegate(this,this._onMouseOut);
$addHandler(document,"mouseout",this._onMouseOutDelegate);
}
}
this._onResizeDelegate=Function.createDelegate(this,this._onResize);
$addHandler(window,"resize",this._onResizeDelegate);
this._eventMap.addHandlerForClassName("mouseover","rmItem",this._onItemMouseOver);
this._eventMap.addHandlerForClassName("mouseout","rmItem",this._onItemMouseOut);
this._eventMap.addHandlerForClassName("dragstart","rmItem",this._onItemDragStart);
this._eventMap.addHandlerForClassName("click","rmLink",this._onLinkClick);
this._eventMap.addHandlerForClassName("mouseover","rmLink",this._onLinkMouseOver);
this._eventMap.addHandlerForClassName("mouseout","rmLink",this._onLinkMouseOut);
this._eventMap.addHandlerForClassName("mousedown","rmLink",this._onLinkMouseDown);
this._eventMap.addHandlerForClassName("mouseup","rmLink",this._onLinkMouseUp);
this._eventMap.addHandlerForClassName("blur","rmLink",this._onLinkBlur);
this._eventMap.addHandlerForClassName("deactivate","rmLink",this._onLinkBlur);
this._eventMap.addHandlerForClassName("focus","rmLink",this._onLinkFocus);
this._eventMap.addHandlerForClassName("activate","rmLink",this._onLinkFocus);
this._eventMap.addHandlerForClassName("keydown","rmLink",this._onLinkKeyDown);
this._eventMap.addHandlerForClassName("mousedown","rmTopArrow",this._onTopArrowMouseDown);
this._eventMap.addHandlerForClassName("mouseup","rmTopArrow",this._onTopArrowMouseUp);
this._eventMap.addHandlerForClassName("mouseover","rmTopArrow",this._onTopArrowMouseOver);
this._eventMap.addHandlerForClassName("mouseout","rmTopArrow",this._onTopArrowMouseOut);
this._eventMap.addHandlerForClassName("click","rmTopArrow",this._onScrollArrowClicked);
this._eventMap.addHandlerForClassName("mousedown","rmBottomArrow",this._onBottomArrowMouseDown);
this._eventMap.addHandlerForClassName("mouseup","rmBottomArrow",this._onBottomArrowMouseUp);
this._eventMap.addHandlerForClassName("mouseover","rmBottomArrow",this._onBottomArrowMouseOver);
this._eventMap.addHandlerForClassName("mouseout","rmBottomArrow",this._onBottomArrowMouseOut);
this._eventMap.addHandlerForClassName("click","rmBottomArrow",this._onScrollArrowClicked);
this._eventMap.addHandlerForClassName("mousedown","rmLeftArrow",this._onLeftArrowMouseDown);
this._eventMap.addHandlerForClassName("mouseup","rmLeftArrow",this._onLeftArrowMouseUp);
this._eventMap.addHandlerForClassName("mouseover","rmLeftArrow",this._onLeftArrowMouseOver);
this._eventMap.addHandlerForClassName("mouseout","rmLeftArrow",this._onLeftArrowMouseOut);
this._eventMap.addHandlerForClassName("click","rmLeftArrow",this._onScrollArrowClicked);
this._eventMap.addHandlerForClassName("mousedown","rmRightArrow",this._onRightArrowMouseDown);
this._eventMap.addHandlerForClassName("mouseup","rmRightArrow",this._onRightArrowMouseUp);
this._eventMap.addHandlerForClassName("mouseover","rmRightArrow",this._onRightArrowMouseOver);
this._eventMap.addHandlerForClassName("mouseout","rmRightArrow",this._onRightArrowMouseOut);
this._eventMap.addHandlerForClassName("click","rmRightArrow",this._onScrollArrowClicked);
if(!this.get_enabled()){
this.set_enabled(false);
}
this._raiseEvent("load",null);
},dispose:function(){
Telerik.Web.UI.RadMenu.callBaseMethod(this,"dispose");
if(this._onClickDelegate){
$removeHandler(document,"click",this._onClickDelegate);
this._onClickDelegate=null;
}
if(this._onMouseOutDelegate){
$removeHandler(document,"mouseout",this._onMouseOutDelegate);
this._onMouseOutDelegate=null;
}
if(this._onResizeDelegate){
$removeHandler(window,"resize",this._onResizeDelegate);
this._onResizeDelegate=null;
}
if(this._eventMap){
this._eventMap.dispose();
this._eventMap=null;
}
},repaint:function(){
if(this._flow==Telerik.Web.UI.ItemFlow.Vertical){
Telerik.Web.UI.RadMenu._adjustRootItemWidth(this.get_id(),this.get_childListElement());
}
},get_items:function(){
return this._getChildren();
},set_items:function(_63){
this._children=_63;
},get_enableScreenBoundaryDetection:function(){
return this._enableScreenBoundaryDetection;
},set_enableScreenBoundaryDetection:function(_64){
this._enableScreenBoundaryDetection=_64;
},get_enableAutoScroll:function(){
return this._enableAutoScroll;
},set_enableAutoScroll:function(_65){
this._enableAutoScroll=_65;
},get_autoScrollMinimumHeight:function(){
return this._autoScrollMinimumHeight;
},set_autoScrollMinimumHeight:function(_66){
this._autoScrollMinimumHeight=_66;
},get_autoScrollMinimumWidth:function(){
return this._autoScrollMinimumWidth;
},set_autoScrollMinimumWidth:function(_67){
this._autoScrollMinimumWidth=_67;
},get_childListElement:function(){
if(!this._childListElement){
this._childListElement=$telerik.getFirstChildByTagName(this.get_element(),"ul",0);
}
return this._childListElement;
},get_expandAnimation:function(){
return this._expandAnimation;
},set_expandAnimation:function(_68){
var _69=Sys.Serialization.JavaScriptSerializer.deserialize(_68);
this._expandAnimation=new Telerik.Web.UI.AnimationSettings(_69);
},get_collapseAnimation:function(){
return this._collapseAnimation;
},set_collapseAnimation:function(_6a){
var _6b=Sys.Serialization.JavaScriptSerializer.deserialize(_6a);
this._collapseAnimation=new Telerik.Web.UI.AnimationSettings(_6b);
},get_defaultGroupSettings:function(){
return this._defaultGroupSettings;
},set_defaultGroupSettings:function(_6c){
var _6d=Sys.Serialization.JavaScriptSerializer.deserialize(_6c);
this._defaultGroupSettings=new Telerik.Web.UI.RadMenuItemGroupSettings(_6d);
},get_itemData:function(){
return this._itemData;
},set_itemData:function(_6e){
this._itemData=_6e;
},set_enabled:function(_6f){
Telerik.Web.UI.RadMenu.callBaseMethod(this,"set_enabled",[_6f]);
if(!this.get_isInitialized()){
return;
}
var _70=this.get_element();
var _71=this.get_items();
var _72=_71.get_count();
if(!_6f){
_70.disabled="disabled";
this.disableEvents();
for(var i=0;i<_72;i++){
_71.getItem(i).disable();
}
}else{
_70.disabled="";
this.enableEvents();
for(var i=0;i<_72;i++){
_71.getItem(i).enable();
}
}
},get_allItems:function(){
return this._getAllItems();
},get_focusedItem:function(){
return this._focusedItem;
},get_openedItem:function(){
return this._openedItem;
},get_clickToOpen:function(){
return this._clickToOpen;
},set_clickToOpen:function(_74){
this._clickToOpen=_74;
},get_collapseDelay:function(){
return this._collapseDelay;
},set_collapseDelay:function(_75){
this._collapseDelay=_75;
},get_expandDelay:function(){
return this._expandDelay;
},set_expandDelay:function(_76){
this._expandDelay=_76;
},get_loadingTemplate:function(){
return this._loadingTemplate;
},set_loadingTemplate:function(_77){
this._loadingTemplate=_77;
},get_webServiceSettings:function(){
return this._webServiceSettings;
},set_webServiceSettings:function(_78){
var _79=Sys.Serialization.JavaScriptSerializer.deserialize(_78);
this._webServiceSettings=new Telerik.Web.UI.WebServiceSettings(_79);
},get_rightToLeft:function(){
if(this._rightToLeft===null){
this._rightToLeft=Telerik.Web.UI.RadMenu._requiresRightToLeft(this.get_element());
}
return this._rightToLeft;
},set_rightToLeft:function(_7a){
this._rightToLeft=_7a;
},set_clicked:function(_7b){
this._clicked=_7b;
},get_clicked:function(){
return this._clicked;
},saveClientState:function(){
var _7c=this._log._logEntries;
var _7d={logEntries:_7c};
return Sys.Serialization.JavaScriptSerializer.serialize(_7d);
},close:function(){
var _7e=this.get_openedItem();
if(_7e){
_7e.close();
}
},disable:function(){
this.set_enabled(false);
},enable:function(){
this.set_enabled(true);
},disableEvents:function(){
this._fireEvents=false;
},enableEvents:function(){
this._fireEvents=true;
},focus:function(){
this.get_element().focus();
},findItemByText:function(_7f){
return this._findItemByText(_7f);
},findItemByUrl:function(_80){
return this._findItemByUrl(_80);
},findItemByAbsoluteUrl:function(_81){
return this._findItemByAbsoluteUrl(_81);
},findItemByValue:function(_82){
return this._findItemByValue(_82);
},findItemByAttribute:function(_83,_84){
return this._findItemByAttribute(_83,_84);
},get_allItems:function(){
return this._getAllItems();
},get_persistLoadOnDemandItems:function(){
return this._persistLoadOnDemandItems;
},set_persistLoadOnDemandItems:function(_85){
this._persistLoadOnDemandItems=_85;
},get_enableOverlay:function(){
return this._enableOverlay;
},set_enableOverlay:function(_86){
this._enableOverlay=_86;
},_isMainElementDescendant:function(_87){
return $telerik.isDescendant(this.get_element(),_87);
},_createChildControls:function(){
this._children=new Telerik.Web.UI.RadMenuItemCollection(this);
Telerik.Web.UI.RadMenu._createChildControls(this,this._children);
},_onMouseOut:function(e){
var _89=e.rawEvent.relatedTarget?e.rawEvent.relatedTarget:e.rawEvent.toElement;
var _8a=this.get_element();
if(!_89&&!this._isMainElementDescendant(e.target)){
var _8b=this;
setTimeout(function(){
_8b.close();
},this.get_collapseDelay());
}
},_onClick:function(e){
if(!this._isMainElementDescendant(e.target)){
var _8d=this.get_clickToOpen();
if(this._focusedItem||_8d){
this.close();
if(this.get_clickToOpen()){
this.set_clicked(false);
}
}
}
},_onResize:function(e){
},_onItemMouseOver:function(e){
var _90=this._extractItemFromDomElement(e.eventMapTarget);
if(!_90.get_enabled()){
return true;
}
_90._preventClose();
if(this.get_clickToOpen()&&!this.get_clicked()){
return true;
}
if(_90._state==Telerik.Web.UI.RadMenuItemState.Open||_90._state==Telerik.Web.UI.RadMenuItemState.AboutToOpen){
return true;
}
var _91=_90.get_parent();
var _92=_91.get_openedItem();
if(_92&&_92!=_90){
_92._clearTimeout();
_92._state=Telerik.Web.UI.RadMenuItemState.AboutToClose;
_92._setTimeout(function(){
_92.close();
_92._timeoutRef=null;
},this.get_expandDelay());
}
if(_90.get_items().get_count()==0&&!_90._isWebServiceCallNeeded()){
return true;
}
this._lastOpenedItem=_90;
_90._state=Telerik.Web.UI.RadMenuItemState.AboutToOpen;
_90._setTimeout(function(){
_90.open();
_90._timeoutRef=null;
},this.get_expandDelay());
return true;
},_onItemMouseOut:function(e){
var _94=this._extractItemFromDomElement(e.eventMapTarget);
if(!_94.get_enabled()){
return true;
}
var _95=e.eventMapRelatedTarget;
var _96=_94.get_element();
if(!_95||_96==_95||$telerik.isDescendant(_96,_95)){
return true;
}
if(this._childrenDetached&&$telerik.isDescendant(_94.get_parent()._getAnimationContainer(),_95)){
return true;
}
if(_94._state==Telerik.Web.UI.RadMenuItemState.Closed||_94._state==Telerik.Web.UI.RadMenuItemState.AboutToClose){
return true;
}
if(_94._state==Telerik.Web.UI.RadMenuItemState.AboutToOpen){
_94._clearTimeout();
_94._state=Telerik.Web.UI.RadMenuItemState.Closed;
_94.get_parent()._openedItem=null;
return true;
}
if(this.get_clickToOpen()){
return true;
}
_94._state=Telerik.Web.UI.RadMenuItemState.AboutToClose;
_94._setTimeout(function(){
_94.close();
_94._timeoutRef=null;
},this._collapseDelay);
return true;
},_onItemDragStart:function(e){
e.preventDefault();
return false;
},_onLinkClick:function(e){
var _99=this._extractItemFromDomElement(e.eventMapTarget);
if(!_99._click(e)){
e.preventDefault();
return false;
}
return true;
},_onLinkMouseOver:function(e){
var _9b=e.eventMapRelatedTarget;
var _9c=this._extractItemFromDomElement(e.eventMapTarget);
if(!_9c.get_enabled()){
return true;
}
var _9d=_9c.get_linkElement();
if(!_9b||_9d==_9b||$telerik.isDescendant(_9d,_9b)){
return true;
}
_9c._hovered=true;
_9c._updateImageSrc();
this._raiseEvent("mouseOver",new Telerik.Web.UI.RadMenuMouseOverEventArgs(_9c,e));
return true;
},_onLinkMouseOut:function(e){
var _9f=e.eventMapRelatedTarget;
var _a0=this._extractItemFromDomElement(e.eventMapTarget);
if(!_a0.get_enabled()){
return true;
}
var _a1=_a0.get_linkElement();
if(!_9f||!_a1){
return;
}
if(_a1==_9f||$telerik.isDescendant(_a1,_9f)){
return true;
}
_a0._hovered=false;
_a0._updateImageSrc();
this._raiseEvent("mouseOut",new Telerik.Web.UI.RadMenuMouseOutEventArgs(_a0,e));
return true;
},_onLinkMouseDown:function(e){
var _a3=this._extractItemFromDomElement(e.eventMapTarget);
if(!_a3.get_enabled()){
return true;
}
_a3._clicked=true;
_a3._updateLinkClass();
_a3._updateImageSrc();
return true;
},_onLinkMouseUp:function(e){
var _a5=this._extractItemFromDomElement(e.eventMapTarget);
if(!_a5.get_enabled()){
return true;
}
_a5._clicked=false;
_a5._updateLinkClass();
_a5._updateImageSrc();
return true;
},_onLinkBlur:function(e){
var _a7=this._extractItemFromDomElement(e.eventMapTarget);
if(!_a7.get_enabled()){
return true;
}
_a7._focused=false;
_a7.blur();
return true;
},_onLinkFocus:function(e){
var _a9=this._extractItemFromDomElement(e.eventMapTarget);
if(!_a9.get_enabled()){
return true;
}
_a9._focused=true;
_a9.focus();
return true;
},_onLinkKeyDown:function(e){
var _ab=this._extractItemFromDomElement(e.eventMapTarget);
if(!_ab.get_enabled()){
return true;
}
return _ab._onKeyDown(e);
},_onTopArrowMouseDown:function(e){
var _ad=this._extractItemFromDomElement(e.eventMapTarget);
_ad._onScrollArrowMouseDown(Telerik.Web.UI.ArrowPosition.Top);
},_onTopArrowMouseUp:function(e){
var _af=this._extractItemFromDomElement(e.eventMapTarget);
_af._onScrollArrowMouseUp(Telerik.Web.UI.ArrowPosition.Top);
},_onTopArrowMouseOver:function(e){
var _b1=this._extractItemFromDomElement(e.eventMapTarget);
_b1._onScrollArrowMouseOver(Telerik.Web.UI.ArrowPosition.Top);
},_onTopArrowMouseOut:function(e){
var _b3=this._extractItemFromDomElement(e.eventMapTarget);
_b3._onScrollArrowMouseOut(Telerik.Web.UI.ArrowPosition.Top);
},_onBottomArrowMouseDown:function(e){
var _b5=this._extractItemFromDomElement(e.eventMapTarget);
_b5._onScrollArrowMouseDown(Telerik.Web.UI.ArrowPosition.Bottom);
},_onBottomArrowMouseUp:function(e){
var _b7=this._extractItemFromDomElement(e.eventMapTarget);
_b7._onScrollArrowMouseUp(Telerik.Web.UI.ArrowPosition.Bottom);
},_onBottomArrowMouseOver:function(e){
var _b9=this._extractItemFromDomElement(e.eventMapTarget);
_b9._onScrollArrowMouseOver(Telerik.Web.UI.ArrowPosition.Bottom);
},_onBottomArrowMouseOut:function(e){
var _bb=this._extractItemFromDomElement(e.eventMapTarget);
_bb._onScrollArrowMouseOut(Telerik.Web.UI.ArrowPosition.Bottom);
},_onLeftArrowMouseDown:function(e){
var _bd=this._extractItemFromDomElement(e.eventMapTarget);
_bd._onScrollArrowMouseDown(Telerik.Web.UI.ArrowPosition.Left);
},_onLeftArrowMouseUp:function(e){
var _bf=this._extractItemFromDomElement(e.eventMapTarget);
_bf._onScrollArrowMouseUp(Telerik.Web.UI.ArrowPosition.Left);
},_onLeftArrowMouseOver:function(e){
var _c1=this._extractItemFromDomElement(e.eventMapTarget);
_c1._onScrollArrowMouseOver(Telerik.Web.UI.ArrowPosition.Left);
},_onLeftArrowMouseOut:function(e){
var _c3=this._extractItemFromDomElement(e.eventMapTarget);
_c3._onScrollArrowMouseOut(Telerik.Web.UI.ArrowPosition.Left);
},_onRightArrowMouseDown:function(e){
var _c5=this._extractItemFromDomElement(e.eventMapTarget);
_c5._onScrollArrowMouseDown(Telerik.Web.UI.ArrowPosition.Right);
},_onRightArrowMouseUp:function(e){
var _c7=this._extractItemFromDomElement(e.eventMapTarget);
_c7._onScrollArrowMouseUp(Telerik.Web.UI.ArrowPosition.Right);
},_onRightArrowMouseOver:function(e){
var _c9=this._extractItemFromDomElement(e.eventMapTarget);
_c9._onScrollArrowMouseOver(Telerik.Web.UI.ArrowPosition.Right);
},_onRightArrowMouseOut:function(e){
var _cb=this._extractItemFromDomElement(e.eventMapTarget);
_cb._onScrollArrowMouseOut(Telerik.Web.UI.ArrowPosition.Right);
},_onScrollArrowClicked:function(e){
e.preventDefault();
e.stopPropagation();
return false;
},_childrenCleared:function(_cd){
if(_cd._slideWrapElement){
_cd._slideWrapElement.outerHTML="";
_cd._slideWrapElement=null;
_cd._scrollWrapElement=null;
}
_cd._linkElement=null;
_cd._childListElement=null;
_cd._animatedElement=null;
_cd._animationContainer=null;
Telerik.Web.UI.RadMenu.callBaseMethod(this,"_childrenCleared",[_cd]);
},_childInserted:function(_ce,_cf,_d0){
if(_d0._setHasItems){
_d0._setHasItems(true);
}
Telerik.Web.UI.RadMenu.callBaseMethod(this,"_childInserted",[_ce,_cf,_d0]);
if(_d0._state&&_d0._state==Telerik.Web.UI.RadMenuItemState.Open){
if(_cf._getWidth()>0){
Telerik.Web.UI.RadMenu._adjustChildrenWidth(_d0);
}
}
},_childRemoved:function(_d1,_d2){
_d1.get_text();
var _d3=_d1.get_element();
if(_d2.get_items().get_count()==0){
if(_d2._slide){
_d2._slide.dispose();
_d2._slide=null;
}
_d3=$telerik.getFirstChildByTagName(_d2.get_element(),"div",0);
_d2._linkElement=null;
_d2._childListElement=null;
_d2._scrollWrapElement=null;
_d2._slideWrapElement=null;
_d2._animatedElement=null;
_d2._animationContainer=null;
}
if(_d3){
_d3.outerHTML="";
if(_d3.parentNode){
_d3.parentNode.removeChild(_d3);
}
_d3=null;
}
var _d4=_d2.get_items().get_count();
if(_d4>0){
var _d5=_d2.get_items().getItem(0).get_element();
if(_d5&&!Sys.UI.DomElement.containsCssClass(_d5,"rmFirst")){
_d5.className+=" rmFirst";
}
}
var _d6=_d4-1;
if(_d4>0){
var _d7=_d2.get_items().getItem(_d6).get_element();
if(_d7&&!Sys.UI.DomElement.containsCssClass(_d7,"rmLast")){
_d7.className+=" rmLast";
}
}
Telerik.Web.UI.RadMenu.callBaseMethod(this,"_childRemoved",[_d1,_d2]);
if(_d2._state&&_d2._state==Telerik.Web.UI.RadMenuItemState.Open){
Telerik.Web.UI.RadMenu._adjustChildrenWidth(_d2,true);
}
},_getExtendedItemClickingEventArgs:function(_d8){
return _d8;
},_getExtendedItemClickedEventArgs:function(_d9){
return _d9;
},_incrementZIndex:function(_da){
if(this._zIndexIncrementDepth==0){
var _db=this.get_element();
_db.style.zIndex=this._originalZIndex+_da;
}
this._zIndexIncrementDepth++;
},_restoreZIndex:function(){
if(this._zIndexIncrementDepth>0){
this._zIndexIncrementDepth--;
}
if(this._zIndexIncrementDepth==0){
var _dc=this.get_element();
_dc.style.zIndex=this._originalZIndex;
}
},_getRtlClassName:function(){
return "rmRtl";
},_getMainElement:function(){
return this.get_element();
},_initRightToLeft:function(){
var _dd=this._getMainElement();
_dd.dir="ltr";
if(_dd.className.indexOf("rmRtl")<0){
_dd.className=String.format("{0} {1}",_dd.className,this._getRtlClassName());
if(this._skin){
_dd.className=String.format("{0} RadMenu_{1}_rtl",_dd.className,this._skin);
}
}
for(var i=0;i<this.get_items().get_count();i++){
var _df=this.get_items().getItem(i);
var _e0=_df.get_imageElement();
if(_e0){
_e0.style.styleFloat="left";
_e0.style.cssFloat="left";
_df.get_linkElement().style.width=_df._getWidth()+"px";
_e0.style.styleFloat="right";
_e0.style.cssFloat="right";
}
}
},_postback:function(_e1){
if(!this._postBackReference){
return;
}
var _e2=this._postBackReference.replace("arguments",_e1);
eval(_e2);
},_raiseEvent:function(_e3,_e4){
if(this._fireEvents){
this.raiseEvent(_e3,_e4);
}
},_initializeWebServiceLoader:function(){
this._webServiceLoader=new Telerik.Web.UI.WebServiceLoader(this.get_webServiceSettings());
this._webServiceLoader.add_loadingStarted(Function.createDelegate(this,this._onItemLoadingStarted));
this._webServiceLoader.add_loadingSuccess(Function.createDelegate(this,this._onItemLoadingSuccess));
this._webServiceLoader.add_loadingError(Function.createDelegate(this,this._onItemLoadingError));
},_loadChildrenFromWebService:function(_e5){
if(!this._webServiceLoader){
this._initializeWebServiceLoader();
}
var _e6={};
var _e7=new Telerik.Web.UI.RadMenuItemPopulatingEventArgs(_e5,_e6);
this._raiseEvent("itemPopulating",_e7);
if(_e7.get_cancel()){
return;
}
var _e8={Text:_e5.get_text(),Value:_e5.get_value(),ExpandMode:_e5.get_expandMode()};
var _e9={item:_e8,context:_e6};
this._webServiceLoader.loadData(_e9,_e5);
},_onItemLoadingStarted:function(_ea,_eb){
var _ec=_eb.get_context();
_ec._onChildrenLoading();
},_onItemLoadingSuccess:function(_ed,_ee){
var _ef=_ee.get_data();
var _f0=_ee.get_context();
var _f1=_f0.get_items();
for(i=0;i<_ef.length;i++){
var _f3=_ef[i];
var _f4=new Telerik.Web.UI.RadMenuItem();
_f4._loadFromDictionary(_f3);
if(_f4.get_navigateUrl()===""){
_f4.set_navigateUrl("#");
}
_f1.add(_f4);
}
_f0._onChildrenLoaded();
if(this.get_persistLoadOnDemandItems()){
this.trackChanges();
_f0.set_expandMode(Telerik.Web.UI.MenuItemExpandMode.ClientSide);
var _f5=_f1.get_count();
for(var i=0;i<_f5;i++){
this._log.logInsert(_f1.getItem(i));
}
this.commitChanges();
}
var _f6=new Telerik.Web.UI.RadMenuItemPopulatedEventArgs(_f0);
this._raiseEvent("itemPopulated",_f6);
},_onItemLoadingError:function(_f7,_f8){
var _f9=_f8.get_message();
var _fa=_f8.get_context();
_fa._onChildrenLoadingError();
var _fb=new Telerik.Web.UI.RadMenuItemPopulationFailedEventArgs(_fa,_f9);
this._raiseEvent("itemPopulationFailed",_fb);
if(_fb.get_cancel()){
return;
}
alert(_f9);
},add_mouseOver:function(_fc){
this.get_events().addHandler("mouseOver",_fc);
},remove_mouseOver:function(_fd){
this.get_events().removeHandler("mouseOver",_fd);
},add_mouseOut:function(_fe){
this.get_events().addHandler("mouseOut",_fe);
},remove_mouseOut:function(_ff){
this.get_events().removeHandler("mouseOut",_ff);
},add_itemFocus:function(_100){
this.get_events().addHandler("itemFocus",_100);
},remove_itemFocus:function(_101){
this.get_events().removeHandler("itemFocus",_101);
},add_itemBlur:function(_102){
this.get_events().addHandler("itemBlur",_102);
},remove_itemBlur:function(_103){
this.get_events().removeHandler("itemBlur",_103);
},add_itemClicking:function(_104){
this.get_events().addHandler("itemClicking",_104);
},remove_itemClicking:function(_105){
this.get_events().removeHandler("itemClicking",_105);
},add_itemClicked:function(_106){
this.get_events().addHandler("itemClicked",_106);
},remove_itemClicked:function(_107){
this.get_events().removeHandler("itemClicked",_107);
},add_itemOpening:function(_108){
this.get_events().addHandler("itemOpening",_108);
},remove_itemOpening:function(_109){
this.get_events().removeHandler("itemOpening",_109);
},add_itemOpened:function(_10a){
this.get_events().addHandler("itemOpened",_10a);
},remove_itemOpened:function(_10b){
this.get_events().removeHandler("itemOpened",_10b);
},add_itemClosing:function(_10c){
this.get_events().addHandler("itemClosing",_10c);
},remove_itemClosing:function(_10d){
this.get_events().removeHandler("itemClosing",_10d);
},add_itemClosed:function(_10e){
this.get_events().addHandler("itemClosed",_10e);
},remove_itemClosed:function(_10f){
this.get_events().removeHandler("itemClosed",_10f);
},add_load:function(_110){
this.get_events().addHandler("load",_110);
},remove_load:function(_111){
this.get_events().removeHandler("load",_111);
},add_itemPopulating:function(_112){
this.get_events().addHandler("itemPopulating",_112);
},remove_itemPopulating:function(_113){
this.get_events().removeHandler("itemPopulating",_113);
},add_itemPopulated:function(_114){
this.get_events().addHandler("itemPopulated",_114);
},remove_itemPopulated:function(_115){
this.get_events().removeHandler("itemPopulated",_115);
},add_itemPopulationFailed:function(_116){
this.get_events().addHandler("itemPopulationFailed",_116);
},remove_itemPopulationFailed:function(_117){
this.get_events().removeHandler("itemPopulationFailed",_117);
}};
Telerik.Web.UI.RadMenu.registerClass("Telerik.Web.UI.RadMenu",Telerik.Web.UI.ControlItemContainer);
Type.registerNamespace("Telerik.Web.UI");
Telerik.Web.UI.RadMenuItemState=function(){
};
Telerik.Web.UI.RadMenuItemState.prototype={Closed:0,Open:1,AboutToClose:2,AboutToOpen:3};
Telerik.Web.UI.RadMenuItemState.registerEnum("Telerik.Web.UI.RadMenuItemState");
Telerik.Web.UI.MenuItemExpandMode=function(){
};
Telerik.Web.UI.MenuItemExpandMode.prototype={ClientSide:0,WebService:1};
Telerik.Web.UI.MenuItemExpandMode.registerEnum("Telerik.Web.UI.MenuItemExpandMode");
Telerik.Web.UI.RadMenuItem=function(){
Telerik.Web.UI.RadMenuItem.initializeBase(this);
this._zIndexStep=1000;
this._scrollWrapCssClass="rmScrollWrap";
this._groupCssClass="rmGroup";
this._levelCssClass="rmLevel";
this._horizontalCssClass="rmHorizontal";
this._verticalCssClass="rmVertical";
this._leftImageCssClass="rmLeftImage";
this._defaultDisabledCssClass="rmDisabled";
this._defaultExpandedCssClass="rmExpanded";
this._defaultFocusedCssClass="rmFocused";
this._defaultClickedCssClass="rmClicked";
this._defaultScrollSize=16;
this._menu=null;
this._groupSettings=new Telerik.Web.UI.RadMenuItemGroupSettings({});
this._imageUrl=null;
this._flow=null;
this._openedItem=null;
this._timeoutRef=null;
this._focused=false;
this._clicked=false;
this._hovered=false;
this._isImageOnly=null;
this._itemsLoaded=false;
this._itemsLoading=false;
this._adjustSiblingsWidthOnShow=false;
this._state=Telerik.Web.UI.RadMenuItemState.Closed;
this._linkElement=null;
this._imageElement=null;
this._childListElement=null;
this._scrollWrapElement=null;
this._slideWrapElement=null;
this._animatedElement=null;
this._animationContainer=null;
this._childrenDetached=false;
this._autoScrollActive=false;
this._collapseAnimationEndedDelegate=null;
this._slide=null;
this._scroller=null;
this._styleCssText=null;
this._hasItems=null;
};
Telerik.Web.UI.RadMenuItem.prototype={_initialize:function(json,_119){
Telerik.Web.UI.RadMenuItem.callBaseMethod(this,"_initialize",[json,_119]);
var menu=this.get_menu();
if(typeof (json.groupSettings)!="undefined"){
this._groupSettings=new Telerik.Web.UI.RadMenuItemGroupSettings(json.groupSettings,menu.get_defaultGroupSettings());
}
this._initializeAnimation();
this._updateTextElementClass();
this._renderAccessKey();
},_dispose:function(){
Telerik.Web.UI.RadMenuItem.callBaseMethod(this,"_dispose");
if(this._collapseAnimationEndedDelegate){
if(this._slide){
this._slide.remove_collapseAnimationEnded(this._collapseAnimationEndedDelegate);
}
this._collapseAnimationEndedDelegate=null;
}
if(this._slide){
this._slide.dispose();
this._slide=null;
}
if(this._scroller){
this._scroller.dispose();
this._scroller=null;
}
var _11b=this._getAnimationContainer();
if(_11b){
_11b._item=null;
_11b._itemTypeName=null;
}
this._clearTimeout();
},_initializeRenderedItem:function(){
Telerik.Web.UI.RadMenuItem.callBaseMethod(this,"_initializeRenderedItem");
this._initializeAnimation();
this._updateTextElementClass();
this._updateLinkClass();
this._renderAccessKey();
},get_linkElement:function(){
if(!this._linkElement){
this._linkElement=$telerik.getFirstChildByTagName(this.get_element(),"a",0);
}
return this._linkElement;
},get_childListElement:function(){
if(!this._childListElement){
var _11c=this._getSlideWrapElement();
if(_11c){
var _11d=_11c;
var _11e=this._getScrollWrapElement();
if(_11e){
_11d=_11e;
}
this._childListElement=$telerik.getFirstChildByTagName(_11d,"ul",0);
}
}
return this._childListElement;
},get_imageElement:function(){
if(!this._imageElement){
var _11f=this.get_linkElement();
var _120=this.get_element();
this._imageElement=$telerik.getFirstChildByTagName(_11f||_120,"img",0);
}
return this._imageElement;
},get_textElement:function(){
var link=this.get_linkElement();
if(link){
return $telerik.getChildByClassName(link,"rmText",0);
}else{
return null;
}
},get_menu:function(){
return this._getControl();
},get_items:function(){
return this._getChildren();
},set_text:function(_122){
Telerik.Web.UI.RadMenuItem.callBaseMethod(this,"set_text",[_122]);
this._adjustSiblingsWidthOnShow=true;
},get_navigateUrl:function(){
return this._getNavigateUrl();
},set_navigateUrl:function(_123){
this._properties.setValue("navigateUrl",_123,true);
if(this.get_linkElement()){
this.get_linkElement().href=_123;
}
},get_target:function(){
return this._properties.getValue("target",null);
},set_target:function(_124){
this._properties.setValue("target",_124);
if(this.get_linkElement()){
this.get_linkElement().target=_124;
}
},get_groupSettings:function(){
return this._groupSettings;
},set_groupSettings:function(_125){
this._groupSettings=_125;
},_getNextItem:function(){
var _126=this.get_parent().get_items();
var _127=this.get_index();
if(_127==_126.get_count()-1){
return _126.getItem(0);
}
return _126.getItem(_127+1);
},_getPreviousItem:function(){
var _128=this.get_parent().get_items();
var _129=this.get_index();
if(_129==0){
return _128.getItem(_128.get_count()-1);
}
return _128.getItem(_129-1);
},_focus:function(e){
this._setFocused(true,e);
},_blur:function(e){
this._setFocused(false,e);
},_setFocused:function(_12c,e){
if(_12c){
this._doFocus(e);
}else{
this._doBlur(e);
}
this._focused=_12c;
this._updateLinkClass();
},_open:function(e){
var menu=this.get_menu();
var _130=new Telerik.Web.UI.RadMenuItemOpeningEventArgs(this,e);
menu._raiseEvent("itemOpening",_130);
if(_130.get_cancel()){
return;
}
if(this._isWebServiceCallNeeded()){
this._loadChildrenFromWebService();
return;
}
this._doOpen(e);
},_close:function(e){
if(this.get_isSeparator()||this._state==Telerik.Web.UI.RadMenuItemState.Closed){
return;
}
var _132=new Telerik.Web.UI.RadMenuItemClosingEventArgs(this,e);
this.get_menu()._raiseEvent("itemClosing",_132);
if(_132.get_cancel()){
return;
}
if(this._openedItem){
this._openedItem._close(e);
}
var _133=this.get_parent();
_133._openedItem=null;
if(!this._getAnimationContainer()){
return;
}
this._state=Telerik.Web.UI.RadMenuItemState.Closed;
var menu=this.get_menu();
if(this.get_level()==0){
menu._aboutToCollapse=true;
}
if(!this._getIsImageOnly()){
this.get_element().style.zIndex=0;
}
this._slide.collapse();
this._updateLinkClass();
this._updateImageSrc();
var _135=new Telerik.Web.UI.RadMenuItemClosedEventArgs(this,e);
this.get_menu()._raiseEvent("itemClosed",_135);
this._closeChildren(e);
},get_nextItem:function(){
return this.get_nextSibling();
},get_previousItem:function(){
return this.get_previousSibling();
},get_focusedItem:function(){
return this._focusedItem;
},get_isSeparator:function(){
return this._properties.getValue("isSeparator",false);
},set_isSeparator:function(_136){
this._properties.setValue("isSeparator",_136,true);
},get_openedItem:function(){
return this._openedItem;
},get_templated:function(){
return this._properties.getValue("templated",false)==true;
},get_cssClass:function(){
return this._properties.getValue("cssClass","");
},set_cssClass:function(_137){
this._properties.setValue("cssClass",_137,true);
},get_focused:function(){
return this._focused;
},set_focused:function(_138){
this._setFocused(_138);
},get_hoveredImageUrl:function(){
return this._properties.getValue("hoveredImageUrl",null);
},set_hoveredImageUrl:function(_139){
this._properties.setValue("hoveredImageUrl",_139,true);
this._updateImageSrc();
},get_clickedImageUrl:function(){
return this._properties.getValue("clickedImageUrl",null);
},set_clickedImageUrl:function(_13a){
this._properties.setValue("clickedImageUrl",_13a,true);
this._updateImageSrc();
},get_imageUrl:function(){
if(!this._imageUrl){
var _13b=this.get_imageElement();
if(_13b){
this._imageUrl=_13b.src;
}
}
return this._imageUrl;
},set_imageUrl:function(_13c){
this._imageUrl=_13c;
this._properties.setValue("imageUrl",_13c,true);
this._updateImageSrc();
},set_visible:function(_13d){
var _13e=this.get_visible()!=_13d;
if(!_13e){
return;
}
Telerik.Web.UI.RadMenuItem.callBaseMethod(this,"set_visible",[_13d]);
this._adjustSiblingsWidthOnShow=true;
this._clearWidth();
var _13f=_13d?"":"none";
var _140=this.get_linkElement();
var _141=this.get_textElement();
var _142;
if(_140){
_142=_140;
}else{
if(_141){
_142=_141;
}
}
if(this.get_isSeparator()||this.get_templated()){
_142=this.get_element().childNodes[0];
}
_142.style.display=_13f;
if(this.get_visible()){
this.get_element().style.cssText=this._styleCssText;
}else{
this._styleCssText=this.get_element().style.cssText;
this.get_element().style.cssText="padding:0px;margin:0px;height:0px;overflow:hidden;";
}
var _143=this._getParentFlow();
if(_143==Telerik.Web.UI.ItemFlow.Vertical){
if(!_13d){
this._clearSiblingsWidth();
}
var _144=this.get_parent();
if(_144.get_element().offsetWidth>0){
Telerik.Web.UI.RadMenu._adjustChildrenWidth(_144);
}
}
},get_expandedImageUrl:function(){
return this._properties.getValue("expandedImageUrl",null);
},set_expandedImageUrl:function(_145){
this._properties.setValue("expandedImageUrl",_145,true);
this._updateImageSrc();
},get_disabledImageUrl:function(){
return this._properties.getValue("disabledImageUrl",null);
},set_disabledImageUrl:function(_146){
this._properties.setValue("disabledImageUrl",_146,true);
this._updateImageSrc();
},get_disabledCssClass:function(){
return this._properties.getValue("disabledCssClass",this._defaultDisabledCssClass);
},set_disabledCssClass:function(_147){
this._properties.setValue("disabledCssClass",_147,true);
this._updateLinkClass();
},get_expandedCssClass:function(){
return this._properties.getValue("expandedCssClass",this._defaultExpandedCssClass);
},set_expandedCssClass:function(_148){
this._properties.setValue("expandedCssClass",_148,true);
this._updateLinkClass();
},get_focusedCssClass:function(){
return this._properties.getValue("focusedCssClass",this._defaultFocusedCssClass);
},set_focusedCssClass:function(_149){
this._properties.setValue("focusedCssClass",_149,true);
this._updateLinkClass();
},get_clickedCssClass:function(){
return this._properties.getValue("clickedCssClass",this._defaultClickedCssClass);
},set_clickedCssClass:function(_14a){
this._properties.setValue("clickedCssClass",_14a,true);
this._updateLinkClass();
},get_postBack:function(){
return this._properties.getValue("postBack",true)==true;
},set_postBack:function(_14b){
this._properties.setValue("postBack",_14b);
},get_expandMode:function(){
return this._properties.getValue("expandMode",Telerik.Web.UI.MenuItemExpandMode.ClientSide);
},set_expandMode:function(_14c){
this._properties.setValue("expandMode",_14c,true);
},set_enabled:function(_14d){
Telerik.Web.UI.RadMenuItem.callBaseMethod(this,"set_enabled",[_14d]);
this._updateLinkClass();
},open:function(){
this._open(null);
},close:function(){
this._close(null);
},hide:function(){
this.set_visible(false);
},show:function(){
this.set_visible(true);
},focus:function(){
this._setFocused(true,null);
},blur:function(){
this._blur(null);
},focusFirstChild:function(e){
var _14f=this.get_items();
if(_14f.get_count()==0){
return;
}
var item=_14f.getItem(0);
var _151=item;
while(!item._canFocus()){
item=item._getNextItem();
if(item==_151){
return;
}
}
item._focus(e||null);
},focusLastChild:function(e){
var _153=this.get_items();
if(_153.get_count()==0){
return;
}
var item=_153.getItem(_153.get_count()-1);
var _155=item;
while(!item._canFocus()){
item=item._getPreviousItem();
if(item==_155){
return;
}
}
item._focus(e||null);
},focusNextItem:function(e){
var item=this._getNextItem();
while(!item._canFocus()){
item=item._getNextItem();
}
item._focus(e||null);
},focusPreviousItem:function(e){
var item=this._getPreviousItem();
while(!item._canFocus()){
item=item._getPreviousItem();
}
item._focus(e||null);
},disable:function(){
this.set_enabled(false);
},enable:function(){
this.set_enabled(true);
},click:function(){
this._click(null);
},_modifyPositionClass:function(){
var _15a=this._getVisibleIndex();
if(_15a==0){
var _15b=this._getNextVisibleSibling(this.get_index());
var _15c=this.get_visible()?"rmItem":"rmItem rmFirst";
var _15d=this.get_visible()?"rmItem rmFirst":"rmItem";
this._replaceCssClass(this.get_element(),_15c,_15d);
this._replaceCssClass(_15b.get_element(),_15d,_15c);
}
if(_15a==this._getVisibleSiblingsCount()){
var _15e=this._getPreviousVisibleSibling(this.get_index());
var _15c=this.get_visible()?"rmItem":"rmItem rmLast";
var _15d=this.get_visible()?"rmItem rmLast":"rmItem";
this._replaceCssClass(this.get_element(),_15c,_15d);
this._replaceCssClass(_15e.get_element(),_15d,_15c);
}
},_getSiblings:function(){
return this.get_parent().get_items();
},_getVisibleIndex:function(){
var _15f=this._getSiblings();
if(this.get_index()==0){
return 0;
}
var _160=0;
for(var i=0;i<=this.get_index();i++){
if(_15f.getItem(i).get_visible()){
_160++;
}
}
return _160;
},_getVisibleSiblingsCount:function(){
var _162=this._getSiblings();
var _163=0;
for(var i=0;i<_162.get_count();i++){
if(_162.getItem(i).get_visible()){
_163++;
}
}
return _163;
},_getPreviousVisibleSibling:function(_165){
var _166=this.get_parent().get_items();
for(var i=_165-1;i>=0;i--){
var item=_166.getItem(i);
if(item.get_visible()){
return item;
}
}
return null;
},_getNextVisibleSibling:function(_169){
var _16a=this.get_parent().get_items();
for(var i=_169+1;i<_16a.get_count();i++){
var item=_16a.getItem(i);
if(item.get_visible()){
return item;
}
}
return null;
},_determineCssClass:function(){
var _16d="rmItem";
var _16e=this.get_parent();
var _16f=_16e.get_items().get_count();
var _170=_16f-1;
if(this.get_index()==0&&_16f>0){
var _171=_16e.get_items().getItem(1);
if(_171&&_171.get_element()){
if(_171.get_index()==_170){
this._replaceCssClass(_171.get_element(),"rmItem rmFirst","rmItem rmLast");
}else{
this._replaceCssClass(_171.get_element(),"rmItem rmFirst","rmItem");
}
}
_16d+=" "+"rmFirst";
}
if(this.get_index()==_170&&_16f>0){
var _172=_16e.get_items().getItem(_170-1);
if(_172&&_172.get_element()){
if(_172.get_index()==0){
this._replaceCssClass(_172.get_element(),"rmItem rmLast","rmItem rmFirst");
}else{
this._replaceCssClass(_172.get_element(),"rmItem rmLast","rmItem");
}
}
_16d+=" "+"rmLast";
}
if(this.get_isSeparator()){
_16d="rmItem"+" "+"rmSeparator";
}
return _16d;
},_renderImage:function(html){
html[html.length]="<img alt='' src='"+this.get_imageUrl()+"' class='rmLeftImage'";
if(!this.get_enabled()){
html[html.length]=" disabled='disabled'";
}
html[html.length]="/>";
return html;
},_renderLink:function(html){
if(this.get_isSeparator()){
return;
}
var href="#";
var _176=this.get_navigateUrl();
if(_176&&_176!="#"){
href=_176;
}
html[html.length]="<a href=\"";
html[html.length]=href;
html[html.length]="\" ";
var _177=this.get_target();
if(_177){
html[html.length]="target=\"";
html[html.length]=_177;
html[html.length]="\" ";
}
if(this.get_enabled()){
html[html.length]="class=\"rmLink\"";
}else{
html[html.length]="class=\"rmLink rmDisabled\"";
}
html[html.length]=">";
return html;
},_renderChildList:function(html){
var _179=this.get_items().get_count();
if(_179>0){
html[html.length]="<div class='rmSlide'>";
var _17a=this.get_groupSettings();
var _17b=_17a.get_flow();
if(_17b==0){
_17b="rmVertical";
}else{
_17b="rmHorizontal";
}
var _17c;
if(this._getRenderScroll()){
var _17d="rmLevel"+(this.get_level()+1);
var _17e="rmScrollWrap"+" "+"rmGroup"+" "+_17d;
html[html.length]="<div class='"+_17e+"' style='";
var _17f=_17a.get_width();
var _180=_17a.get_height();
if(_17f){
html[html.length]="width :"+_17f+";";
}
if(_180){
html[html.length]="height :"+_180+";";
}
html[html.length]=" '>";
_17c=_17b;
}else{
var _17d="rmLevel"+(this.get_level()+1);
_17c=_17b+" "+"rmGroup"+" "+_17d;
}
html[html.length]="<ul class='"+_17c+"'>";
for(var i=0;i<_179;i++){
this.get_items().getItem(i)._render(html);
}
html[html.length]="</ul></div>";
if(this._getRenderScroll()){
html[html.length]="</div>";
}
}
},_doOpen:function(e){
var menu=this.get_menu();
if(this.get_items().get_count()==0){
return;
}
this._ensureChildControls();
var _184=this.get_parent();
menu._aboutToCollapse=false;
if(_184!=menu&&_184._state!=Telerik.Web.UI.RadMenuItemState.Open){
_184._open(e);
}
var _185=this._getAnimationContainer();
if(!_185){
return;
}
_184._openedItem=this;
this._state=Telerik.Web.UI.RadMenuItemState.Open;
var _186=this.get_childListElement();
_186.style.display="block";
_185.style.visibility="hidden";
this._slide.show();
if(this._groupSettings.get_flow()==Telerik.Web.UI.ItemFlow.Vertical){
Telerik.Web.UI.RadMenu._adjustChildrenWidth(this);
}else{
Telerik.Web.UI.RadMenu._adjustListWidth(this);
}
if(this._adjustSiblingsWidthOnShow){
this._adjustSiblingsWidth();
this._adjustSiblingsWidthOnShow=false;
}
this._resetAnimatedElementPosition();
this._slide.set_direction(this._getSlideDirection());
this._updateScrollWrapSize();
this._slide.updateSize();
this._positionChildContainer();
_185=this._getAnimationContainer();
_185.style.visibility="visible";
this.get_element().style.zIndex=_184.get_items().get_count()-this.get_index();
_185.style.zIndex=_184.get_items().get_count()+1;
menu._incrementZIndex(this._zIndexStep);
if(this._scroller){
this._scroller.updateState();
}
this._slide.expand();
this._updateLinkClass();
this._updateImageSrc();
var _187=new Telerik.Web.UI.RadMenuItemOpenedEventArgs(this,e);
this.get_menu()._raiseEvent("itemOpened",_187);
},_shouldInitializeChild:function(_188){
return true;
},_createChildListElement:function(){
var _189=document.createElement("ul");
var _18a=this.get_groupSettings();
var _18b=_18a.get_flow();
if(_18b==0){
_18b="rmVertical";
}else{
_18b="rmHorizontal";
}
var _18c=_18b;
var _18d=this._createSlideWrapElement();
var _18e=_18d.firstChild!=null;
if(_18e){
_18d.firstChild.appendChild(_189);
}else{
var _18f="rmLevel"+(this.get_level()+1);
_18c+=" "+"rmGroup"+" "+_18f;
_18d.appendChild(_189);
}
_189.className=_18c;
this.get_element().appendChild(_18d);
this._initializeAnimation();
this._updateTextElementClass();
if(_18e){
this._initializeScroller();
}
return _18d;
},_createSlideWrapElement:function(){
var _190=document.createElement("div");
_190.className="rmSlide";
if(this._getRenderScroll()){
var _191=this._createScrollWrapElement();
_190.appendChild(_191);
}
return _190;
},_createScrollWrapElement:function(){
var _192=document.createElement("div");
var _193="rmLevel"+(this.get_level()+1);
var _194="rmScrollWrap"+" "+"rmGroup"+" "+_193;
_192.className=_194;
var _195=this.get_groupSettings();
var _196=_195.get_width();
var _197=_195.get_height();
if(_196){
_192.style.width=_196;
}
if(_197){
_192.style.height=_197;
}
return _192;
},_getRenderScroll:function(){
var _198;
var _199=this.get_groupSettings();
var _19a=_199.get_width();
if(!_19a){
_19a=this.get_menu().get_defaultGroupSettings().get_width();
}
var _19b=_199.get_height();
if(!_19b){
_19b=this.get_menu().get_defaultGroupSettings().get_height();
}
var _19c=_19a||_19b;
return _19c;
},_getChildElements:function(){
return $telerik.getChildrenByTagName(this.get_childListElement(),"li");
},_createItemCollection:function(){
var _19d=new Telerik.Web.UI.RadMenuItemCollection(this);
Telerik.Web.UI.RadMenu._createChildControls(this,_19d);
return _19d;
},_getSlideWrapElement:function(){
if(!this._slideWrapElement){
var _19e=$telerik.getFirstChildByTagName(this.get_element(),"div",1);
if(_19e&&Sys.UI.DomElement.containsCssClass(_19e,"rmSlide")){
this._slideWrapElement=_19e;
}
}
return this._slideWrapElement;
},_getScrollWrapElement:function(){
if(!this._scrollWrapElement){
var _19f=this._getSlideWrapElement();
if(_19f){
this._scrollWrapElement=$telerik.getFirstChildByTagName(_19f,"div",0);
}
}
return this._scrollWrapElement;
},_getAnimationContainer:function(){
if(!this._animationContainer){
var _1a0=this.get_templated()?1:0;
this._animationContainer=$telerik.getFirstChildByTagName(this.get_element(),"div",_1a0);
}
return this._animationContainer;
},_getAnimatedElement:function(){
if(!this._animatedElement){
this._animatedElement=this._getScrollWrapElement()||this.get_childListElement();
}
return this._animatedElement;
},_determineExpandDirection:function(){
var _1a1=this.get_groupSettings();
if(_1a1.get_expandDirection()!=Telerik.Web.UI.ExpandDirection.Auto){
return;
}
var _1a2=this._getParentFlow();
if(_1a2==Telerik.Web.UI.ItemFlow.Vertical){
if(this.get_menu().get_rightToLeft()){
_1a1.set_expandDirection(Telerik.Web.UI.ExpandDirection.Left);
}else{
_1a1.set_expandDirection(Telerik.Web.UI.ExpandDirection.Right);
}
}else{
_1a1.set_expandDirection(Telerik.Web.UI.ExpandDirection.Down);
}
},_getSlideDirection:function(){
var _1a3=this.get_groupSettings().get_expandDirection();
if(_1a3==Telerik.Web.UI.ExpandDirection.Auto){
return null;
}
return _1a3;
},_getParentFlow:function(){
var _1a4=this.get_parent();
if(!_1a4){
return null;
}
if(_1a4==this.get_menu()){
return _1a4._flow;
}else{
return _1a4.get_groupSettings().get_flow();
}
},_initializeAnimation:function(){
this._determineExpandDirection();
var _1a5=this._getAnimatedElement();
if(_1a5){
var menu=this.get_menu();
this._slide=new Telerik.Web.UI.Slide(_1a5,menu.get_expandAnimation(),menu.get_collapseAnimation(),menu.get_enableOverlay());
this._slide.initialize();
this._slide.set_direction(this._getSlideDirection());
this._collapseAnimationEndedDelegate=Function.createDelegate(this,this._onCollapseAnimationEnded);
this._slide.add_collapseAnimationEnded(this._collapseAnimationEndedDelegate);
}
},_getHasItems:function(){
if(this._hasItems===null){
this._hasItems=this.get_itemData()&&this.get_itemData().length>0;
}
return this._hasItems;
},_setHasItems:function(_1a7){
this._hasItems=_1a7;
},_updateTextElementClass:function(){
var _1a8=this.get_textElement();
if(!_1a8){
return;
}
var _1a9="rmText ";
if(this._getHasItems()||this.get_expandMode()==Telerik.Web.UI.MenuItemExpandMode.WebService){
_1a9+=" "+this._getExpandClassName();
}
_1a8.className=_1a9;
},_onCollapseAnimationEnded:function(_1aa,e){
var menu=this.get_menu();
this.get_element().style.zIndex=0;
menu._restoreZIndex();
if(this.get_level()==0&&menu.get_rightToLeft()){
var _1ad=menu.get_element();
_1ad.style.cssText=_1ad.style.cssText;
}
},_initializeScroller:function(){
var _1ae=this._getScrollWrapElement();
if(_1ae){
this._scroller=new Telerik.Web.UI.MenuItemScroller(this.get_childListElement(),this.get_groupSettings().get_flow());
this._scroller.initialize();
}
},_isAutoScrollPossible:function(){
var menu=this.get_menu();
var _1b0=this._getMaximumExpandSize();
var _1b1=this._getAnimationContainer();
if(this.get_groupSettings().get_flow()==Telerik.Web.UI.ItemFlow.Vertical){
return (menu._autoScrollMinimumHeight<_1b0&&_1b0<=_1b1.offsetHeight);
}else{
return (menu._autoScrollMinimumWidth<_1b0&&_1b0<=_1b1.offsetWidth);
}
},_getMaximumExpandSize:function(){
var _1b2=this._slide.get_direction();
var _1b3=$telerik.getViewPortSize();
var _1b4=this._getAnimationContainer();
var _1b5=$telerik.getLocation(_1b4);
if(this.get_groupSettings().get_flow()==Telerik.Web.UI.ItemFlow.Vertical){
if(_1b2==Telerik.Web.UI.ExpandDirection.Up){
availableHeight=_1b4.offsetHeight+_1b5.y;
}else{
availableHeight=_1b3.height-_1b5.y-this._defaultScrollSize;
}
return availableHeight;
}else{
if(_1b2==Telerik.Web.UI.ExpandDirection.Left){
availableWidth=_1b5.x;
}else{
availableWidth=_1b3.width-_1b5.x;
}
return availableWidth;
}
return null;
},_initializeAutoScroll:function(){
this._buildScrollWrap();
this._initializeScroller();
this._animatedElement=null;
this._scrollWrapElement=null;
this._slide.set_animatedElement(this._getAnimatedElement());
},_removeAutoScroll:function(){
var _1b6=this.get_items();
var _1b7=_1b6.get_count();
for(var i=0;i<_1b7;i++){
_1b6.getItem(i)._removeAutoScroll();
}
this._attachChildren();
if(!this._scroller){
return;
}
this._scroller.dispose();
this._scroller=null;
var _1b9=this._getSlideWrapElement();
var _1ba=this.get_childListElement();
var _1bb=this._getScrollWrapElement();
_1b9.appendChild(_1ba);
_1b9.removeChild(_1bb);
_1ba.className=String.format("{0} {1} {2}{3}",this._getFlowCssClass(),this._groupCssClass,this._levelCssClass,this.get_level());
this._animatedElement=null;
this._scrollWrapElement=null;
this._slide.set_animatedElement(this._getAnimatedElement());
this._slide.updateSize();
},_updateAutoScrollSize:function(){
var _1bc=this._slide.get_direction();
var _1bd=$telerik.getViewPortSize();
var _1be=this._getAnimationContainer();
var _1bf=$telerik.getLocation(_1be);
var _1c0=this._getScrollWrapElement();
_1c0.style.height="";
_1c0.style.width="";
var _1c1=this._getMaximumExpandSize();
if(this.get_groupSettings().get_flow()==Telerik.Web.UI.ItemFlow.Vertical){
_1c0.style.height=_1c1+"px";
_1c0.style.width=_1be.style.width;
if(_1bc==Telerik.Web.UI.ExpandDirection.Up){
_1be.style.top=-_1c1+"px";
}
}else{
_1c0.style.width=_1c1+"px";
_1c0.style.height=_1be.style.height;
}
this._slide.updateSize();
this._scroller.resetState();
},_buildScrollWrap:function(){
var _1c2=this._getSlideWrapElement();
var _1c3=this.get_childListElement();
var _1c4=document.createElement("div");
_1c4.style.position="relative";
_1c4.style.overflow="hidden";
_1c3.className=this._getFlowCssClass();
_1c4.className=String.format("{0} {1} {2}{3}",this._scrollWrapCssClass,this._groupCssClass,this._levelCssClass,this.get_level());
_1c4.appendChild(_1c3);
_1c2.appendChild(_1c4);
},_updateScrollWrapSize:function(){
var _1c5=this._getScrollWrapElement();
var _1c6=this.get_childListElement();
if(!_1c5){
return;
}
if(!_1c5.style.height){
_1c5.style.height=_1c6.offsetHeight+"px";
}
if(this.get_groupSettings().get_flow()==Telerik.Web.UI.ItemFlow.Vertical){
_1c5.style.width=_1c6.offsetWidth+"px";
}
},_getWidth:function(){
var _1c7=this.get_linkElement();
if(_1c7){
return _1c7.offsetWidth;
}else{
return this.get_element().offsetWidth;
}
},_setWidth:function(_1c8){
var _1c9=this.get_linkElement();
if(!_1c9){
_1c9=this.get_element();
}
if(!_1c9){
return;
}
if($telerik.isOpera){
this.get_element().style.cssFloat="none";
}
var _1ca=parseInt(_1c8);
if(isNaN(_1ca)){
_1c9.style.width=_1c8;
_1c9.style.cssText=_1c9.style.cssText;
return;
}
var _1cb=_1ca;
var _1cc=$telerik.getPaddingBox(_1c9).horizontal;
var _1cd=$telerik.getBorderBox(_1c9).horizontal;
_1cb-=_1cc+_1cd;
if(_1cb<=0){
return;
}
var _1ce=_1c9.style.width;
if(!_1ce||_1cb!=_1ce){
_1c9.style.width=_1cb+"px";
}
},_clearWidth:function(){
this._setWidth("auto");
},_getData:function(){
var data=Telerik.Web.UI.RadMenuItem.callBaseMethod(this,"_getData");
var _1d0=this.get_navigateUrl();
if(_1d0&&_1d0!="#"&&(location.href+"#"!==_1d0)){
data["navigateUrl"]=_1d0;
}
return data;
},_loadFromDictionary:function(data){
Telerik.Web.UI.RadMenuItem.callBaseMethod(this,"_loadFromDictionary",[data]);
if(typeof (data.ExpandMode)!="undefined"&&data.ExpandMode!=Telerik.Web.UI.MenuItemExpandMode.ClientSide){
this.set_expandMode(data.ExpandMode);
}
if(data.NavigateUrl){
this.set_navigateUrl(data.NavigateUrl);
}
if(data.PostBack===false){
this.set_postBack(data.PostBack);
}
if(data.Target){
this.set_target(data.Target);
}
if(data.IsSeparator===true){
this.set_isSeparator(data.IsSeparator);
}
if(data.CssClass){
this.set_cssClass(data.CssClass);
}
if(typeof (data.DisabledCssClass)!="undefined"&&data.DisabledCssClass!=this._defaultDisabledCssClass){
this.set_disabledCssClass(data.DisabledCssClass);
}
if(typeof (data.ExpandedCssClass)!="undefined"&&data.ExpandedCssClass!=this._defaultExpandedCssClass){
this.set_expandedCssClass(data.ExpandedCssClass);
}
if(typeof (data.FocusedCssClass)!="undefined"&&data.FocusedCssClass!=this._defaultFocusedCssClass){
this.set_focusedCssClass(data.FocusedCssClass);
}
if(typeof (data.ClickedCssClass)!="undefined"&&data.ClickedCssClass!=this._defaultClickedCssClass){
this.set_clickedCssClass(data.ClickedCssClass);
}
if(data.ImageUrl){
this.set_imageUrl(data.ImageUrl);
}
if(data.HoveredImageUrl){
this.set_hoveredImageUrl(data.HoveredImageUrl);
}
if(data.ClickedImageUrl){
this.set_clickedImageUrl(data.ClickedImageUrl);
}
if(data.DisabledImageUrl){
this.set_disabledImageUrl(data.DisabledImageUrl);
}
if(data.ExpandedImageUrl){
this.set_expandedImageUrl(data.ExpandedImageUrl);
}
},_replaceCssClass:function(_1d2,_1d3,_1d4){
_1d2.className=_1d2.className.replace(_1d3,_1d4);
},_setChildContainerPosition:function(left,top){
var _1d7=this._getAnimationContainer();
var _1d8=this.get_parent();
var _1d9=null;
if(_1d8._getScrollWrapElement){
_1d9=_1d8._getScrollWrapElement();
}
if(_1d9){
this._detachChildren();
var _1da=this.get_element();
top+=_1da.offsetTop;
var _1db=_1d8.get_childListElement();
var _1dc=parseInt(_1db.style.top);
if(isNaN(_1dc)){
_1dc=0;
}
if(this.get_groupSettings().get_offsetY()==0){
top+=_1dc;
}
}
_1d7.style.left=(left+this.get_groupSettings().get_offsetX())+"px";
_1d7.style.top=(top+this.get_groupSettings().get_offsetY())+"px";
},_detachChildren:function(){
if(this._childrenDetached){
return;
}
var _1dd=this._getAnimationContainer();
var _1de=this.get_parent();
var _1df=_1de._getAnimationContainer();
if(!this._childrenDetached){
_1df.appendChild(_1dd);
this._childrenDetached=true;
_1dd._item=this;
_1dd._itemTypeName=Object.getTypeName(this);
}
},_attachChildren:function(){
if(this._childrenDetached){
var _1e0=this.get_element();
_1e0.appendChild(this._getAnimationContainer());
this._childrenDetached=false;
}
},_resetAnimatedElementPosition:function(){
var _1e1=this._getAnimatedElement();
_1e1.style.top="0px";
_1e1.style.left="0px";
},_positionChildContainer:function(){
var _1e2=$telerik.getClientBounds();
var top=0;
var left=0;
var _1e5=this._slide._getAnimatedStyleProperty();
var _1e6=this.get_element();
var _1e7=_1e6.offsetHeight;
var _1e8=_1e6.offsetWidth;
var _1e9=this._getAnimationContainer();
var _1ea=_1e9.offsetHeight;
var _1eb=_1e9.offsetWidth;
var _1ec=this.get_groupSettings().get_expandDirection();
switch(_1ec){
case Telerik.Web.UI.ExpandDirection.Up:
top=-_1ea;
break;
case Telerik.Web.UI.ExpandDirection.Down:
top=_1e7;
break;
case Telerik.Web.UI.ExpandDirection.Left:
left=-_1eb;
break;
case Telerik.Web.UI.ExpandDirection.Right:
left=_1e8;
break;
}
var menu=this.get_menu();
if(menu.get_rightToLeft()&&this.get_level()==0){
left=_1e8-_1eb;
if(this._getParentFlow()==Telerik.Web.UI.ItemFlow.Vertical){
left-=_1e8;
}
}
this._setChildContainerPosition(left,top);
var _1ee=menu.get_enableAutoScroll();
var _1ef=menu.get_enableScreenBoundaryDetection();
var _1f0=false;
if(_1ee){
if(this._applyAutoScroll(left,top)){
_1f0=true;
}else{
if(this._autoScrollActive){
this._removeAutoScroll();
this._autoScrollActive=false;
}
if(_1ef){
var _1f1=this._adjustForScreenBoundaries(left,top);
_1f0=true;
this._applyAutoScroll(_1f1.adjustedLeft,_1f1.adjustedTop);
}
}
if(this._autoScrollActive){
this._updateAutoScrollSize();
}
}
if(_1ef&&!_1f0){
this._adjustForScreenBoundaries(left,top);
}
var _1f2=this.get_textElement();
if(_1f2){
_1f2.className="rmText "+this._getExpandClassName();
}
},_applyAutoScroll:function(_1f3,_1f4){
if(this._isAutoScrollPossible()){
if(!this._scroller){
this._initializeAutoScroll();
this._autoScrollActive=true;
this._setChildContainerPosition(_1f3,_1f4);
}
return true;
}
return false;
},_adjustForScreenBoundaries:function(left,top){
var _1f7=this._getAnimationContainer();
var _1f8=_1f7.offsetHeight;
var _1f9=_1f7.offsetWidth;
var _1fa=this.get_element();
var _1fb=_1fa.offsetHeight;
var _1fc=_1fa.offsetWidth;
var _1fd=this.get_groupSettings().get_expandDirection();
var _1fe=_1fd;
var _1ff=$telerik.getViewPortSize();
var _200=$telerik.getLocation(_1f7);
switch(_1fd){
case Telerik.Web.UI.ExpandDirection.Up:
if($telerik.elementOverflowsTop(_1f7)){
_1fe=Telerik.Web.UI.ExpandDirection.Down;
top=_1fb;
}
break;
case Telerik.Web.UI.ExpandDirection.Down:
if($telerik.elementOverflowsBottom(_1ff,_1f7)){
var _201=$telerik.getLocation(_1fa);
if(_201.y>_1f7.offsetHeight){
_1fe=Telerik.Web.UI.ExpandDirection.Up;
top=-_1f8;
}
}
break;
case Telerik.Web.UI.ExpandDirection.Left:
if($telerik.elementOverflowsLeft(_1f7)){
_1fe=Telerik.Web.UI.ExpandDirection.Right;
left=_1fc;
}
break;
case Telerik.Web.UI.ExpandDirection.Right:
if($telerik.elementOverflowsRight(_1ff,_1f7)){
_1fe=Telerik.Web.UI.ExpandDirection.Left;
left=-_1f9;
}
break;
}
switch(_1fe){
case Telerik.Web.UI.ExpandDirection.Down:
case Telerik.Web.UI.ExpandDirection.Up:
if($telerik.elementOverflowsRight(_1ff,_1f7)){
left=_1ff.width-(_200.x+_1f9);
}
break;
case Telerik.Web.UI.ExpandDirection.Left:
case Telerik.Web.UI.ExpandDirection.Right:
if($telerik.elementOverflowsBottom(_1ff,_1f7)){
top=_1ff.height-(_200.y+_1f8);
}
break;
}
this._setChildContainerPosition(left,top);
this._slide.set_direction(_1fe);
return {adjustedLeft:left,adjustedTop:top};
},_closeChildren:function(e){
var _203=this.get_items();
for(var i=0;i<_203.get_count();i++){
var _205=_203.getItem(i);
_205._stopAnimation();
_205._close(e);
}
},_stopAnimation:function(){
if(this._slide){
this._slide._stopAnimation();
}
},_preventClose:function(){
var _206=this.get_parent();
if(this._state==Telerik.Web.UI.RadMenuItemState.AboutToClose){
this._clearTimeout();
this._state=Telerik.Web.UI.RadMenuItemState.Open;
_206._openedItem=this;
}
if(_206._preventClose){
_206._preventClose();
}
},_setTimeout:function(_207,_208){
this._timeoutRef=setTimeout(_207,_208);
},_clearTimeout:function(){
if(this._timeoutRef){
clearTimeout(this._timeoutRef);
this._timeoutRef=null;
}
},_getExpandClassName:function(){
return "rmExpand"+this._getExpandClass();
},_getExpandClass:function(){
var _209=this._getSlideDirection();
switch(_209){
case Telerik.Web.UI.SlideDirection.Up:
return "Top";
case Telerik.Web.UI.SlideDirection.Down:
return "Down";
case Telerik.Web.UI.SlideDirection.Left:
return "Left";
case Telerik.Web.UI.SlideDirection.Right:
return "Right";
}
},_updateLinkClass:function(){
if(this.get_isSeparator()||this.get_templated()){
return;
}
var _20a="rmLink "+this.get_cssClass();
if(this.get_focused()){
_20a+=" "+this.get_focusedCssClass();
}
if(this._state==Telerik.Web.UI.RadMenuItemState.Open){
_20a+=" "+this.get_expandedCssClass();
}
if(this._clicked){
_20a+=" "+this.get_clickedCssClass();
}
if(!this.get_enabled()){
_20a+=" "+this.get_disabledCssClass();
}
var _20b=this.get_linkElement();
if(_20b){
_20b.className=_20a;
}
},_updateImageSrc:function(){
var _20c=this.get_imageUrl();
if(this._hovered&&this.get_hoveredImageUrl()){
_20c=this.get_hoveredImageUrl();
}
if(this._state==Telerik.Web.UI.RadMenuItemState.Open&&this.get_expandedImageUrl()){
_20c=this.get_expandedImageUrl();
}
if(!this.get_enabled()&&this.get_disabledImageUrl()){
_20c=this.get_disabledImageUrl();
}
if(this._clicked&&this.get_clickedImageUrl()){
_20c=this.get_clickedImageUrl();
}
if(_20c&&this.get_element()){
var _20d=this.get_imageElement();
if(!_20d){
_20d=this._createImageElement();
}
_20c=_20c.replace(/&amp;/ig,"&");
if(_20c!=_20d.src){
_20d.src=_20c;
}
}
},_createImageElement:function(){
this._imageElement=document.createElement("img");
this._imageElement.className=this._leftImageCssClass;
if(!this.get_enabled()){
this._imageElement.disabled="disabled";
}
var _20e=this.get_linkElement()||this.get_element();
if(_20e.firstChild){
_20e.insertBefore(this._imageElement,_20e.firstChild);
}else{
_20e.appendChild(this._imageElement);
}
return this._imageElement;
},_click:function(e){
if(!this.get_enabled()){
return false;
}
var menu=this.get_menu();
var _211=menu._getExtendedItemClickingEventArgs(new Telerik.Web.UI.RadMenuItemClickingEventArgs(this,e));
menu._raiseEvent("itemClicking",_211);
if(_211.get_cancel()){
return false;
}
if(menu.get_clickToOpen()&&this.get_level()==0){
if(menu._clicked){
this._close(e);
}else{
this._open(e);
}
menu._clicked=!menu._clicked;
}
var _212=menu._getExtendedItemClickedEventArgs(new Telerik.Web.UI.RadMenuItemClickedEventArgs(this,e));
menu._raiseEvent("itemClicked",_212);
if(this._shouldNavigate()){
return true;
}
if(this._shouldPostBack()){
menu._postback(this._getHierarchicalIndex());
}
return false;
},_shouldPostBack:function(){
if(!this.get_menu()){
return false;
}
return this.get_postBack()&&this.get_menu()._postBackReference;
},_canFocus:function(){
return (!this.get_isSeparator())&&this.get_enabled();
},_clearSiblingsWidth:function(){
var _213=this.get_parent();
var _214=_213.get_items();
for(var i=0;i<_214.get_count();i++){
var _216=_214.getItem(i);
if(_216!=this){
var _217=_216.get_linkElement();
if(_217){
_217.style.width="auto";
}
}
if($telerik.isSafari){
_213.get_childListElement().style.width="auto";
}
}
},_doFocus:function(e){
if(!this._canFocus()){
return;
}
this._ensureChildControls();
var _219=this.get_parent();
var _21a=_219.get_openedItem();
if(_21a&&_21a!=this){
_21a._close(e);
}
if(_219._state!=Telerik.Web.UI.RadMenuItemState.Open&&_219.open){
_219._open(e);
}
_219._focusedItem=this;
var menu=this.get_menu();
menu._focusedItem=this;
var _21c=this.get_linkElement();
if(!this.get_focused()&&_21c){
_21c.focus();
}
this.get_menu()._raiseEvent("itemFocus",new Telerik.Web.UI.RadMenuItemFocusEventArgs(this,e));
},_doBlur:function(e){
if(this.get_isSeparator()){
return;
}
if(this.get_focused()){
this.get_linkElement().blur();
}
this.get_parent()._focusedItem=null;
var menu=this.get_menu();
var _21f=this;
window.setTimeout(function(){
if(menu._focusedItem==_21f){
menu._focusedItem=null;
}
},100);
this.get_menu()._raiseEvent("itemBlur",new Telerik.Web.UI.RadMenuItemBlurEventArgs(this,e));
},_createChildControls:function(){
Telerik.Web.UI.RadMenuItem.callBaseMethod(this,"_createChildControls");
this._initializeScroller();
},_onScrollArrowMouseDown:function(_220){
if(!this._scroller){
return;
}
this._scroller.changeScrollSpeed(Telerik.Web.UI.ScrollerSpeed.Fast);
},_onScrollArrowMouseUp:function(_221){
if(!this._scroller){
return;
}
this._scroller.changeScrollSpeed(Telerik.Web.UI.ScrollerSpeed.Slow);
},_onScrollArrowMouseOver:function(_222){
if(!this._scroller){
return;
}
var _223=1;
if(_222==Telerik.Web.UI.ArrowPosition.Top||_222==Telerik.Web.UI.ArrowPosition.Left){
_223=-1;
}
this._scroller.startScroll(Telerik.Web.UI.ScrollerSpeed.Slow,_223);
},_onScrollArrowMouseOut:function(_224){
if(!this._scroller){
return;
}
this._scroller.stopScroll();
},_onKeyDown:function(e){
var _226=e.keyCode?e.keyCode:e.rawEvent.keyCode;
var rtl=this.get_menu().get_rightToLeft();
switch(_226){
case Sys.UI.Key.up:
if(!rtl){
this._onKeyboardUp(e);
}else{
this._onKeyboardDown(e);
}
break;
case Sys.UI.Key.down:
if(!rtl){
this._onKeyboardDown(e);
}else{
this._onKeyboardUp(e);
}
break;
case Sys.UI.Key.left:
if(!rtl){
this._onKeyboardLeft(e);
}else{
this._onKeyboardRight(e);
}
break;
case Sys.UI.Key.right:
if(!rtl){
this._onKeyboardRight(e);
}else{
this._onKeyboardLeft(e);
}
break;
case Sys.UI.Key.esc:
this._onKeyboardEsc(e);
break;
default:
return true;
}
e.preventDefault();
return false;
},_onKeyboardUp:function(e){
var _229=this._getParentFlow();
if(_229==Telerik.Web.UI.ItemFlow.Vertical){
this.focusPreviousItem(e);
}else{
this.focusLastChild(e);
}
},_onKeyboardDown:function(e){
var _22b=this._getParentFlow();
if(_22b==Telerik.Web.UI.ItemFlow.Vertical){
this.focusNextItem(e);
}else{
this.focusFirstChild(e);
}
},_onKeyboardLeft:function(e){
var _22d=this._getParentFlow();
if(_22d==Telerik.Web.UI.ItemFlow.Horizontal){
this.focusPreviousItem(e);
return;
}
var _22e=this.get_items();
var _22f=this.get_groupSettings();
if(_22e.get_count()>0&&_22f.get_expandDirection()==Telerik.Web.UI.ExpandDirection.Left){
this.focusFirstChild(e);
return;
}
var _230=this.get_parent();
var _231=null;
if(_230.get_groupSettings){
var _231=_230.get_groupSettings();
}
if(_231&&_231.get_expandDirection()==Telerik.Web.UI.ExpandDirection.Right){
_230._focus(e);
return;
}
var _232=this.get_menu().get_openedItem();
if(_232){
_232.focusPreviousItem(e);
}
},_onKeyboardRight:function(e){
var _234=this._getParentFlow();
if(_234==Telerik.Web.UI.ItemFlow.Horizontal){
this.focusNextItem(e);
return;
}
var _235=this.get_items();
var _236=this.get_groupSettings();
if(_235.get_count()>0&&_236.get_expandDirection()==Telerik.Web.UI.ExpandDirection.Right){
this.focusFirstChild(e);
return;
}
var _237=this.get_parent();
var _238=null;
if(_237.get_groupSettings){
var _238=_237.get_groupSettings();
}
if(_238&&_238.get_expandDirection()==Telerik.Web.UI.ExpandDirection.Left){
_237.focus();
return;
}
var _239=this.get_menu().get_openedItem();
if(_239){
_239.focusNextItem(e);
}
},_onKeyboardEsc:function(e){
var _23b=this.get_parent();
var menu=this.get_menu();
if(_23b==menu){
this._blur(e);
}else{
_23b._close(e);
_23b._focus(e);
}
},_render:function(html){
var _23e="rmItem";
var _23f=false;
if(this.get_parent().get_items().get_count()==1){
_23f=true;
}
html[html.length]="<li class='"+this._determineCssClass()+"'>";
this._renderLink(html);
if(this.get_imageUrl()){
this._renderImage(html);
}
html[html.length]="<span class='rmText'>";
html[html.length]=this.get_text();
html[html.length]="</span></a>";
var _240=this.get_items();
var _241=_240.get_count();
this._renderChildList(html);
html[html.length]="</li>";
},_renderAccessKey:function(){
if(this.get_isSeparator()||this.get_templated()){
return;
}
var _242=this.get_linkElement();
if(!_242){
return;
}
var _243=this.get_linkElement().accessKey.toLowerCase();
if(!_243){
return;
}
var text=this.get_text();
var _245=text.toLowerCase().indexOf(_243);
if(text.toLowerCase().indexOf("<u>")!=-1){
return;
}
if(_245==-1){
return;
}
var _246=this.get_textElement();
_246.innerHTML=text.substr(0,_245)+"<u>"+text.substr(_245,1)+"</u>"+text.substr(_245+1,text.length);
},_getIsImageOnly:function(){
if(this._isImageOnly===null){
this._isImageOnly=this.get_imageElement()!=null;
}
return this._isImageOnly;
},_getFlowCssClass:function(){
if(this.get_groupSettings().get_flow()==Telerik.Web.UI.ItemFlow.Vertical){
return this._verticalCssClass;
}else{
return this._horizontalCssClass;
}
},_isWebServiceCallNeeded:function(){
if(this._itemsLoading){
return false;
}
return (!this._itemsLoaded&&this.get_expandMode()==Telerik.Web.UI.MenuItemExpandMode.WebService);
},_createLoadingItem:function(){
var _247=this.get_menu().get_loadingTemplate();
if(_247===""){
return;
}
var _248=new Telerik.Web.UI.RadMenuItem();
this.get_items().add(_248);
_248.set_text(_247);
},_removeLoadingItem:function(){
if(this.get_menu().get_loadingTemplate()===""){
return;
}
var _249=this.get_items().getItem(0);
this.get_items().remove(_249);
},_loadChildrenFromWebService:function(){
this.get_menu()._loadChildrenFromWebService(this);
},_onChildrenLoading:function(){
this._itemsLoading=true;
this._createLoadingItem();
this._doOpen(null);
},_onChildrenLoaded:function(){
this._removeLoadingItem();
this._itemsLoaded=true;
this._itemsLoading=false;
this._slide.updateSize();
if(this._hovered){
this._doOpen(null);
}
},_onChildrenLoadingError:function(){
this._close(null);
this._removeLoadingItem();
this._itemsLoaded=false;
this._itemsLoading=false;
},_adjustSiblingsWidth:function(){
var _24a=this.get_parent();
if(_24a){
this._clearSiblingsWidth();
Telerik.Web.UI.RadMenu._adjustChildrenWidth(_24a);
}
}};
Telerik.Web.UI.RadMenuItem.registerClass("Telerik.Web.UI.RadMenuItem",Telerik.Web.UI.ControlItem);
Type.registerNamespace("Telerik.Web.UI");
Telerik.Web.UI.RadMenuItemCollection=function(_24b){
Telerik.Web.UI.RadMenuItemCollection.initializeBase(this,[_24b]);
};
Telerik.Web.UI.RadMenuItemCollection.prototype={};
Telerik.Web.UI.RadMenuItemCollection.registerClass("Telerik.Web.UI.RadMenuItemCollection",Telerik.Web.UI.ControlItemCollection);
Type.registerNamespace("Telerik.Web.UI");
Telerik.Web.UI.RadMenuItemGroupSettings=function(_24c,_24d){
this._flow=Telerik.Web.UI.ItemFlow.Vertical;
this._expandDirection=Telerik.Web.UI.ExpandDirection.Auto;
this._offsetX=0;
this._offsetY=0;
this._width=null;
this._height=null;
if(typeof (_24c.flow)!="undefined"){
this._flow=_24c.flow;
}else{
if(_24d){
this._flow=_24d.get_flow();
}
}
if(typeof (_24c.expandDirection)!="undefined"){
this._expandDirection=_24c.expandDirection;
}else{
if(_24d){
this._expandDirection=_24d.get_expandDirection();
}
}
if(typeof (_24c.offsetX)!="undefined"){
this._offsetX=_24c.offsetX;
}else{
if(_24d){
this._offsetX=_24d.get_offsetX();
}
}
if(typeof (_24c.offsetY)!="undefined"){
this._offsetY=_24c.offsetY;
}else{
if(_24d){
this._offsetY=_24d.get_offsetY();
}
}
if(typeof (_24c.width)!="undefined"){
this._width=_24c.width;
}else{
if(_24d){
this._width=_24d.get_width();
}
}
if(typeof (_24c.height)!="undefined"){
this._height=_24c.height;
}else{
if(_24d){
this._height=_24d.get_height();
}
}
};
Telerik.Web.UI.RadMenuItemGroupSettings.prototype={get_flow:function(){
return this._flow;
},set_flow:function(_24e){
this._flow=_24e;
},get_expandDirection:function(){
return this._expandDirection;
},set_expandDirection:function(_24f){
this._expandDirection=_24f;
},get_offsetX:function(){
return this._offsetX;
},set_offsetX:function(_250){
this._offsetX=_250;
},get_offsetY:function(){
return this._offsetY;
},set_offsetY:function(_251){
this._offsetY=_251;
},get_width:function(){
return this._width;
},set_width:function(_252){
this._width=_252;
},get_height:function(){
return this._height;
},set_height:function(_253){
this._height=_253;
}};
Telerik.Web.UI.RadMenuItemGroupSettings.registerClass("Telerik.Web.UI.RadMenuItemGroupSettings");
Telerik.Web.UI.MenuItemScroller=function(_254,_255){
this._leftArrowCssClass="rmLeftArrow";
this._rightArrowCssClass="rmRightArrow";
this._topArrowCssClass="rmTopArrow";
this._bottomArrowCssClass="rmBottomArrow";
this._leftArrowDisabledCssClass="rmLeftArrowDisabled";
this._rightArrowDisabledCssClass="rmRightArrowDisabled";
this._topArrowDisabledCssClass="rmTopArrowDisabled";
this._bottomArrowDisabledCssClass="rmBottomArrowDisabled";
this._arrowsZIndex=2000;
this._scroller=null;
this._childListElement=_254;
this._scrollElement=null;
this._orientation=null;
this._minScrollPosition=null;
this._itemFlow=_255;
this._scrollerPositionChangedDelegate=null;
this._decArrow=null;
this._incArrow=null;
};
Telerik.Web.UI.MenuItemScroller.prototype={initialize:function(){
this._childListElement.style.position="relative";
this._scrollElement=this._childListElement.parentNode;
this._orientation=Telerik.Web.UI.ScrollerOrientation.Horizontal;
if(this._itemFlow==Telerik.Web.UI.ItemFlow.Vertical){
this._orientation=Telerik.Web.UI.ScrollerOrientation.Vertical;
}
this._scroller=new Telerik.Web.UI.Scroller(this._childListElement,this._scrollElement,this._orientation);
this._scroller.initialize();
this._createArrows();
this._scroller.resetState();
this._scrollerPositionChangedDelegate=Function.createDelegate(this,this._onScrollerPositionChanged);
this._scroller.add_positionChanged(this._scrollerPositionChangedDelegate);
},dispose:function(){
if(this._scroller){
this._scroller.dispose();
this._scroller=null;
}
this._scrollerPositionChangedDelegate=null;
},updateState:function(){
this._updateScrollingLimits();
this._updateArrows();
},resetState:function(){
this._scroller.resetState();
},startScroll:function(_256,_257){
this._scroller.startScroll(_256,_257);
},changeScrollSpeed:function(_258){
this._scroller.changeScrollSpeed(_258);
},stopScroll:function(){
this._scroller.stopScroll();
},_createArrows:function(){
this._decArrow=this._createArrowDomElement();
this._incArrow=this._createArrowDomElement();
if(this._orientation==Telerik.Web.UI.ScrollerOrientation.Vertical){
this._decArrow.style.left="0px";
this._decArrow.style.top="0px";
this._incArrow.style.left="0px";
this._incArrow.style.bottom="0px";
}else{
this._decArrow.style.top="0px";
this._decArrow.style.left="-1px";
this._incArrow.style.top="0px";
this._incArrow.style.right="-1px";
}
},_createArrowDomElement:function(){
var _259=document.createElement("a");
_259.href="#";
_259.style.zIndex=this._arrowsZIndex;
_259.appendChild(document.createTextNode("&nbsp;"));
this._scrollElement.appendChild(_259);
return _259;
},_updateArrows:function(){
var _25a=this._scroller.isAtMinPosition();
var _25b=this._scroller.isAtMaxPosition();
if(_25a){
this._decArrow.disabled="disabled";
this._setElementCssClass(this._decArrow,this._getDecArrowCssClass(false));
}else{
this._decArrow.disabled="";
this._setElementCssClass(this._decArrow,this._getDecArrowCssClass(true));
}
if(_25b){
this._incArrow.disabled="disabled";
this._setElementCssClass(this._incArrow,this._getIncArrowCssClass(false));
}else{
this._incArrow.disabled="";
this._setElementCssClass(this._incArrow,this._getIncArrowCssClass(true));
}
},_updateScrollingLimits:function(){
var _25c=0;
var _25d=0;
var _25e=0;
if(this._orientation==Telerik.Web.UI.ScrollerOrientation.Vertical){
_25c=this._childListElement.offsetHeight-this._scrollElement.offsetHeight;
_25d=this._decArrow.offsetHeight;
_25e=this._incArrow.offsetHeight;
}else{
_25c=this._childListElement.offsetWidth-this._scrollElement.offsetWidth;
_25d=this._decArrow.offsetWidth;
_25e=this._incArrow.offsetWidth;
}
var _25f=0;
var _260=_25c;
this._scroller.setScrollingLimits(_25f,_260);
},_getDecArrowCssClass:function(_261){
if(this._orientation==Telerik.Web.UI.ScrollerOrientation.Vertical){
return _261?this._topArrowCssClass:this._topArrowDisabledCssClass;
}else{
return _261?this._leftArrowCssClass:this._leftArrowDisabledCssClass;
}
},_getIncArrowCssClass:function(_262){
if(this._orientation==Telerik.Web.UI.ScrollerOrientation.Vertical){
return _262?this._bottomArrowCssClass:this._bottomArrowDisabledCssClass;
}else{
return _262?this._rightArrowCssClass:this._rightArrowDisabledCssClass;
}
},_setElementCssClass:function(_263,_264){
var _265=_263.className;
if(_265!=_264){
_263.className=_264;
}
},_onScrollerPositionChanged:function(_266,_267){
this._updateArrows();
}};
Telerik.Web.UI.MenuItemScroller.registerClass("Telerik.Web.UI.MenuItemScroller",null,Sys.IDisposable);

