 ASPxClientListEdit.prototype.RaiseSelectedIndexChanged=function(){var processOnServer=this.autoPostBack;if(!this.SelectedIndexChanged.IsEmpty()){var args=new ASPxClientProcessingModeEventArgs(processOnServer);this.SelectedIndexChanged.FireEvent(this,args);processOnServer=args.processOnServer;}return processOnServer;}
ASPxClientListEdit.prototype.GetSelectedItem=function(){var index=this.GetSelectedIndexInternal();return this.GetItem(index);}
ASPxClientListEdit.prototype.GetSelectedIndex=function(){return this.GetSelectedIndexInternal();}
ASPxClientListEdit.prototype.SetSelectedItem=function(item){var index=(item!=null)?item.index:-1;this.SelectIndex(index);}
ASPxClientListEdit.prototype.SetSelectedIndex=function(index){this.SelectIndex(index);}
ASPxClientListEditItem=_aspxCreateClass(null,{constructor:function(listEditBase,index,text,value,imageUrl){this.listEditBase=listEditBase;this.index=index;this.imageUrl=imageUrl;this.text=text;this.value=value;}});ASPxClientListBox.prototype.InitOnContainerMadeVisible=function(){this.InitializeDisplayed();}
ASPxClientListBox.prototype.SetSelectedIndex=function(index){if(index!=this.GetSelectedIndexInternal())this.SelectIndex(index,false);}
ASPxClientListBox.prototype.AddItem=function(text,value,imageUrl){var index=this.GetItemCount();this.InsertItemInternal(index,text,value,imageUrl);return index;}
ASPxClientListBox.prototype.InsertItem=function(index,text,value,imageUrl){this.InsertItemInternal(index,text,value,imageUrl);}
ASPxClientListBox.prototype.BeginUpdate=function(){this.APILockCount++;}
ASPxClientListBox.prototype.EndUpdate=function(){this.APILockCount--;this.Synchronize();this.CorrectSizeByTimer();}
ASPxClientListBox.prototype.ClearItems=function(){this.BeginUpdate();this.RemoveItemsClasses();this.ClearItemsInternal();this.SetSelectedIndexInternal(-1);this.SetValue(null);this.EndUpdate();}
ASPxClientListBox.prototype.RemoveItem=function(index){if(0<=index&&index<this.GetItemCount()){this.RemoveItemClass(this.GetItem(index));var row=this.GetItemRow(index);if(_aspxIsExistsElement(row)){if(index==this.GetSelectedIndexInternal())this.SetSelectedIndexInternal(-1);row.parentNode.removeChild(row);}}}
ASPxClientListBox.prototype.GetItem=function(index){var item=null;var listTable=this.GetListTable();if(_aspxIsExists(listTable)){if(0<=index&&index<listTable.rows.length){var row=listTable.rows[index];var isImageExists=row.cells.length==2;if(isImageExists)var image=_aspxGetChildByTagName(row.cells[0],"IMG",0);var textCell=row.cells[isImageExists?1:0];var textNode=_aspxGetChildTextNode(textCell,0);var text=__aspxMozilla?textCell.textContent:textCell.innerText;if(text=="&nbsp;"||text.charCodeAt(0)==160)text=" ";item=new ASPxClientListEditItem(this,index,text,this.itemsValue[index],image==null?"":image.src);}}return item;}
ASPxClientListBox.prototype.PerformCallback=function(arg){this.ClearItems();this.SetCustomCallbackArg(this.FormatCallbackArg("LECC",arg));this.SendCallback();};ASPxClientListBox.prototype.GetCustomCallbackArg=function(){return this.GetSyncroHiddenInput("CustomCallback").value;}
ASPxClientListBox.prototype.SetCustomCallbackArg=function(arg){this.GetSyncroHiddenInput("CustomCallback").value=arg;}
ASPxClientListBox.prototype.GetTableRowParent=function(table){if(table.tBodies.length>0)return table.tBodies[0];return table;}
ASPxClientListBox.prototype.InsertItemInternal=function(index,text,value,imageUrl){if(!_aspxIsExists(imageUrl))imageUrl="";if(!_aspxIsExists(value))value=text;if(typeof(text)=="string"&&(text==""||text==" "))text="&nbsp;";var newItemRow=this.CreateNewItem();var listTable=this.GetListTable();var tbody=this.GetTableRowParent(listTable);var isAdd=listTable.rows.length<=index;if(isAdd)tbody.appendChild(newItemRow);else tbody.insertBefore(newItemRow,this.GetItemRow(index));var newIndex=this.FindFreeIndex();var newId=this.CreateItemId(newIndex);var newClientId=this.CreateItemClientId(newIndex);this.InitializeItemAttributes(newItemRow,newClientId,true);var sampleCellElement=this.GetSampleItemTextCell();aspxAddHoverItems(this.name,this.CreateStyleClasses(sampleCellElement,newId,__aspxLBIPostfixes,true));aspxAddSelectedItems(this.name,this.CreateStyleClasses(sampleCellElement,newId,__aspxLBIPostfixes,false));this.AddItemClass(index,text,value,imageUrl);this.PrepareItem(newItemRow,text,imageUrl);if(index==this.GetSelectedIndexInternal())this.SetSelectedIndex(index+1);}
ASPxClientListBox.prototype.PrepareItem=function(newItemRow,text,imageUrl){if(newItemRow.cells.length==2){var imageCell=newItemRow.cells[0];var image=_aspxGetChildByTagName(imageCell,'img',0);if(!_aspxIsExists(image)){image=document.createElement('img');imageCell.innerHTML="";imageCell.appendChild(image);}
this.SetImageSrc(image,imageUrl);newItemRow.cells[1].innerHTML=text;}else newItemRow.cells[0].innerHTML=text;}
ASPxClientListBox.prototype.SetImageSrc=function(image,src){var isFilterNeed=this.IsAlphaFilterNeed(src);image.src=isFilterNeed?__dxSpaceImageUrl:src;if(__aspxIE&&!__aspxIE7)image.style.filter=isFilterNeed?this.CreateImageFilterStyle(src):"";}
ASPxClientListBox.prototype.CreateImageFilterStyle=function(src){return "progid:DXImageTransform.Microsoft.AlphaImageLoader(src="+src+", sizingMethod=scale)"}
ASPxClientListBox.prototype.IsAlphaFilterNeed=function(src){return(__aspxIE&&!__aspxIE7&&src.slice(-3).toLowerCase()==="png");}
ASPxClientListBox.prototype.ClearItemsInternal=function(){var tBody=this.GetTableRowParent(this.GetListTable());if(__aspxIE)tBody.innerText="";else tBody.innerHTML="";}
ASPxClientListBox.prototype.AddItemClass=function(index,text,value,imageUrl){_aspxArrayInsert(this.itemsValue,value,index);if(this.isSyncEnabled){var item=new ASPxClientListEditItem(this,index,text,value,imageUrl);_aspxArrayPush(this.insertedItems,item);this.Synchronize();}}
ASPxClientListBox.prototype.RemoveItemClass=function(item){_aspxArrayRemoveAt(this.itemsValue,item.index);if(this.isSyncEnabled){var item=new ASPxClientListEditItem(this,item.index,item.text,item.value,item.imageUrl);var index=this.FindItemInArray(this.insertedItems,item);if(index==-1)_aspxArrayPush(this.deletedItems,item);else _aspxArrayRemoveAt(this.insertedItems,index);this.Synchronize();}}
ASPxClientListBox.prototype.RemoveItemsClasses=function(){for(var i=this.GetItemCount()-1;i>=0;i--)this.RemoveItemClass(this.GetItem(i));}
ASPxClientListBox.prototype.FindItemInArray=function(array,item){for(var i=array.length-1;i>=0;i--){var currentItem=array[i];if(currentItem.text==item.text&&currentItem.value==item.value&&currentItem.imageUrl==item.imageUrl)break;}return i;}
ASPxClientListBox.prototype.CreateItemId=function(index){return __aspxLBIIdSuffix+index;}
ASPxClientListBox.prototype.CreateItemClientId=function(index){return this.name+"_"+__aspxLBIIdSuffix+index;}
ASPxClientListBox.prototype.CreateNewItem=function(){var newItemRow=this.GetSampleItem();if(_aspxIsExistsElement(newItemRow))newItemRow=newItemRow.cloneNode(true);return newItemRow;}
ASPxClientListBox.prototype.CreateStyleClasses=function(sampleElement,id,postfixes,isHover){var styleController=aspxGetStateController();var item=isHover?styleController.GetHoverElement(sampleElement):styleController.GetSelectedElement(sampleElement);var kind=isHover?__aspxHoverItemKind:__aspxSelectedItemKind;var classes=[];if(_aspxIsExists(item)&&_aspxIsExists(item[kind])){classes[0]=[];classes[0][0]=item[kind].className;classes[0][1]=item[kind].cssText;classes[0][2]=[];classes[0][2][0]=id;classes[0][3]=postfixes;}return classes;}
ASPxClientListBox.prototype.CorrectSizeByTimer=function(){if(this.IsDisplayed())_aspxSetTimeout("aspxLBCorrectSizesByTimer(\""+this.name+"\");",0);}
ASPxClientListBox.prototype.FindFreeIndex=function(){return this.freeUniqIndex++;}
ASPxClientListBox.prototype.GetCorrectString=function(string){return _aspxIsExists(string)?string:"";}
ASPxClientListBox.prototype.GetSampleItemID=function(){return this.name+"_"+__aspxLBSIIdSuffix;}
ASPxClientListBox.prototype.GetSampleItem=function(){if(this.SampleItem==null)this.SampleItem=_aspxGetElementById(this.GetSampleItemID());return this.SampleItem;}
ASPxClientListBox.prototype.GetSampleItemTextCell=function(){if(!_aspxIsExistsElement(this.sampleItemTextCell))this.sampleItemTextCell=_aspxGetElementById(this.GetSampleItemID()+__aspxLBIPostfixes[1]);return this.sampleItemTextCell;}
ASPxClientListBox.prototype.GetSyncroHiddenInput=function(syncroType){return _aspxGetElementById(this.name+syncroType);}
ASPxClientListBox.prototype.Synchronize=function(){if(this.APILockCount==0&&this.isSyncEnabled){this.SynchronizeItems(this.deletedItems,"DeletedItems");this.SynchronizeItems(this.insertedItems,"InsertedItems");}
this.CorrectSizeByTimer();}
ASPxClientListBox.prototype.SynchronizeItems=function(items,syncroType){var inputElement=this.GetSyncroHiddenInput(syncroType);if(_aspxIsExistsElement(inputElement)){var itemsState="";for(var i=0;i<items.length;i++){itemsState+=this.GetSynchronizedItemState(items[i]);if(i<items.length-1)itemsState+=__aspxItemsSeparator;}
inputElement.value=itemsState;}}
ASPxClientListBox.prototype.GetSynchronizedItemState=function(item){if(_aspxIsExists(item)){var itemState=item.value;itemState+=__aspxItemAttrsSeparator+this.GetCorrectString(item.index);itemState+=__aspxItemAttrsSeparator+this.GetCorrectString(item.text);itemState+=__aspxItemAttrsSeparator+this.GetCorrectString(item.imageUrl);return itemState;}return "";}
function aspxLBCorrectSizesByTimer(name){var lb=aspxGetControlCollection().Get(name);if(lb!=null)lb.CorrectSizes();}
ASPxClientRadioButtonList.prototype.CreateItems=function(itemsProperties){for(var i=0;i<itemsProperties.length;i++)this.CreateItem(i,itemsProperties[i][0],itemsProperties[i][1],itemsProperties[i][2]);}
ASPxClientRadioButtonList.prototype.GetItem=function(index){return(0<=index&&index<this.items.length)?this.items[index]:null;}
ASPxClientRadioButtonList.prototype.CreateItem=function(index,text,value,imageUrl){var item=new ASPxClientListEditItem(this,index,text,value,imageUrl);_aspxArrayPush(this.items,item);}