Telerik.Web.UI.RadComboBoxEventArgs=function(e){
Telerik.Web.UI.RadComboBoxEventArgs.initializeBase(this);
this._domEvent=e;
};
Telerik.Web.UI.RadComboBoxEventArgs.prototype={get_domEvent:function(){
return this._domEvent;
}};
Telerik.Web.UI.RadComboBoxEventArgs.registerClass("Telerik.Web.UI.RadComboBoxEventArgs",Sys.EventArgs);
Telerik.Web.UI.RadComboBoxCancelEventArgs=function(e){
Telerik.Web.UI.RadComboBoxCancelEventArgs.initializeBase(this);
this._domEvent=e;
};
Telerik.Web.UI.RadComboBoxCancelEventArgs.prototype={get_domEvent:function(){
return this._domEvent;
}};
Telerik.Web.UI.RadComboBoxCancelEventArgs.registerClass("Telerik.Web.UI.RadComboBoxCancelEventArgs",Sys.CancelEventArgs);
Telerik.Web.UI.RadComboBoxItemEventArgs=function(_3,e){
Telerik.Web.UI.RadComboBoxItemEventArgs.initializeBase(this);
this._item=_3;
this._domEvent=e;
};
Telerik.Web.UI.RadComboBoxItemEventArgs.prototype={get_item:function(){
return this._item;
},get_domEvent:function(){
return this._domEvent;
}};
Telerik.Web.UI.RadComboBoxItemEventArgs.registerClass("Telerik.Web.UI.RadComboBoxItemEventArgs",Sys.EventArgs);
Telerik.Web.UI.RadComboBoxItemCancelEventArgs=function(_5,e){
Telerik.Web.UI.RadComboBoxItemCancelEventArgs.initializeBase(this);
this._item=_5;
this._domEvent=e;
};
Telerik.Web.UI.RadComboBoxItemCancelEventArgs.prototype={get_item:function(){
return this._item;
},get_domEvent:function(){
return this._domEvent;
}};
Telerik.Web.UI.RadComboBoxItemCancelEventArgs.registerClass("Telerik.Web.UI.RadComboBoxItemCancelEventArgs",Sys.CancelEventArgs);
Telerik.Web.UI.RadComboBoxRequestEventArgs=function(_7,e){
Telerik.Web.UI.RadComboBoxRequestEventArgs.initializeBase(this);
this._text=_7;
this._domEvent=e;
};
Telerik.Web.UI.RadComboBoxRequestEventArgs.prototype={get_text:function(){
return this._text;
},get_domEvent:function(){
return this._domEvent;
}};
Telerik.Web.UI.RadComboBoxRequestEventArgs.registerClass("Telerik.Web.UI.RadComboBoxRequestEventArgs",Sys.EventArgs);
Telerik.Web.UI.RadComboBoxRequestCancelEventArgs=function(_9,_a,e){
Telerik.Web.UI.RadComboBoxRequestCancelEventArgs.initializeBase(this);
this._text=_9;
this._context=_a;
this._domEvent=e;
};
Telerik.Web.UI.RadComboBoxRequestCancelEventArgs.prototype={get_text:function(){
return this._text;
},get_context:function(){
return this._context;
},get_domEvent:function(){
return this._domEvent;
}};
Telerik.Web.UI.RadComboBoxRequestCancelEventArgs.registerClass("Telerik.Web.UI.RadComboBoxRequestCancelEventArgs",Sys.CancelEventArgs);
Telerik.Web.UI.RadComboBoxItemsRequestFailedEventArgs=function(_c,_d,e){
Telerik.Web.UI.RadComboBoxItemsRequestFailedEventArgs.initializeBase(this);
this._text=_c;
this._errorMessage=_d;
this._domEvent=e;
};
Telerik.Web.UI.RadComboBoxItemsRequestFailedEventArgs.prototype={get_text:function(){
return this._text;
},get_errorMessage:function(){
return this._errorMessage;
},get_domEvent:function(){
return this._domEvent;
}};
Telerik.Web.UI.RadComboBoxItemsRequestFailedEventArgs.registerClass("Telerik.Web.UI.RadComboBoxItemsRequestFailedEventArgs",Telerik.Web.UI.RadComboBoxCancelEventArgs);
Type.registerNamespace("Telerik.Web.UI");
Telerik.Web.UI.Keys=function(){
};
Telerik.Web.UI.Keys.prototype={Shift:16,Escape:27,Up:38,Down:40,Left:37,Right:39,Enter:13,Tab:9,Space:32,PageUp:33,Del:46,F1:112,F12:123};
Telerik.Web.UI.Keys.registerEnum("Telerik.Web.UI.Keys");
Telerik.Web.UI.RadComboBoxFilter=function(){
};
Telerik.Web.UI.RadComboBoxFilter.prototype={None:0,Contains:1,StartsWith:2};
Telerik.Web.UI.RadComboBoxFilter.registerEnum("Telerik.Web.UI.RadComboBoxFilter");
Telerik.Web.UI.RadComboBox=function(_f){
Telerik.Web.UI.RadComboBox.initializeBase(this,[_f]);
this._callbacktext="";
this._changeText=true;
this._children=null;
this._virtualScroll=true;
this._itemData=null;
this._selectedItem=null;
this._selectedIndex=null;
this._highlightedItem=null;
this._dropDownVisible=false;
this._enableLoadOnDemand=false;
this._enableTextSelection=true;
this._setSelectedItem=false;
this._enableItemCaching=false;
this._openDropDownOnLoad=false;
this._appendItems=false;
this._allowCustomText=false;
this._markFirstMatch=false;
this._filter=0;
this._originalText=this.get_inputDomElement().value;
this._cachedText=this._originalText;
this._cachedOffsetHeight="";
this._text="";
this._value=null;
this._isCaseSensitive=false;
this._autoCompleteSeparator=null;
this._postBackReference=null;
this._dropDownElement=null;
this._inputDomElement=null;
this._imageDomElement=null;
this._tableElement=null;
this._itemRequestTimeout=300;
this._isTemplated=false;
this._requestTimeoutID=0;
this._highlightTemplatedItems=false;
this._clientState={value:"",text:"",enabled:true,logEntries:[]};
this._uniqueId=null;
this._rightToLeft=false;
this._isDetached=false;
this._offsetX=0;
this._offsetY=0;
this._overlay=null;
this._enableScreenBoundaryDetection=true;
this._suppressChange=false;
this._lastKeyCode=null;
this._loadingDiv=null;
this._loadingMessage="Loading...";
this._showMoreResultsBox=false;
this._closeDropDownOnBlur=true;
this._focused=false;
this._causesValidation=true;
this.get_inputDomElement().setAttribute("autocomplete","off");
this._errorMessage="CallBack Error!";
this._showMoreMessage="";
this._webServiceSettings=new Telerik.Web.UI.WebServiceSettings({});
this._webServiceLoader=null;
this._clientDataString=null;
this._scrollbarWidth=16;
this._enabled=true;
this._fireEvents=this._enabled;
this._slide=null;
this._expandAnimation=new Telerik.Web.UI.AnimationSettings({});
this._expandDelay=100;
this._collapseAnimation=new Telerik.Web.UI.AnimationSettings({});
this._collapseDelay=500;
this._slideDirection=Telerik.Web.UI.SlideDirection.Down;
this._expandAnimationEndedDelegate=null;
this._expandAnimationStartedDelegate=null;
this._showDropDownOnTextboxClick=true;
this._dropDownWidth="";
this._height="";
this._maxHeight="";
this._childListElementWrapper=null;
this._skin="";
this._skipLoadingItems=false;
this._ajaxRequest=false;
this._endOfItems=false;
this._emptyMessage=null;
this._disposed=false;
this._disposeChildElements=true;
this._firstOpeningOfDropDown=true;
this.lodHashTable={};
};
Telerik.Web.UI.RadComboBox._getScrollBarWidth=function(){
if(Telerik.Web.UI.RadComboBox._scrollbarWidth){
return Telerik.Web.UI.RadComboBox._scrollbarWidth;
}
var _10,_11=0;
var _12=document.createElement("div");
_12.style.position="absolute";
_12.style.top="-1000px";
_12.style.left="-1000px";
_12.style.width="100px";
_12.style.height="50px";
_12.style.overflow="hidden";
var _13=document.createElement("div");
_13.style.width="100%";
_13.style.height="200px";
_12.appendChild(_13);
document.body.appendChild(_12);
var _14=_13.offsetWidth;
_12.style.overflow="auto";
var _15=_13.offsetWidth;
Telerik.Web.UI.RadComboBox._scrollbarWidth=_14-_15;
if(Telerik.Web.UI.RadComboBox._scrollbarWidth<=0){
_13.style.width="300px";
_10=_12.offsetWidth;
_11=_12.clientWidth;
Telerik.Web.UI.RadComboBox._scrollbarWidth=_10-_11;
}
if(Telerik.Web.UI.RadComboBox._scrollbarWidth<=0){
Telerik.Web.UI.RadComboBox._scrollbarWidth=16;
}
document.body.removeChild(document.body.lastChild);
return Telerik.Web.UI.RadComboBox._scrollbarWidth;
};
Telerik.Web.UI.RadComboBox.ComboBoxes=[];
Telerik.Web.UI.RadComboBox._createChildControls=function(_16,_17){
var _18=_16.get_itemData();
if(!_18){
return;
}
var _19=_16.get_childListElement();
if(!_19){
return;
}
var _1a=$telerik.getChildrenByTagName(_16.get_childListElement(),"li");
var _1b=_1a.length;
var _1c=0;
if(_1a.length>0&&_1a[0].className=="rcbLoading"){
_1b=_1b-1;
_1c=1;
}
for(var i=_1c,_1e=_1a.length;i<_1e;i++){
var _1f=new Telerik.Web.UI.RadComboBoxItem();
_17.add(_1f);
_1f._initialize(_18[i-_1c],_1a[i]);
}
};
Telerik.Web.UI.RadComboBox.prototype={initialize:function(){
Telerik.Web.UI.ControlItemContainer.callBaseMethod(this,"initialize");
this._log.initialize();
this._initializeEventMap();
this._clientState.value=this._value;
this._clientState.text=this._text;
this.updateClientState();
if(this._requiresRightToLeft()){
this._initRightToLeft();
}
if(this.get_childListElement()){
this._onDropDownClickDelegate=Function.createDelegate(this,this._onDropDownClick);
$addHandler(this.get_childListElement(),"click",this._onDropDownClickDelegate);
this._onDropDownHoverDelegate=Function.createDelegate(this,this._onDropDownHover);
$addHandler(this.get_childListElement(),"mouseover",this._onDropDownHoverDelegate);
this._cancelDelegate=Function.createDelegate(this,this._cancelEvent);
$addHandler(this.get_childListElement(),"selectstart",this._cancelDelegate);
$addHandler(this.get_childListElement(),"dragstart",this._cancelDelegate);
this._onDropDownOutDelegate=Function.createDelegate(this,this._onDropDownOut);
$addHandler(this.get_childListElement(),"mouseout",this._onDropDownOutDelegate);
}
this._onTableHoverDelegate=Function.createDelegate(this,this._onTableHover);
$addHandler(this.get_tableElement(),"mouseover",this._onTableHoverDelegate);
this._onTableOutDelegate=Function.createDelegate(this,this._onTableOut);
$telerik.addExternalHandler(this.get_tableElement(),"mouseout",this._onTableOutDelegate);
this._onPropertyChangeDelegate=Function.createDelegate(this,this._onInputPropertyChange);
$addHandler(this.get_inputDomElement(),"propertychange",this._onPropertyChangeDelegate);
this._onFocusDelegate=Function.createDelegate(this,this._onFocus);
$addHandler(this.get_inputDomElement(),"focus",this._onFocusDelegate);
this._onDocumentClickDelegate=Function.createDelegate(this,this._onDocumentClick);
if($telerik.isIE){
document.attachEvent("onmousedown",this._onDocumentClickDelegate);
document.attachEvent("oncontextmenu",this._onDocumentClickDelegate);
}else{
$addHandler(document,"mousedown",this._onDocumentClickDelegate);
$addHandler(document,"contextmenu",this._onDocumentClickDelegate);
}
this._onDropDownScrollDelegate=Function.createDelegate(this,this._onDropDownScroll);
$addHandler(this.get_childListElementWrapper(),"scroll",this._onDropDownScrollDelegate);
this._eventMap.addHandlerForClassName("click","rcbInput",this._onInputClick);
this._eventMap.addHandlerForClassName("keydown","rcbInput",this._onKeyDown);
if(!$telerik.isIE){
this._eventMap.addHandlerForClassName("input","rcbInput",this._onInputChange);
}
if(this.get_imageDomElement()){
this._onImageClickDelegate=Function.createDelegate(this,this._onImageClick);
$addHandler(this.get_imageDomElement(),"click",this._onImageClickDelegate);
}
this._onWindowResizeDelegate=Function.createDelegate(this,this._onWindowResize);
$addHandler(window,"resize",this._onWindowResizeDelegate);
this._onWindowUnloadDelegate=Function.createDelegate(this,this._onWindowUnload);
$addHandler(window,"unload",this._onWindowUnloadDelegate);
if(this._openDropDownOnLoad){
this._onOpenOnLoad=Function.createDelegate(this,this.showDropDown);
$addHandler(window,"load",this._onOpenOnLoad);
}
if(this.get_moreResultsBoxElement()){
this._onMoreResultsBoxClickDelegate=Function.createDelegate(this,this._onMoreResultsBoxClick);
$addHandler(this.get_moreResultsBoxElement(),"click",this._onMoreResultsBoxClickDelegate);
this._onMoreResultsBoxOverDelegate=Function.createDelegate(this,this._onMoreResultsBoxOver);
$addHandler(this.get_moreResultsBoxElement(),"mouseover",this._onMoreResultsBoxOverDelegate);
this._onMoreResultsBoxOutDelegate=Function.createDelegate(this,this._onMoreResultsBoxOut);
$addHandler(this.get_moreResultsBoxElement(),"mouseout",this._onMoreResultsBoxOutDelegate);
}
if(this._openDropDownOnLoad&&!this.get_dropDownVisible()){
this.showDropDown();
}
var me=this;
Array.add(Telerik.Web.UI.RadComboBox.ComboBoxes,this);
if(this._fireEvents){
this.raiseEvent("load",null);
}
this.get_element().value=this._text;
},_applyZIndex:function(){
var _21=this.get_element().style.zIndex;
var _22=this.get_dropDownElement().parentNode.style.zIndex;
if(_21==0){
_21=_22;
}
this.get_dropDownElement().parentNode.style.zIndex=_21;
},_initializeAnimation:function(){
var _23=this._getAnimatedElement();
if(_23){
this._slide=new Telerik.Web.UI.Slide(_23,this.get_expandAnimation(),this.get_collapseAnimation());
this._slide.initialize();
this._slide.set_direction(this.get_slideDirection());
}
this._expandAnimationEndedDelegate=Function.createDelegate(this,this._onExpandAnimationEnded);
this._slide.add_expandAnimationEnded(this._expandAnimationEndedDelegate);
this._expandAnimationStartedDelegate=Function.createDelegate(this,this._onExpandAnimationStarted);
this._slide.add_expandAnimationStarted(this._expandAnimationStartedDelegate);
},_onExpandAnimationEnded:function(_24,e){
if(window.netscape&&!window.opera){
this.get_childListElementWrapper().style.overflow="auto";
if(this.get_selectedItem()){
this.get_selectedItem().scrollOnTop();
}
}
},_onExpandAnimationStarted:function(_26,e){
if(window.netscape&&!window.opera){
this.get_childListElementWrapper().style.overflow="hidden";
}
},_requiresRightToLeft:function(){
var _28=this.get_element();
while(_28.nodeType!==9){
if(_28.dir=="rtl"){
return true;
}
_28=_28.parentNode;
}
return false;
},_initRightToLeft:function(){
this._rightToLeft=true;
if(this._skin){
this.get_element().className=String.format("{0} RadComboBox_{1}_rtl",this.get_element().className,this._skin);
this.get_dropDownElement().className=String.format("{0} RadComboBoxDropDown_{1}_rtl",this.get_dropDownElement().className,this._skin);
}
if(this.get_imageDomElement()){
if(Sys.UI.DomElement.containsCssClass(this.get_imageDomElement().parentNode,"rcbArrowCellRight")){
this._replaceCssClass(this.get_imageDomElement().parentNode,"rcbArrowCellRight","rcbArrowCellLeft");
this.get_inputDomElement().parentNode.className="rcbInputCell rcbInputCellRight";
}else{
this._replaceCssClass(this.get_imageDomElement().parentNode,"rcbArrowCellLeft","rcbArrowCellRight");
this.get_inputDomElement().parentNode.className="rcbInputCell rcbInputCellLeft";
}
}
},_replaceCssClass:function(_29,_2a,_2b){
_29.className=_29.className.replace(_2a,_2b);
},dispose:function(){
Array.remove(Telerik.Web.UI.RadComboBox.ComboBoxes,this);
if(this._expandAnimationEndedDelegate){
if(this._slide){
this._slide.remove_expandAnimationEnded(this._expandAnimationEndedDelegate);
}
this._expandAnimationEndedDelegate=null;
}
if(this._expandAnimationStartedDelegate){
if(this._slide){
this._slide.remove_expandAnimationStarted(this._expandAnimationStartedDelegate);
}
this._expandAnimationStartedDelegate=null;
}
$removeHandler(window,"unload",this._onWindowUnloadDelegate);
$removeHandler(window,"resize",this._onWindowResizeDelegate);
$removeHandler(this.get_inputDomElement(),"propertychange",this._onPropertyChangeDelegate);
$removeHandler(this.get_inputDomElement(),"focus",this._onFocusDelegate);
if($telerik.isIE){
document.detachEvent("onmousedown",this._onDocumentClickDelegate);
document.detachEvent("oncontextmenu",this._onDocumentClickDelegate);
}else{
$removeHandler(document,"mousedown",this._onDocumentClickDelegate);
$removeHandler(document,"contextmenu",this._onDocumentClickDelegate);
}
if(this.get_childListElement()){
$removeHandler(this.get_childListElement(),"click",this._onDropDownClickDelegate);
$removeHandler(this.get_childListElement(),"mouseover",this._onDropDownHoverDelegate);
$removeHandler(this.get_childListElement(),"mouseout",this._onDropDownOutDelegate);
$removeHandler(this.get_childListElement(),"selectstart",this._cancelDelegate);
$removeHandler(this.get_childListElement(),"dragstart",this._cancelDelegate);
}
if(this.get_tableElement()){
$removeHandler(this.get_tableElement(),"mouseover",this._onTableHoverDelegate);
$telerik.removeExternalHandler(this.get_tableElement(),"mouseout",this._onTableOutDelegate);
}
if(this.get_imageDomElement()){
$removeHandler(this.get_imageDomElement(),"click",this._onImageClickDelegate);
}
if(this._openDropDownOnLoad){
$removeHandler(window,"load",this._onOpenOnLoad);
}
if(this.get_moreResultsBoxElement()){
$removeHandler(this.get_moreResultsBoxElement(),"click",this._onMoreResultsBoxClickDelegate);
$removeHandler(this.get_moreResultsBoxElement(),"mouseover",this._onMoreResultsBoxOverDelegate);
$removeHandler(this.get_moreResultsBoxElement(),"mouseout",this._onMoreResultsBoxOutDelegate);
}
$removeHandler(this.get_childListElementWrapper(),"scroll",this._onDropDownScrollDelegate);
if(this._slide){
this._slide.dispose();
this._slide=null;
}
this._removeDropDown();
this._disposed=true;
Telerik.Web.UI.RadComboBox.callBaseMethod(this,"dispose");
this._tableElement._events=null;
this._inputDomElement._events=null;
this._imageDomElement._events=null;
this._childListElementWrapper._events=null;
},_cancelEvent:function(e){
e.preventDefault();
return false;
},_onDropDownScroll:function(e){
if(!this._virtualScroll||this._ajaxRequest||this._endOfItems){
return;
}
var _2e=this.get_items().get_count();
var _2f=22;
var _30=0;
if(_2e>0){
_2f=this.get_items().getItem(0).get_element().offsetHeight;
_30=this.get_items().getItem(_2e-1).get_element().offsetTop;
}
var _31=$telerik.getFirstChildByTagName(this.get_childListElement(),"div",0);
if(_31){
var _32=_31.offsetHeight;
if(this.get_childListElementWrapper().scrollTop+_32>=this.get_childListElement().offsetHeight-_32){
this.requestItems(this.get_text(),true);
}
}
},_detachDropDown:function(){
if((!document.readyState||document.readyState=="complete")&&(!this._isDetached)){
var _33=this._findParentForm()||document.body;
var _34=this.get_dropDownElement();
var _35=this.get_dropDownElement().parentNode;
_35.parentNode.removeChild(_35);
_35.style.marginLeft="0";
_33.insertBefore(_35,_33.firstChild);
this._isDetached=true;
}
},_removeDropDown:function(){
var _36=this.get_dropDownElement().parentNode;
_36.parentNode.removeChild(_36);
if(this._disposeChildElements){
Sys.WebForms.PageRequestManager.getInstance()._destroyTree(_36);
}
if(!$telerik.isSafari){
_36.outerHTML=null;
}
this._dropDownElement=null;
},attachDropDown:function(){
var _37=this.get_dropDownElement().parentNode;
_37.parentNode.removeChild(_37);
this.get_tableElement().parentNode.appendChild(_37);
},_findParentForm:function(){
var _38=this.get_element();
while(_38&&_38.tagName&&_38.tagName.toLowerCase()!="form"){
_38=_38.parentNode;
}
if(!_38.tagName){
_38=null;
}
return _38;
},_findNearestItem:function(_39){
while(_39.nodeType!==9){
if(_39._item&&Telerik.Web.UI.RadComboBoxItem.isInstanceOfType(_39._item)){
return _39._item;
}
_39=_39.parentNode;
}
return null;
},_positionDropDown:function(){
this._detachDropDown();
var _3a=this.get_element();
var _3b=this._getAnimationContainer();
_3b.style.position="absolute";
var _3c=$telerik.getLocation(_3a);
var _3d=this.get_dropDownElement();
var _3e=this.get_element().offsetWidth;
if(this._dropDownWidth){
_3e=this._dropDownWidth;
}
var _3f=this.get_childListElement();
var _40=this.get_childListElementWrapper();
var _41=_3c.y+this.get_offsetY()+this.get_element().offsetHeight;
_3b.style.top=_41+"px";
_3b.style.left=_3c.x+this.get_offsetX()+"px";
if(this._rightToLeft&&document.body.dir=="rtl"){
_3b.style.left="";
_3b.style.left=_3c.x+this.get_offsetX()-this._getScrollBarWidth()+"px";
}
_3d.style.display="block";
_3d.style.width=_3e+"px";
var _42=0;
if(!this._dropDownWidth){
_42=_3d.offsetWidth-_3e;
}
if(_42>0&&_42<_3e){
_3d.style.width=_3e-_42+"px";
}
if(this._rightToLeft){
_3d.dir="rtl";
}
this._determineScreenBoundaryDetection();
},_calculateItemsHeight:function(){
var _43=0;
var _44=this.get_items().get_count();
for(var i=0;i<_44;i++){
_43+=this.get_items().getItem(i).get_element().offsetHeight;
}
return _43;
},_calculateDropDownAutoHeight:function(){
var _46=this.get_dropDownElement();
var _47=this._getAnimationContainer();
var _48=$telerik.getLocation(this.get_element());
var _47=this._getAnimationContainer();
var _49=$telerik.getLocation(_47);
var _4a=$telerik.getViewPortSize();
var y=_48.y-_46.offsetHeight;
var _4c=_4a.height-_49.y;
var _4d=_49.y-this.get_element().offsetHeight;
var _4e=_4c;
var _4f=false;
var _50=0;
if(this._getHeaderElement()){
_50=_50+this._getHeaderElement().offsetHeight;
_4f=true;
}
if(this._getFooterElement()){
_50=_50+this._getFooterElement().offsetHeight;
_4f=true;
}
if(this.get_moreResultsBoxElement()){
_50=_50+this.get_moreResultsBoxElement().offsetHeight;
_4f=true;
}
if(this._enableScreenBoundaryDetection&&_4c<_4d){
_4e=_4d;
}
if(!(_4e>=0&&(this.get_childListElement().offsetHeight+_50)>=_4e)){
_4e=this.get_childListElement().offsetHeight+_50;
}
if(_4f&&_50<_4e){
this.get_childListElementWrapper().style.height=_4e-_50+"px";
}else{
this.get_childListElementWrapper().style.height=_4e+"px";
}
return _4e;
},_determineScreenBoundaryDetection:function(){
var _51=this.get_dropDownElement();
var _52=this._getAnimationContainer();
var _53=$telerik.getLocation(this.get_element());
var _52=this._getAnimationContainer();
var _54=$telerik.getLocation(_52);
var _55=$telerik.getViewPortSize();
var _56=_51.offsetHeight;
if(this._height==""&&this.get_childListElement()){
if(this._maxHeight==""||this._calculateItemsHeight()<this._maxHeight){
this._cachedOffsetHeight=_56;
_56=this._calculateDropDownAutoHeight();
}else{
if(this._maxHeight!=""){
if(this._cachedOffsetHeight!=""){
_56=this._cachedOffsetHeight;
}
this.get_dropDownElement().style.height="";
this.get_childListElementWrapper().style.height=this._maxHeight;
}
}
}
if(this._enableScreenBoundaryDetection){
if(this._elementOverflowsBottom(_55,_51,this.get_inputDomElement())){
var y=_53.y-_56;
if(y>=0){
this.set_slideDirection(Telerik.Web.UI.SlideDirection.Up);
this._getAnimationContainer().style.height=this.get_dropDownElement().offsetHeight;
this._getAnimationContainer().style.top=_53.y-this.get_offsetY()-_51.offsetHeight+"px";
if(window.netscape&&!window.opera){
this._getAnimationContainer().style.top=_53.y-this.get_offsetY()-_51.offsetHeight+2+"px";
}
if(this._height==""&&(this._maxHeight==""||this._calculateItemsHeight()<this._maxHeight)&&_56==_54.y-this.get_element().offsetHeight){
this._getAnimationContainer().style.top="0px";
}
}else{
this.set_slideDirection(Telerik.Web.UI.SlideDirection.Down);
}
}else{
this.set_slideDirection(Telerik.Web.UI.SlideDirection.Down);
}
}
this.set_dropDownVisible(true);
},_getScrollBarWidth:function(){
var _58,_59=0;
var _5a=document.createElement("div");
_5a.style.position="absolute";
_5a.style.top="-1000px";
_5a.style.left="-1000px";
_5a.style.width="100px";
_5a.style.height="50px";
_5a.style.overflow="hidden";
var _5b=document.createElement("div");
_5b.style.width="100%";
_5b.style.height="200px";
_5a.appendChild(_5b);
document.body.appendChild(_5a);
var _5c=_5b.offsetWidth;
_5a.style.overflow="auto";
var _5d=_5b.offsetWidth;
this._scrollbarWidth=_5c-_5d;
if(this._scrollbarWidth<=0){
_5b.style.width="300px";
_58=_5a.offsetWidth;
_59=_5a.clientWidth;
this._scrollbarWidth=_58-_59;
}
if(this._scrollbarWidth<=0){
this._scrollbarWidth=16;
}
document.body.removeChild(document.body.lastChild);
return this._scrollbarWidth;
},_elementOverflowsBottom:function(_5e,_5f,_60){
var _61=$telerik.getLocation(_60).y+_5f.offsetHeight;
return _61>_5e.height;
},_selectFirstMatch:function(){
var _62=this._findItemToSelect();
if(_62&&_62.get_enabled()&&!_62.get_isSeparator()){
_62.highlight();
_62.scrollOnTop();
this.set_selectedItem(_62);
}
},_findItemToSelect:function(){
var _63=this.findItemByValue(this.get_value());
if(!_63){
_63=this.findItemByText(this.get_text());
}
return _63;
},clearItems:function(){
this.get_items().clear();
this._itemData=null;
},clearSelection:function(){
this.set_text("");
this.set_value("");
this.set_selectedItem(null);
this.set_highlightedItem(null);
},decodeText:function(_64){
var _65=_64;
var _66={"&lt;":"<","&gt;":">","&amp;":"&","&quot;":"\""};
for(var _67 in _66){
_65=_65.replace(new RegExp(_67,"g"),_66[_67]);
}
return _65;
},_findNextAvailableIndex:function(_68,_69){
var _6a=this.get_visibleItems();
for(var i=_68,_6c=_6a.length;i<_6c;i++){
if(_6a[i].get_enabled()&&!_6a[i].get_isSeparator()){
if(_69==null){
return i;
}
if(_69&&_6a[i].get_text().indexOf(_69)==0){
return i;
}
}
}
return _6a.length;
},_findPrevAvailableIndex:function(_6d){
var _6e=this.get_visibleItems();
if(_6e.length<1){
return -1;
}
for(var i=_6d;i>=0;i--){
if(_6e[i].get_enabled()&&!_6e[i].get_isSeparator()){
return i;
}
}
return -1;
},_onDropDownClick:function(e){
if(this._eventMap.skipElement(e,null)){
return;
}
if(!this._enabled){
return;
}
var _71=this._findNearestItem(e.target);
if(!_71||!_71.get_enabled()||_71.get_isSeparator()){
return;
}
try{
this.get_inputDomElement().focus();
}
catch(e){
}
this._performSelect(_71,e);
this._hideDropDown(e);
if(!this.get_isTemplated()&&this.get_filter()!=Telerik.Web.UI.RadComboBoxFilter.None&&e.stopPropagation){
e.stopPropagation();
}
},_onDropDownHover:function(e){
if(!this._enabled||this._ajaxRequest){
return;
}
var _73=this._findNearestItem(e.target);
if(!_73||!_73.get_enabled()||_73.get_isSeparator()){
return;
}
_73.highlight();
},_onDropDownOut:function(e){
if(!this._enabled){
return;
}
if(!e){
e=event;
}
var _75;
try{
_75=e.toElement||e.relatedTarget||e.fromElement;
while(_75.nodeType!==9){
if(_75.parentNode==this.get_dropDownElement()){
return;
}
_75=_75.parentNode;
}
}
catch(e){
}
var _76=this.get_highlightedItem();
if(_76){
_76.unHighlight();
}
},_onTableHover:function(e){
if(!this._enabled){
return;
}
var _78=this.get_tableElement();
if(_78!=null&&_78.className!="rcbFocused"){
_78.className="rcbHovered";
}
},_onTableOut:function(e){
if(!this._enabled){
return;
}
if(!e){
e=event;
}
var _7a=this.get_tableElement();
var _7b=e.target||e.srcElement;
var _7c=e.toElement||e.relatedTarget||e.fromElement;
while(_7c&&_7c.nodeType!==9){
if(_7c.parentNode&&_7c.parentNode==_7a){
return;
}
_7c=_7c.parentNode;
}
if(_7a!=null&&_7a.className=="rcbHovered"){
_7a.className="";
}
},_onDocumentClick:function(e){
if(!e){
e=event;
}
var _7e=e.target||e.srcElement;
while(_7e.nodeType!==9){
if(_7e.parentNode==null||_7e==this.get_element()||_7e==this.get_dropDownElement()){
return;
}
_7e=_7e.parentNode;
}
if(this.get_dropDownVisible()&&this.get_closeDropDownOnBlur()){
this._hideDropDown(e);
}
if(this._focused){
this._raiseClientBlur(e);
this._selectItemOnBlur(e);
this._focused=false;
}
},_selectItemOnBlur:function(e){
var _80=this._findItemToSelect();
if(!_80&&!this.get_allowCustomText()&&this.get_items().get_count()>0){
if(this.get_markFirstMatch()){
if(this.get_text()==""){
this.set_text(this._originalText);
}
this.highlightMatches();
this.selectText(0,0);
_80=this.get_highlightedItem();
}
}
if(!this.get_allowCustomText()&&!this.get_enableLoadOnDemand()&&this.get_filter()!=Telerik.Web.UI.RadComboBoxFilter.None){
_80=this.get_highlightedItem();
if(this.get_highlightedItem()==null&&this.get_selectedItem()){
_80=this.get_selectedItem();
}else{
if(!this.get_highlightedItem()&&this.get_visibleItems().length>0){
_80=this.get_visibleItems()[0];
}
}
}
if(this.get_filter()!=Telerik.Web.UI.RadComboBoxFilter.None){
this.setAllItemsVisible(true);
}
this._performSelect(_80,e);
},_onWindowResize:function(){
if(this.get_dropDownVisible()){
this._positionDropDown();
}
},_onWindowUnload:function(){
this._disposeChildElements=false;
},_onKeyDown:function(e){
if(!this._fireEvents||this._ajaxRequest){
return;
}
if(!e){
e=event;
}
this.raise_onClientKeyPressing(e);
var _82=e.keyCode||e.which;
this._lastKeyCode=_82;
var _83=String.fromCharCode(_82);
if(_82==Telerik.Web.UI.Keys.Escape&&this.get_dropDownVisible()){
if(this.get_dropDownVisible()){
this._hideDropDown(e);
}
return;
}else{
if(_82===Telerik.Web.UI.Keys.Enter){
if(this.get_dropDownVisible()){
this._hideDropDown(e);
}
this._performSelect(this.get_highlightedItem(),e);
e.returnValue=false;
if(e.preventDefault){
e.preventDefault();
}
return;
}else{
if(_82===Telerik.Web.UI.Keys.Down){
e.returnValue=false;
if(e.altKey){
this._toggleDropDown(e);
return;
}
this.highlightNextItem(null);
if(e.preventDefault){
e.preventDefault();
}
return;
}else{
if(_82===Telerik.Web.UI.Keys.Up){
e.returnValue=false;
if(e.altKey){
this._toggleDropDown(e);
return;
}
this.highlightPreviousItem();
if(e.preventDefault){
e.preventDefault();
}
return;
}else{
if(_82===Telerik.Web.UI.Keys.Tab){
if(this.get_dropDownVisible()){
this._hideDropDown(e);
}
this._raiseClientBlur(e);
this._selectItemOnBlur(e);
this._focused=false;
return;
}
}
}
}
}
if(_82==Telerik.Web.UI.Keys.Left||_82==Telerik.Web.UI.Keys.Right){
return;
}
if(_83&&!(this.get_enableLoadOnDemand()||!this.get_readOnly())){
this.highlightNextItem(_83);
return;
}
},_onImageClick:function(e){
if(this._enabled){
if(!this.get_dropDownVisible()){
this._selectFirstMatch();
}
this._toggleDropDown(e);
}
},_onInputClick:function(e){
if(this._enabled){
this._selectFirstMatch();
this.selectText(0,this.get_text().length);
if(!this.get_dropDownVisible()&&this._showDropDownOnTextboxClick){
this._showDropDown(e);
}
return true;
}
},_onMoreResultsBoxClick:function(e){
this.requestItems(this.get_text(),true);
},_onMoreResultsBoxOver:function(e){
this.get_moreResultsBoxElement().style.cursor="pointer";
},_onMoreResultsBoxOut:function(e){
this.get_moreResultsBoxElement().style.cursor="default";
},_onFocus:function(e){
if(this._focused){
return;
}
if(this.get_emptyMessage()&&this.get_emptyMessage()==this.get_text()){
this._suppressChange=true;
this.get_inputDomElement().value=this._text;
(function(_8a){
setTimeout(function(){
_8a.get_inputDomElement().className="rcbInput";
},0);
})(this);
this._suppressChange=false;
}
var _8b=this.get_tableElement();
if(_8b!=null){
(function(){
setTimeout(function(){
_8b.className="rcbFocused";
},0);
})();
}
if(!e&&typeof (event)!="undefined"){
e=event;
}
this._focused=true;
this.raise_onClientFocus(e);
return true;
},_raiseClientBlur:function(e){
if(this._focused){
var _8d=this.get_tableElement();
if(_8d!=null){
_8d.className="";
}
this._applyEmptyMessage();
this.raise_onClientBlur(e);
}
},_applyEmptyMessage:function(){
if(this.get_emptyMessage()&&this.get_text()==""){
this._suppressChange=true;
this.get_inputDomElement().value=this.get_emptyMessage();
this.get_inputDomElement().className+=" rcbEmptyMessage";
this._suppressChange=false;
}
},_onInputChange:function(){
this.set_value("");
var _8e=this.get_text();
if(this.get_emptyMessage()!=""&&_8e!=this.get_emptyMessage()){
this._text=_8e;
}
this.get_element().value=this._text;
this.updateClientState();
if(this.get_enableLoadOnDemand()&&!this._suppressChange){
var me=this;
if(this._requestTimeoutID>0){
window.clearTimeout(this._requestTimeoutID);
this._requestTimeoutID=0;
}
if(!this._showDropDownOnTextboxClick){
this._skipLoadingItems=true;
}
if(!this.get_dropDownVisible()){
this.showDropDown();
}
this._requestTimeoutID=window.setTimeout(function(){
if(me._disposed){
return;
}
me.requestItems(me.get_text(),false);
},me.get_itemRequestTimeout());
return;
}
if(!this._suppressChange){
if(this.get_filter()==Telerik.Web.UI.RadComboBoxFilter.None){
if(this._shouldHighlight()){
this.highlightMatches();
}
}else{
this.highlightAllMatches(this.get_text());
}
}
},_onInputPropertyChange:function(){
if(!event.propertyName){
event=event.rawEvent;
}
if(event.propertyName=="value"){
var _90=this.get_text();
if(this._cachedText!=_90){
this._cachedText=_90;
this._onInputChange(event);
}
}
},_shouldHighlight:function(){
if(this._lastKeyCode<Telerik.Web.UI.Keys.Space){
return false;
}
if(this._lastKeyCode>=Telerik.Web.UI.Keys.PageUp&&this._lastKeyCode<=Telerik.Web.UI.Keys.Del){
return false;
}
if(this._lastKeyCode>=Telerik.Web.UI.Keys.F1&&this._lastKeyCode<=Telerik.Web.UI.Keys.F12){
return false;
}
return true;
},_showDropDown:function(e){
if(this._firstOpeningOfDropDown){
this._initializeAnimation();
this._applyZIndex();
this._firstOpeningOfDropDown=false;
}
if(this.raise_dropDownOpening(e)==true){
return;
}
var _92=this._getAnimationContainer();
if(!_92){
return;
}
var _93=this.get_text();
if(this.get_emptyMessage()==this.get_text()){
_93="";
}
if(this.get_enableLoadOnDemand()&&this.get_items().get_count()==0&&!this._skipLoadingItems){
this.requestItems(_93,false);
}
_92.style.visibility="hidden";
this.get_dropDownElement().style.visibility="hidden";
this._slide.show();
this._resetAnimatedElementPosition();
this._slide.set_direction(this.get_slideDirection());
try{
this.get_inputDomElement().focus();
}
catch(e){
}
this._onFocus(e);
this.set_dropDownVisible(true);
this._positionDropDown();
var _94=this.get_dropDownElement();
_94.style.top=-_94.offsetHeight+"px";
this._slide.updateSize();
_92.style.visibility="visible";
this._slide.expand();
this.raise_dropDownOpened(e);
},_toggleDropDown:function(e){
if(this.get_dropDownVisible()){
this._hideDropDown(e);
}else{
this._showDropDown(e);
if(this.get_highlightedItem()){
this.get_highlightedItem().scrollIntoView();
}
}
},_hideDropDown:function(e){
if(!this.get_dropDownVisible()){
return;
}
if(this.raise_dropDownClosing(e)==true){
return;
}
this.get_dropDownElement().style.display="none";
if(!this._getAnimationContainer()){
return;
}
if(window.netscape&&!window.opera){
this.get_childListElementWrapper().scrollTop=0;
}
this._slide.collapse();
this.set_dropDownVisible(false);
if(this.get_filter()!=Telerik.Web.UI.RadComboBoxFilter.None){
this._removeEmTagsFromAllItems();
}
this.raise_dropDownClosed(e);
},get_dropDownElement:function(){
if(!this._dropDownElement){
this._dropDownElement=this._getChildElement("DropDown");
}
return this._dropDownElement;
},get_inputDomElement:function(){
if(!this._inputDomElement){
this._inputDomElement=this._getChildElement("Input");
}
return this._inputDomElement;
},get_moreResultsBoxMessageElement:function(){
var box=this.get_moreResultsBoxElement();
var _98=$telerik.getFirstChildByTagName(box,"span",0);
return _98;
},get_moreResultsBoxElement:function(){
var box=this._getChildElement("MoreResultsBox");
return box;
},get_emptyMessage:function(){
return this._emptyMessage;
},set_emptyMessage:function(_9a){
if(this._emptyMessage!==_9a){
this._emptyMessage=_9a;
}
this._applyEmptyMessage();
},get_imageDomElement:function(){
if(!this._imageDomElement){
this._imageDomElement=this._getChildElement("Arrow");
}
return this._imageDomElement;
},get_slideDirection:function(){
return this._slideDirection;
},set_slideDirection:function(_9b){
this._slideDirection=_9b;
this._slide.set_direction(_9b);
},hideDropDown:function(){
this._hideDropDown(null);
},showDropDown:function(){
this._showDropDown(null);
},toggleDropDown:function(){
this._toggleDropDown(null);
},_resetAnimatedElementPosition:function(){
var _9c=this._getAnimatedElement();
_9c.style.top="0px";
_9c.style.left="0px";
},get_readOnly:function(){
return !(this.get_allowCustomText()||this.get_markFirstMatch())&&this.get_filter()==Telerik.Web.UI.RadComboBoxFilter.None;
},_performSelect:function(_9d,e){
if(_9d&&_9d!=this.get_selectedItem()&&!this.get_enableLoadOnDemand()){
_9d._select(e);
return;
}
if(_9d&&_9d==this.get_selectedItem()&&this.getLastWord(this.get_text())!=_9d.get_text()&&!this.get_readOnly()){
this.set_text(_9d.get_text());
return;
}
if(_9d&&_9d==this.get_selectedItem()){
return;
}
if(_9d&&this.get_originalText()!=_9d.get_text()){
_9d._select(e);
return;
}
if(_9d&&(!this.get_selectedItem()||this.get_selectedItem().get_value()!=_9d.get_value())){
_9d._select(e);
return;
}
if(this.get_originalText()!=this.get_text()){
if(this.get_highlightedItem()){
this.get_highlightedItem().unHighlight();
}
if(this.raise_textChange(this,e)==true){
return;
}
var _9f={Command:"TextChanged"};
this.postback(_9f);
}
},set_value:function(_a0){
this._value=_a0;
this.updateClientState();
},get_value:function(){
return this._value;
},set_text:function(_a1){
_a1=this.decodeText(_a1);
this.get_element().value=_a1;
this._suppressChange=true;
var _a2=this.get_inputDomElement();
_a2.value=_a1;
this.set_value("");
if(_a2.fireEvent&&document.createEventObject){
var _a3=document.createEventObject();
_a2.fireEvent("onchange",_a3);
}else{
if(_a2.dispatchEvent){
var _a4=true;
var _a3=document.createEvent("HTMLEvents");
_a3.initEvent("change",_a4,true);
_a2.dispatchEvent(_a3);
}
}
this._suppressChange=false;
this._text=_a1;
this.updateClientState();
},get_webServiceSettings:function(){
return this._webServiceSettings;
},set_webServiceSettings:function(_a5){
var _a6=Sys.Serialization.JavaScriptSerializer.deserialize(_a5);
this._webServiceSettings=new Telerik.Web.UI.WebServiceSettings(_a6);
},get_text:function(){
return this.get_inputDomElement().value;
},enable:function(){
this.get_inputDomElement().disabled=false;
var _a7=this.get_tableElement();
if(_a7!=null){
_a7.className="";
}
this.set_enabled(true);
this.enableEvents();
var _a8=this.get_items().get_count();
for(var i=0;i<_a8;i++){
this._children.getItem(i).enable();
}
},disable:function(){
var _aa=this.get_tableElement();
if(_aa!=null){
_aa.className="rcbDisabled";
}
this.set_enabled(false);
this.get_inputDomElement().disabled="disabled";
this.disableEvents();
var _ab=this.get_items().get_count();
for(var i=0;i<_ab;i++){
this._children.getItem(i).disable();
}
},set_enabled:function(_ad){
this._enabled=_ad;
this.updateClientState();
},get_enabled:function(){
return this._enabled;
},disableEvents:function(){
this._fireEvents=false;
},enableEvents:function(){
this._fireEvents=true;
},findItemByText:function(_ae){
var _af=this.get_items();
var _b0=_af.get_count();
for(var i=0;i<_b0;i++){
if(_af.getItem(i).get_text()==_ae){
return _af.getItem(i);
}
}
return null;
},findItemByValue:function(_b2){
if(!_b2){
return null;
}
var _b3=this.get_items();
var _b4=_b3.get_count();
for(var i=0;i<_b4;i++){
if(_b3.getItem(i).get_value()==_b2){
return _b3.getItem(i);
}
}
return null;
},_getAnimationContainer:function(){
if(!this._animationContainer){
if(this.get_dropDownElement()){
this._animationContainer=this.get_dropDownElement().parentNode;
}
}
return this._animationContainer;
},highlightPreviousItem:function(){
var _b6=this.get_visibleItems();
var _b7=this.get_highlightedItem();
var _b8=0;
if(_b7){
var _b9=_b6.length;
for(var i=0;i<_b9;i++){
if(_b6[i]==_b7){
_b8=i-1;
}
}
}
_b8=this._findPrevAvailableIndex(_b8);
if(_b8>=0){
_b6[_b8].highlight();
_b6[_b8].scrollIntoView();
var _bb=this._getLastSeparatorIndex(this.get_text());
var _bc=this.get_text().substring(0,_bb+1)+_b6[_b8].get_text();
if(this.get_changeText()){
this.set_text(_bc);
this.set_value(_b6[_b8].get_value());
}
}
},highlightNextItem:function(_bd){
var _be=this.get_visibleItems();
var _bf=this.get_highlightedItem();
var _c0=0;
if(_bf){
var _c1=_be.length;
for(var i=0;i<_c1;i++){
if(_be[i]==_bf){
_c0=i+1;
}
}
}
_c0=this._findNextAvailableIndex(_c0,_bd);
if(_bd&&_c0==_be.length){
_c0=this._findNextAvailableIndex(0,_bd);
}
if(_c0<_be.length){
_be[_c0].highlight();
_be[_c0].scrollIntoView();
var _c3=this._getLastSeparatorIndex(this.get_text());
var _c4=this.get_text().substring(0,_c3+1)+_be[_c0].get_text();
if(this.get_changeText()){
this.set_text(_c4);
this.set_value(_be[_c0].get_value());
}
}
},findFirstMatch:function(_c5){
if(!_c5){
return null;
}
var _c6=this.get_items();
var _c7=_c6.get_count();
for(var i=0;i<_c7;i++){
if(_c6.getItem(i).get_text().length<_c5.length){
continue;
}
if(_c6.getItem(i).get_enabled()==false||_c6.getItem(i).get_isSeparator()){
continue;
}
var _c9=_c6.getItem(i).get_text().substring(0,_c5.length);
if(!this.get_isCaseSensitive()){
if(_c9.toLowerCase()==_c5.toLowerCase()){
return _c6.getItem(i);
}
}else{
if(_c9==_c5){
return _c6.getItem(i);
}
}
}
return null;
},highlightAllMatches:function(_ca){
if(this.get_filter()==Telerik.Web.UI.RadComboBoxFilter.None){
return;
}
if(this.get_highlightedItem()){
this.get_highlightedItem().unHighlight();
}
var _cb=this.getLastWord(_ca);
if(this._getLastSeparator(_ca)==_ca.charAt(_ca.length-1)){
this._removeEmTagsFromAllItems();
this.setAllItemsVisible(true);
return;
}
this.get_items().forEach(function(_cc,_cd){
_cc._markText(_cb);
});
if(this.get_markFirstMatch()){
this.highlightFirstValidMatch();
}
},highlightFirstValidMatch:function(){
if(this.get_text().length>0){
var _ce=this.get_visibleItems();
var _cf=_ce.length;
for(var _d0=0;_d0<_cf;_d0++){
var _d1=_ce[_d0];
if(_d1.get_enabled()==true){
_d1.highlight();
return;
}
}
}
},setAllItemsVisible:function(_d2){
var _d2=_d2;
this.get_items().forEach(function(_d3){
_d3.set_visible(_d2);
});
},_removeEmTagsFromAllItems:function(){
if(this.get_isTemplated()||this.get_filter()==Telerik.Web.UI.RadComboBoxFilter.None){
return;
}
this.get_items().forEach(function(_d4){
_d4.set_text(_d4.get_text());
});
},highlightMatches:function(){
if(!this.get_markFirstMatch()){
return;
}
var _d5=this.get_text();
var _d6=this.getLastWord(_d5);
if(this._getLastSeparator(_d5)==_d5.charAt(_d5.length-1)){
return;
}
var _d7=this.findFirstMatch(_d6);
if(this.get_highlightedItem()){
this.get_highlightedItem().unHighlight();
}
if(!_d7){
if(!this.get_allowCustomText()&&!this.get_enableLoadOnDemand()){
if(_d5){
var _d8=this._getLastSeparatorIndex(_d5);
if(_d8<_d5.length-1){
var _d9=_d5.substring(0,_d5.length-1);
if(_d9==""&&$telerik.isSafari){
var me=this;
window.setTimeout(function(){
me.set_text(_d9);
},0);
}else{
this.set_text(_d9);
this.highlightMatches();
}
}
}
}
return;
}
_d7.highlight();
_d7.scrollOnTop();
var _d8=this._getLastSeparatorIndex(_d5);
var _db=_d5.substring(0,_d8+1)+_d7.get_text();
if(_d5!=_db){
this.set_text(_db);
}
this.set_value(_d7.get_value());
var _dc=_d8+_d6.length+1;
var _dd=_db.length-_dc;
this.selectText(_dc,_dd);
},postback:function(_de){
if(!this._postBackReference){
return;
}
var _df=this._postBackReference.replace("arguments",Sys.Serialization.JavaScriptSerializer.serialize(_de));
eval(_df);
},_getLastSeparator:function(_e0){
if(!this.get_autoCompleteSeparator()){
return null;
}
var _e1=this._getLastSeparatorIndex(_e0);
return _e0.charAt(_e1);
},getLastWord:function(_e2){
var _e3=-1;
if(this.get_autoCompleteSeparator()!=null){
_e3=this._getLastSeparatorIndex(_e2);
}
var _e4=_e2.substring(_e3+1,_e2.length);
return _e4;
},get_lastWord:function(){
var _e5=this.getLastWord(this.get_text());
return _e5;
},_getLastSeparatorIndex:function(_e6){
var _e7=-1;
if(!this.get_autoCompleteSeparator()){
return _e7;
}
for(var i=0,_e9=this.get_autoCompleteSeparator().length;i<_e9;i++){
var _ea=this.get_autoCompleteSeparator().charAt(i);
var _eb=_e6.lastIndexOf(_ea);
if(_eb>_e7&&!this._checkIsThisPartOfWord(_eb,_ea)){
_e7=_eb;
}
}
return _e7;
},_checkIsThisPartOfWord:function(_ec,_ed){
var _ee="";
if(this.get_selectedItem()){
_ee=this.get_selectedItem().get_text();
}
var _ef=_ee.lastIndexOf(_ed);
if(_ef>-1&&_ef==_ec){
return true;
}
return false;
},selectText:function(_f0,_f1){
if(!this.get_enableTextSelection()){
return;
}
if(this.get_inputDomElement().createTextRange){
var _f2=this.get_inputDomElement().createTextRange();
if(_f0==0&&_f1==0){
_f2.collapse(true);
return;
}
_f2.moveStart("character",_f0);
_f2.moveEnd("character",_f1);
_f2.select();
}else{
this.get_inputDomElement().setSelectionRange(_f0,_f0+_f1);
}
},_childRemoving:function(_f3){
var _f4=_f3.get_index();
if(this._itemData){
Array.remove(this._itemData,this._itemData[_f4]);
}
Telerik.Web.UI.RadComboBox.callBaseMethod(this,"_childRemoving",[_f3]);
},_childRemoved:function(_f5,_f6){
var _f7=_f5.get_element();
if(_f5==this.get_selectedItem()){
this.set_selectedItem(null);
this.set_highlightedItem(null);
this.set_text("");
}
if(_f6.get_items().get_count()==0&&!this._getHeaderElement()&&!this._getFooterElement()){
_f7=_f6._childListElement;
_f6._childListElement=null;
}
if(_f7){
_f7.innerHTML="";
if(_f7.parentNode){
_f7.parentNode.removeChild(_f7);
}
_f7=null;
}
Telerik.Web.UI.RadComboBox.callBaseMethod(this,"_childRemoved",[_f5,_f6]);
},_childrenCleared:function(_f8){
this.set_selectedItem(null);
this.set_highlightedItem(null);
var _f9=_f8.get_childListElement();
var _fa=_f8.get_items().get_count();
if(_f9&&!this._getHeaderElement()&&!this._getFooterElement()){
for(var i=0;i<_fa;i++){
_f8.get_items().getItem(i)._dispose();
}
_f9.innerHTML="";
_f9=null;
}else{
if(_f9){
for(var i=0;i<_fa;i++){
this._childRemoved(_f8.get_items().getItem(i),_f8);
}
}
}
},_createChildControls:function(){
this._children=new Telerik.Web.UI.RadComboBoxItemCollection(this);
Telerik.Web.UI.RadComboBox._createChildControls(this,this._children);
},_ensureChildControls:function(){
if(!this._childControlsCreated){
this._createChildControls();
this._childControlsCreated=true;
if(!this._setSelectedItem){
this._setSelectedItem=true;
this._setFirstSelectedItem();
}
}
},_createChildListElement:function(){
var _fc=document.createElement("ul");
_fc.className="rcbList";
this.get_childListElementWrapper().appendChild(_fc);
this._onDropDownClickDelegate=Function.createDelegate(this,this._onDropDownClick);
$addHandler(this.get_childListElement(),"click",this._onDropDownClickDelegate);
this._onDropDownHoverDelegate=Function.createDelegate(this,this._onDropDownHover);
$addHandler(this.get_childListElement(),"mouseover",this._onDropDownHoverDelegate);
this._cancelDelegate=Function.createDelegate(this,this._cancelEvent);
$addHandler(this.get_childListElement(),"selectstart",this._cancelDelegate);
$addHandler(this.get_childListElement(),"dragstart",this._cancelDelegate);
this._onDropDownOutDelegate=Function.createDelegate(this,this._onDropDownOut);
$addHandler(this.get_childListElement(),"mouseout",this._onDropDownOutDelegate);
},_setFirstSelectedItem:function(){
var _fd=this.findItemByText(this._text);
if(_fd&&!_fd.get_isSeparator()){
this.set_selectedItem(_fd);
}
},get_childListElement:function(){
if(!this._childListElement){
var _fe=this.get_childListElementWrapper();
this._childListElement=$telerik.getFirstChildByTagName(_fe,"ul",0);
}
return this._childListElement;
},get_childListElementWrapper:function(){
if(!this._childListElementWrapper){
var _ff=this.get_dropDownElement();
if(this._getHeaderElement()){
this._childListElementWrapper=$telerik.getFirstChildByTagName(_ff,"div",1);
}else{
this._childListElementWrapper=$telerik.getFirstChildByTagName(_ff,"div",0);
}
}
return this._childListElementWrapper;
},_getHeaderElement:function(){
if(this.get_dropDownElement()){
return $telerik.getChildByClassName(this.get_dropDownElement(),"rcbHeader",0);
}
return null;
},_getFooterElement:function(){
if(this.get_dropDownElement()){
return $telerik.getChildByClassName(this.get_dropDownElement(),"rcbFooter",0);
}
return null;
},get_tableElement:function(){
if(!this._tableElement){
this._tableElement=$telerik.getFirstChildByTagName(this.get_element(),"table",0);
}
return this._tableElement;
},get_expandAnimation:function(){
return this._expandAnimation;
},set_expandAnimation:function(_100){
var _101=Sys.Serialization.JavaScriptSerializer.deserialize(_100);
this._expandAnimation=new Telerik.Web.UI.AnimationSettings(_101);
},get_collapseAnimation:function(){
return this._collapseAnimation;
},set_collapseAnimation:function(_102){
var _103=Sys.Serialization.JavaScriptSerializer.deserialize(_102);
this._collapseAnimation=new Telerik.Web.UI.AnimationSettings(_103);
},_getAnimatedElement:function(){
if(!this._animatedElement){
this._animatedElement=this.get_dropDownElement();
}
return this._animatedElement;
},get_items:function(){
return this._getChildren();
},get_visibleItems:function(){
var _104=[];
var _105=this._getChildren().get_count();
for(var i=0;i<_105;i++){
var item=this._getChildren().getItem(i);
if(item.get_visible()){
Array.add(_104,item);
}
}
return _104;
},set_items:function(_108){
this._children=_108;
},get_itemData:function(){
return this._itemData;
},set_itemData:function(_109){
this._itemData=_109;
},get_itemRequestTimeout:function(){
return this._itemRequestTimeout;
},set_itemRequestTimeout:function(_10a){
this._itemRequestTimeout=_10a;
},get_appendItems:function(){
return this._appendItems;
},set_appendItems:function(_10b){
this._appendItems=_10b;
},get_selectedItem:function(){
if(!this._setSelectedItem){
this._setSelectedItem=true;
this._setFirstSelectedItem();
}
return this._selectedItem;
},set_selectedItem:function(_10c){
this._selectedItem=_10c;
},get_selectedIndex:function(){
var _10d=this.get_selectedItem();
if(_10d){
return _10d.get_index();
}
return this._selectedIndex;
},set_selectedIndex:function(_10e){
this._selectedIndex=_10e;
},get_causesValidation:function(){
return this._causesValidation;
},set_causesValidation:function(_10f){
this._causesValidation=_10f;
},get_closeDropDownOnBlur:function(){
return this._closeDropDownOnBlur;
},set_closeDropDownOnBlur:function(_110){
this._closeDropDownOnBlur=_110;
},get_isTemplated:function(){
return this._isTemplated;
},set_isTemplated:function(_111){
this._isTemplated=_111;
},get_highlightTemplatedItems:function(){
return this._highlightTemplatedItems;
},set_highlightTemplatedItems:function(_112){
this._highlightTemplatedItems=_112;
},get_enableLoadOnDemand:function(){
return this._enableLoadOnDemand;
},set_enableLoadOnDemand:function(_113){
this._enableLoadOnDemand=_113;
},get_enableItemCaching:function(){
return this._enableItemCaching;
},set_enableItemCaching:function(_114){
this._enableItemCaching=_114;
},get_allowCustomText:function(){
return this._allowCustomText;
},set_allowCustomText:function(_115){
this._allowCustomText=_115;
},get_changeText:function(){
return this._changeText;
},set_changeText:function(_116){
this._changeText=_116;
},get_markFirstMatch:function(){
return this._markFirstMatch;
},set_markFirstMatch:function(_117){
this._markFirstMatch=_117;
},get_filter:function(){
return this._filter;
},set_filter:function(_118){
this._filter=_118;
},get_enableTextSelection:function(){
return this._enableTextSelection;
},set_enableTextSelection:function(_119){
this._enableTextSelection=_119;
},get_originalText:function(){
return this._originalText;
},set_originalText:function(_11a){
this._originalText=_11a;
},get_highlightedItem:function(){
return this._highlightedItem;
},set_highlightedItem:function(_11b){
this._highlightedItem=_11b;
},get_isCaseSensitive:function(){
return this._isCaseSensitive;
},set_isCaseSensitive:function(_11c){
this._isCaseSensitive=_11c;
},get_dropDownVisible:function(){
return this._dropDownVisible;
},set_dropDownVisible:function(_11d){
this._dropDownVisible=_11d;
},get_autoCompleteSeparator:function(){
return this._autoCompleteSeparator;
},set_autoCompleteSeparator:function(_11e){
this._autoCompleteSeparator=_11e;
},get_showMoreMessage:function(){
return this._showMoreMessage;
},set_showMoreMessage:function(_11f){
this._showMoreMessage=_11f;
},get_loadingMessage:function(){
return this._loadingMessage;
},set_loadingMessage:function(_120){
this._loadingMessage=_120;
},get_errorMessage:function(){
return this._errorMessage;
},set_errorMessage:function(_121){
this._errorMessage=_121;
},set_endOfItems:function(_122){
this._endOfItems=_122;
},get_endOfItems:function(){
return this._endOfItems;
},get_clientDataString:function(){
return this._clientDataString;
},set_clientDataString:function(_123){
this._clientDataString=_123;
},get_offsetX:function(){
return this._offsetX;
},set_offsetX:function(_124){
this._offsetX=_124;
},get_offsetY:function(){
return this._offsetY;
},set_offsetY:function(_125){
this._offsetY=_125;
},add_keyPressing:function(_126){
this.get_events().addHandler("keyPressing",_126);
},remove_keyPressing:function(_127){
this.get_events().removeHandler("keyPressing",_127);
},raise_keyPressing:function(_128){
this.raiseEvent("keyPressing",_128);
},add_textChange:function(_129){
this.get_events().addHandler("textChange",_129);
},remove_textChange:function(_12a){
this.get_events().removeHandler("textChange",_12a);
},raise_textChange:function(_12b,e){
var _12b=new Telerik.Web.UI.RadComboBoxCancelEventArgs(e);
this.raiseEvent("textChange",_12b);
return _12b.get_cancel();
},add_selectedIndexChanging:function(_12d){
this.get_events().addHandler("selectedIndexChanging",_12d);
},remove_selectedIndexChanging:function(_12e){
this.get_events().removeHandler("selectedIndexChanging",_12e);
},raise_selectedIndexChanging:function(item,e){
var _131=new Telerik.Web.UI.RadComboBoxItemCancelEventArgs(item,e);
this.raiseEvent("selectedIndexChanging",_131);
return _131.get_cancel();
},add_selectedIndexChanged:function(_132){
this.get_events().addHandler("selectedIndexChanged",_132);
},remove_selectedIndexChanged:function(_133){
this.get_events().removeHandler("selectedIndexChanged",_133);
},raise_selectedIndexChanged:function(item,e){
var _136=new Telerik.Web.UI.RadComboBoxItemEventArgs(item,e);
this.raiseEvent("selectedIndexChanged",_136);
},add_itemsRequesting:function(_137){
this.get_events().addHandler("itemsRequesting",_137);
},remove_itemsRequesting:function(_138){
this.get_events().removeHandler("itemsRequesting",_138);
},add_itemsRequested:function(_139){
this.get_events().addHandler("itemsRequested",_139);
},remove_itemsRequested:function(_13a){
this.get_events().removeHandler("itemsRequested",_13a);
},raise_itemsRequested:function(text,e){
var _13d=new Telerik.Web.UI.RadComboBoxRequestEventArgs(text,e);
this.raiseEvent("itemsRequested",_13d);
},add_dropDownOpening:function(_13e){
this.get_events().addHandler("dropDownOpening",_13e);
},remove_dropDownOpening:function(_13f){
this.get_events().removeHandler("dropDownOpening",_13f);
},raise_dropDownOpening:function(e){
var _141=new Telerik.Web.UI.RadComboBoxCancelEventArgs(e);
this.raiseEvent("dropDownOpening",_141);
return _141.get_cancel();
},add_dropDownClosing:function(_142){
this.get_events().addHandler("dropDownClosing",_142);
},remove_dropDownClosing:function(_143){
this.get_events().removeHandler("dropDownClosing",_143);
},add_dropDownOpened:function(_144){
this.get_events().addHandler("dropDownOpened",_144);
},remove_dropDownOpened:function(_145){
this.get_events().removeHandler("dropDownOpened",_145);
},raise_dropDownOpened:function(e){
var _147=new Telerik.Web.UI.RadComboBoxEventArgs(e);
this.raiseEvent("dropDownOpened",_147);
},add_dropDownClosed:function(_148){
this.get_events().addHandler("dropDownClosed",_148);
},remove_dropDownClosed:function(_149){
this.get_events().removeHandler("dropDownClosed",_149);
},raise_dropDownClosed:function(e){
var _14b=new Telerik.Web.UI.RadComboBoxEventArgs(e);
this.raiseEvent("dropDownClosed",_14b);
},add_itemsRequestFailed:function(_14c){
this.get_events().addHandler("itemsRequestFailed",_14c);
},remove_itemsRequestFailed:function(_14d){
this.get_events().removeHandler("itemsRequestFailed",_14d);
},raise_itemsRequestFailed:function(text,_14f,e){
var _151=new Telerik.Web.UI.RadComboBoxItemsRequestFailedEventArgs(text,_14f,e);
this.raiseEvent("itemsRequestFailed",_151);
return _151.get_cancel();
},raise_dropDownClosing:function(e){
var _153=new Telerik.Web.UI.RadComboBoxCancelEventArgs(e);
this.raiseEvent("dropDownClosing",_153);
return _153.get_cancel();
},add_onClientFocus:function(_154){
this.get_events().addHandler("onClientFocus",_154);
},remove_onClientFocus:function(_155){
this.get_events().removeHandler("onClientFocus",_155);
},raise_onClientFocus:function(e){
var _157=new Telerik.Web.UI.RadComboBoxEventArgs(e);
this.raiseEvent("onClientFocus",_157);
},add_onClientBlur:function(_158){
this.get_events().addHandler("onClientBlur",_158);
},remove_onClientBlur:function(_159){
this.get_events().removeHandler("onClientBlur",_159);
},raise_onClientBlur:function(e){
var _15b=new Telerik.Web.UI.RadComboBoxEventArgs(e);
this.raiseEvent("onClientBlur",_15b);
},add_onClientKeyPressing:function(_15c){
this.get_events().addHandler("keyPressing",_15c);
},remove_onClientKeyPressing:function(_15d){
this.get_events().removeHandler("keyPressing",_15d);
},raise_onClientKeyPressing:function(e){
var _15f=new Telerik.Web.UI.RadComboBoxEventArgs(e);
this.raiseEvent("keyPressing",_15f);
},add_load:function(_160){
this.get_events().addHandler("load",_160);
},remove_load:function(_161){
this.get_events().removeHandler("load",_161);
},_logInserted:function(item){
if(!item.get_parent()._childControlsCreated||!this._enableClientStatePersistence){
return;
}
this._log.logInsert(item);
},saveClientState:function(){
var _163=this._log._logEntries;
var _164={logEntries:_163,value:this._value,text:this._text,enabled:this._enabled};
return Sys.Serialization.JavaScriptSerializer.serialize(_164);
},requestItems:function(text,_166){
this._ensureChildControls();
if(this._disposed){
return;
}
text=text.replace(/'/g,"&squote");
text=encodeURIComponent(text);
this._ajaxRequest=true;
var _167={};
this.set_appendItems(_166);
_167.NumberOfItems=0;
if(this.get_appendItems()){
_167.NumberOfItems=this.get_items().get_count();
}
_167.Text=decodeURIComponent(text);
var _168=new Telerik.Web.UI.RadComboBoxRequestCancelEventArgs(text,_167);
this.raiseEvent("itemsRequesting",_168);
if(_168.get_cancel()){
this._ajaxRequest=false;
return;
}
if(this.get_highlightedItem()){
this.get_highlightedItem().unHighlight();
}
if(!this._loadingDiv){
this._loadingDiv=document.createElement("li");
this._loadingDiv.className="rcbLoading";
this._loadingDiv.id=this.get_id()+"_LoadingDiv";
this._loadingDiv.innerHTML=this.get_loadingMessage();
if(!this.get_childListElement()){
this._createChildListElement();
}
this.get_childListElement().insertBefore(this._loadingDiv,this.get_childListElement().firstChild);
}
this._callbacktext=text;
if(this.get_webServiceSettings().get_method()){
this._doLoadOnDemandFromWebService(text,_167);
}else{
this._doLoadOnDemand(text,_167);
}
},_doLoadOnDemand:function(text,_16a){
var _16b=0;
if(this.get_appendItems()){
_16b=this.get_items().get_count();
}
var _16c={Command:"LOD",Text:text,ClientState:this._clientState,Context:_16a,NumberOfItems:_16b};
var _16d=Function.createDelegate(this,this._onCallbackResponse);
var _16e=Function.createDelegate(this,this._onErrorReceived);
if(this.get_enableItemCaching()&&this.lodHashTable[text+"$"+_16b]!=null){
this._onCallbackResponse(this.lodHashTable[text+"$"+_16b]);
}else{
WebForm_DoCallback(this._uniqueId,Sys.Serialization.JavaScriptSerializer.serialize(_16c),_16d,text,_16e,true);
}
},_onCallbackResponse:function(_16f){
if(this._disposed){
return;
}
this.set_selectedItem(null);
this.set_highlightedItem(null);
var _170=this._children.get_count();
var text=this.get_text();
var _172=0;
var _173=_16f.split("_$$_")[4];
if(this._callbacktext!=_173){
this.requestItems(this._callbacktext,this.get_appendItems());
return;
}
if(this.get_appendItems()){
_172=this.get_items().get_count();
}
if(this.get_enableItemCaching()&&this.lodHashTable[_173+"$"+_172]==null){
this.lodHashTable[_173+"$"+_172]=_16f;
}
var _174=_16f.split("_$$_");
var _175;
if(_174[0]=="[]"){
_175=null;
}else{
_175=eval(_174[0]);
}
if(_174[3]=="True"){
this._endOfItems=true;
}else{
this._endOfItems=false;
}
if(this.get_appendItems()&&this._itemData&&_175){
Array.addRange(this._itemData,_175);
}else{
this._itemData=_175;
}
if(this._loadingDiv){
if(this._loadingDiv.parentNode){
this._loadingDiv.parentNode.removeChild(this._loadingDiv);
}
this._loadingDiv=null;
}
var _176=this.get_childListElement();
if(!_176){
_176=this._createChildListElement();
}
this._childControlsCreated=true;
var _177=$telerik.getFirstChildByTagName(_176,"div",0);
if(_177){
_177.parentNode.removeChild(_177);
}
if(this.get_appendItems()){
var _178=document.createElement("ul");
_178.innerHTML=_174[1];
var _179=$telerik.getChildrenByTagName(_178,"li");
var _17a=_179.length;
for(var i=0;i<_17a;i++){
_176.appendChild(_179[i]);
this._childControlsCreated=false;
var item=new Telerik.Web.UI.RadComboBoxItem();
this._children.add(item);
item._initialize(_175[i],_179[i]);
}
}else{
this._children.clear();
_176.innerHTML=_174[1];
this._childControlsCreated=false;
this._createChildControls();
}
this.set_showMoreMessage(_174[2]);
this._setUpDropDownAfterRequest(this.get_text(),_176,_170);
},_setUpScroll:function(_17d,_17e){
var _17f=22;
var _180=this.get_items().get_count();
if(_180>0){
_17f=this.get_items().getItem(0).get_element().offsetHeight;
}
if(_17d){
var _181=$telerik.getFirstChildByTagName(_17e,"div",0);
if(_181){
_181.parentNode.removeChild(_181);
}
}else{
var _181=document.createElement("div");
if(this._height==""&&this._maxHeight!=""){
_181.style.height=this._maxHeight;
}else{
_181.style.height=this.get_childListElementWrapper().offsetHeight+"px";
}
_17e.appendChild(_181);
}
},_onErrorReceived:function(_182,text){
if(this._requestTimeoutID>0){
window.clearTimeout(this._requestTimeoutID);
this._requestTimeoutID=0;
}
var _184=this._extractErrorMessage(_182);
if(this.raise_itemsRequestFailed(text,_184,null)==true){
return;
}
alert(_184);
},_initializeWebServiceLoader:function(){
this._webServiceLoader=new Telerik.Web.UI.WebServiceLoader(this.get_webServiceSettings());
this._webServiceLoader.add_loadingSuccess(Function.createDelegate(this,this._onWebServiceResponse));
this._webServiceLoader.add_loadingError(Function.createDelegate(this,this._onWebServiceError));
},_doLoadOnDemandFromWebService:function(text,_186){
if(!this._webServiceLoader){
this._initializeWebServiceLoader();
}
var _187={context:_186};
var _188=_186.NumberOfItems;
if(this.get_enableItemCaching()&&this.lodHashTable[text+"$"+_188]!=null){
this._addNewItems(text,this.lodHashTable[text+"$"+_188]);
}else{
this._webServiceLoader.loadData(_187,text);
}
},_onWebServiceResponse:function(_189,_18a){
var _18b=_18a.get_data();
var text=_18a.get_context();
var _18d=0;
if(this.get_appendItems()){
_18d=this.get_items().get_count();
}
if(this._callbacktext!=text){
this.requestItems(this._callbacktext,this.get_appendItems());
return;
}
if(this.get_enableItemCaching()){
this.lodHashTable[text+"$"+_18d]=_18b;
}
this._addNewItems(text,_18b);
},_addNewItems:function(text,_18f){
this.set_selectedItem(null);
this.set_highlightedItem(null);
this._childControlsCreated=true;
var _190=this.get_items().get_count();
if(this._loadingDiv){
if(this._loadingDiv.parentNode){
this._loadingDiv.parentNode.removeChild(this._loadingDiv);
}
this._loadingDiv=null;
}
if(!this.get_appendItems()){
this.clearItems();
}
var _191=this.get_childListElement();
if(!_191){
_191=this._createChildListElement();
}
if(this._virtualScroll){
this._setUpScroll(true,_191);
}
var _192=null;
if(Array.prototype.isPrototypeOf(_18f)){
_192=_18f;
}else{
_192=_18f.Items;
this._endOfItems=_18f.EndOfItems;
this._showMoreMessage=_18f.Message;
}
this._childControlsCreated=false;
var html=[];
for(var i=0,_195=_192.length;i<_195;i++){
var item=new Telerik.Web.UI.RadComboBoxItem();
var data=_192[i];
item._loadFromDictionary(data);
this._children.add(item);
item._render(html);
}
this._childControlsCreated=true;
if(this.get_appendItems()){
_191.innerHTML=_191.innerHTML+html.join("");
}else{
_191.innerHTML=html.join("");
}
var _198=$telerik.getChildrenByTagName(_191,"li");
for(var i=0,_195=this._children.get_count();i<_195;i++){
var item=this._children.getItem(i);
item.set_element(_198[i]);
}
this._setUpDropDownAfterRequest(text,_191,_190);
},_setUpDropDownAfterRequest:function(text,_19a,_19b){
if(this._virtualScroll){
this._setUpScroll(this._endOfItems,_19a);
}
if(this.get_appendItems()){
if(this.get_items().getItem(_19b+1)!=null){
this.get_items().getItem(_19b+1).scrollIntoView();
}
}
if(this._showMoreResultsBox&&this.get_moreResultsBoxMessageElement()){
this.get_moreResultsBoxMessageElement().innerHTML=this.get_showMoreMessage();
}
this.raise_itemsRequested(text,null);
if(this.get_filter()==Telerik.Web.UI.RadComboBoxFilter.None){
this.highlightMatches();
}else{
this.highlightAllMatches(this.get_text());
}
if(this.get_dropDownVisible()){
if(this._slide){
this._slide.updateSize();
}
this._positionDropDown();
}
this._ajaxRequest=false;
},_onWebServiceError:function(_19c,_19d){
var _19e=_19d.get_message();
var text=_19d.get_context();
this._onErrorReceived(_19e,text);
}};
Telerik.Web.UI.RadComboBox._preInitialize=function(_1a0){
var _1a1=$get(_1a0);
if($telerik.isIE){
_1a1.style.display="inline";
}
if($telerik.isSafari||$telerik.isOpera){
_1a1.style.display="inline-block";
}
if($telerik.isFirefox){
_1a1.style.display="-moz-inline-stack";
}
};
Telerik.Web.UI.RadComboBox.registerClass("Telerik.Web.UI.RadComboBox",Telerik.Web.UI.ControlItemContainer);
Type.registerNamespace("Telerik.Web.UI");
Telerik.Web.UI.RadComboBoxItem=function(){
Telerik.Web.UI.RadComboBoxItem.initializeBase(this);
};
Telerik.Web.UI.RadComboBoxItem.prototype={_shouldInitializeChild:function(_1a2){
return false;
},get_text:function(){
var text=Telerik.Web.UI.RadComboBoxItem.callBaseMethod(this,"get_text");
return this._removeEmTags(text);
},get_baseText:function(){
return Telerik.Web.UI.RadComboBoxItem.callBaseMethod(this,"get_text");
},_removeEmTags:function(text){
var _1a5=text.indexOf("<em>");
var _1a6=text.indexOf("</em>");
if(_1a5>=0&&_1a6>_1a5){
text=String.format("{0}{1}{2}",text.substr(0,_1a5),text.substr(_1a5+4,_1a6-_1a5-4),text.substr(_1a6+5));
}
return text;
},set_visible:function(_1a7){
var _1a8=this.get_visible()!=_1a7;
if(!_1a8){
return;
}
Telerik.Web.UI.RadComboBoxItem.callBaseMethod(this,"set_visible",[_1a7]);
if(_1a7){
this.get_element().style.display="";
}else{
this.get_element().style.display="none";
}
},_markText:function(text){
var _1aa=this.get_comboBox();
var _1ab=this.get_baseText();
var _1ac=this.get_text();
if(!_1aa.get_isTemplated()){
this.set_text(_1ac);
}
_1ab=_1ac;
var _1ad=_1ab.toLowerCase().indexOf(text.toLowerCase());
var _1ae=_1aa.get_filter()==Telerik.Web.UI.RadComboBoxFilter.Contains&&_1ad>=0;
var _1af=_1aa.get_filter()==Telerik.Web.UI.RadComboBoxFilter.StartsWith&&_1ad==0;
if(_1ae||_1af){
if(text!=""&&!_1aa.get_isTemplated()){
var _1ac=String.format("{0}<em>{1}</em>{2}",_1ab.substr(0,_1ad),_1ab.substring(_1ad,_1ad+text.length),_1ab.substr(_1ad+text.length));
this.set_text(_1ac);
}
this.set_visible(true);
}else{
this.set_visible(false);
}
},_render:function(html){
html[html.length]="<li class='";
if(this.get_enabled()){
if(this.get_isSeparator()){
html[html.length]="rcbItem rcbSeparator'>";
}else{
html[html.length]="rcbItem'>";
}
}else{
html[html.length]="rcbDisabled'>";
}
if(this.get_imageUrl()){
this._renderImage(html);
}
html[html.length]=this.get_text();
html[html.length]="</li>";
},_renderImage:function(html){
html[html.length]="<img alt='' src='"+this.get_imageUrl()+"' class='rcbImage'";
if(!this.get_enabled()){
html[html.length]=" disabled='disabled'";
}
html[html.length]="/>";
return html;
},_updateImageSrc:function(){
var _1b2=this.get_imageUrl();
if(!this.get_enabled()&&this.get_disabledImageUrl()){
_1b2=this.get_disabledImageUrl();
}
if(_1b2&&this.get_element()){
var _1b3=this.get_imageElement();
if(!_1b3){
_1b3=this._createImageElement();
}
_1b2=_1b2.replace(/&amp;/ig,"&");
if(_1b2!=_1b3.src){
_1b3.src=_1b2;
}
}
},_createImageElement:function(){
this._imageElement=document.createElement("img");
this._imageElement.className="rcbImage";
if(!this.get_enabled()){
this._imageElement.disabled="disabled";
}
var _1b4=this.get_element();
if(_1b4.firstChild){
_1b4.insertBefore(this._imageElement,_1b4.firstChild);
}else{
_1b4.appendChild(this._imageElement);
}
return this._imageElement;
},get_imageElement:function(){
if(!this._imageElement){
var _1b5=this.get_element();
this._imageElement=$telerik.getFirstChildByTagName(_1b5,"img",0);
}
return this._imageElement;
},get_disabledImageUrl:function(){
return this._properties.getValue("disabledImageUrl",null);
},set_disabledImageUrl:function(_1b6){
this._properties.setValue("disabledImageUrl",_1b6,true);
this._updateImageSrc();
},get_imageUrl:function(){
if(this._imageUrl=this._properties.getValue("imageUrl",null)){
return this._imageUrl;
}
if(!this._imageUrl){
var _1b7=this.get_imageElement();
if(_1b7){
this._imageUrl=_1b7.src;
}
}
return this._imageUrl;
},set_imageUrl:function(_1b8){
this._imageUrl=_1b8;
this._properties.setValue("imageUrl",_1b8,true);
this._updateImageSrc();
},get_value:function(){
return this._properties.getValue("value","");
},select:function(){
this._select(null);
},hide:function(){
this.set_visible(false);
},show:function(){
this.set_visible(true);
},_select:function(e){
if(!this.get_isEnabled()||this.get_isSeparator()){
return;
}
var _1ba=this.get_comboBox();
if(_1ba.raise_selectedIndexChanging(this,e)==true){
return;
}
var text=_1ba.get_text();
var _1bc=_1ba._getLastSeparatorIndex(text);
var _1bd=text.substring(0,_1bc+1)+this.get_text();
_1ba.set_text(_1bd);
_1ba.set_originalText(_1bd);
_1ba.set_value(this.get_value());
_1ba.set_selectedItem(this);
_1ba.set_selectedIndex(this.get_index());
this.highlight();
_1ba.raise_selectedIndexChanged(this,e);
var _1be={Command:"Select",Index:this.get_index()};
_1ba.postback(_1be);
},_createChildControls:function(){
},unHighlight:function(){
var _1bf=this.get_comboBox();
if(!_1bf.get_isTemplated()||_1bf.get_highlightTemplatedItems()){
this._replaceCssClass(this.get_element(),"rcbHovered","rcbItem");
}
_1bf.set_highlightedItem(null);
},highlight:function(){
if(!this.get_isEnabled()||this.get_isSeparator()){
return;
}
var _1c0=this.get_comboBox();
if(!_1c0.get_isTemplated()||_1c0.get_highlightTemplatedItems()){
var _1c1=_1c0.get_highlightedItem();
if(_1c1){
_1c1.unHighlight();
}
var _1c2=this.get_element();
if(_1c2){
this._replaceCssClass(_1c2,"rcbItem","rcbHovered");
}
}
_1c0.set_highlightedItem(this);
},scrollOnTop:function(){
var _1c3=this.get_element().offsetTop;
var _1c4=this.get_comboBox();
var _1c5=_1c4._getHeaderElement();
if(_1c5){
_1c3=_1c3-_1c5.offsetHeight;
}
_1c4.get_childListElementWrapper().scrollTop=_1c3;
},scrollIntoView:function(){
var _1c6=this.get_element().offsetTop;
var _1c7=this.get_element().offsetHeight;
var _1c8=this.get_comboBox().get_childListElementWrapper();
var _1c9=_1c8.scrollTop;
var _1ca=_1c8.offsetHeight;
if(_1c6+_1c7>_1c9+_1ca){
_1c8.scrollTop=_1c6+_1c7-_1ca;
if(_1c8.clientWidth<_1c8.scrollWidth){
var _1cb=Telerik.Web.UI.RadComboBox._getScrollBarWidth();
_1c8.scrollTop+=_1cb;
}
}else{
if(_1c6+_1c7<=_1c9){
_1c8.scrollTop=_1c6;
}
}
},nextItem:function(){
return this.get_comboBox().get_items().getItem(this.get_index()+1);
},_replaceCssClass:function(_1cc,_1cd,_1ce){
_1cc.className=_1cc.className.replace(_1cd,_1ce);
},_createChildListElement:function(){
var _1cf=document.createElement("ul");
this.get_combobox().get_dropDownElement().appendChild(_1cf);
},set_selected:function(_1d0){
this._properties.setValue("selected",_1d0);
},get_selected:function(){
return this._properties.getValue("selected",false);
},get_highlighted:function(){
var _1d1=this.get_comboBox();
if(!_1d1){
return false;
}
return _1d1.get_highlightedItem()==this;
},disable:function(){
this.set_enabled(false);
this.get_element().className="rcbDisabled";
},enable:function(){
this.set_enabled(true);
this.get_element().className="rcbItem";
},set_enabled:function(_1d2){
this._properties.setValue("enabled",_1d2,true);
this._updateImageSrc();
},get_textElement:function(){
return this.get_element();
},get_comboBox:function(){
return this._parent;
},_getHierarchicalIndex:function(){
return this.get_index();
},get_isSeparator:function(){
return this._properties.getValue("isSeparator",false);
},set_isSeparator:function(_1d3){
this._properties.setValue("isSeparator",_1d3,true);
if(this.get_element()){
Sys.UI.DomElement.toggleCssClass(this.get_element(),"rcbSeparator");
}
}};
Telerik.Web.UI.RadComboBoxItem.registerClass("Telerik.Web.UI.RadComboBoxItem",Telerik.Web.UI.ControlItem);
Type.registerNamespace("Telerik.Web.UI");
Telerik.Web.UI.RadComboBoxItemCollection=function(_1d4){
Telerik.Web.UI.RadComboBoxItemCollection.initializeBase(this,[_1d4]);
};
Telerik.Web.UI.RadComboBoxItemCollection.registerClass("Telerik.Web.UI.RadComboBoxItemCollection",Telerik.Web.UI.ControlItemCollection);

