﻿var __aspxInvalidDimension=-10000;var __aspxInvalidPosition=-10000;var __aspxAbsoluteLeftPosition=-10000;var __aspxAbsoluteRightPosition=10000;var __aspxMenuZIndex=21998;var __aspxPopupControlZIndex=11998;var __aspxCheckSizeCorrectedFlag=true;var __aspxCallbackSeparator=":";var __aspxItemIndexSeparator="i";var __aspxCallbackResultPrefix="/*^^^DX^^^*/";var __aspxItemClassName="dxi";var __aspxAccessibilityEmptyUrl="javascript:;";var __aspxHTMLLoaded=false;var __aspxEmptyAttributeValue=new Object();var __aspxEmptyCachedValue=new Object();var __aspxCachedRules=new Object();var __aspxDateFormatInfo={twoDigitYearMax:2029,ts:":",ds:"/",am:"AM",pm:"PM"};function _aspxGetInvariantDateString(date){if(!date)
return"01/01/0001";var day=date.getDate();var month=date.getMonth()+1;var year=date.getFullYear();var result="";if(month<10)
result+="0";result+=month.toString()+"/";if(day<10)
result+="0";result+=day.toString()+"/"+year.toString();return result;}
function _aspxGetInvariantDateTimeString(date){var dateTimeString=_aspxGetInvariantDateString(date);var time={h:date.getHours(),m:date.getMinutes(),s:date.getSeconds()};for(var key in time){var str=time[key].toString();if(str.length<2)
str="0"+str;time[key]=str;}
dateTimeString+=" "+time.h+":"+time.m+":"+time.s;var msec=date.getMilliseconds();if(msec>0)
dateTimeString+="."+msec.toString();return dateTimeString;}
var ASPxKey={F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,Ctrl:17,Shift:16,Alt:18,Enter:13,Home:36,End:35,Left:37,Right:39,Up:38,Down:40,PageUp:33,PageDown:34,Esc:27,Space:32,Tab:9,Backspace:8,Delete:46,Insert:45,ContextMenu:93,Windows:91};var __aspxServerForm=null;function _aspxGetServerForm(){if(typeof(window.__aspxServerFormID)=="undefined")
return null;if(!_aspxIsExistsElement(__aspxServerForm))
__aspxServerForm=_aspxGetElementById(window.__aspxServerFormID);return __aspxServerForm;}
function _aspxGetActiveElement(){try{return document.activeElement;}catch(e){}
return null;}
var __aspxAgent=navigator.userAgent.toLowerCase();var __aspxOpera=(__aspxAgent.indexOf("opera")>-1);var __aspxOpera9=(__aspxAgent.indexOf("opera/9")>-1||__aspxAgent.indexOf("opera 9")>-1);var __aspxSafariFamily=__aspxAgent.indexOf("safari")>-1;var __aspxChrome=__aspxSafariFamily&&__aspxAgent.indexOf("chrome/")>-1;var __aspxSafari=__aspxSafariFamily&&!__aspxChrome;var __aspxSafari3=__aspxSafari&&__aspxAgent.indexOf("version/3")>-1;var __aspxSafariMacOS=__aspxSafari&&__aspxAgent.indexOf("macintosh")>-1;var __aspxIE=(__aspxAgent.indexOf("msie")>-1&&!__aspxOpera);var __aspxIE55=(__aspxAgent.indexOf("5.5")>-1&&__aspxIE);var __aspxIE7=(__aspxAgent.indexOf("7.")>-1&&__aspxIE);var __aspxNotIEOperaSafari=!__aspxSafariFamily&&!__aspxIE&&!__aspxOpera;var __aspxFirefox=(__aspxAgent.indexOf("firefox")>-1)&&__aspxNotIEOperaSafari;var __aspxFirefox3=(__aspxAgent.indexOf("firefox/3.")>-1)&&__aspxNotIEOperaSafari;var __aspxMozilla=(__aspxAgent.indexOf("mozilla")>-1)&&__aspxNotIEOperaSafari;var __aspxNetscape=(__aspxAgent.indexOf("netscape")>-1)&&__aspxNotIEOperaSafari;var __aspxNS=__aspxFirefox||__aspxMozilla||__aspxNetscape;function _aspxArrayPush(array,element){if(_aspxIsExists(array.push))
array.push(element);else
array[array.length]=element;}
function _aspxArrayInsert(array,element,position){if(0<=position&&position<array.length){for(var i=array.length;i>position;i--)
array[i]=array[i-1];array[position]=element;}
else
_aspxArrayPush(array,element);}
function _aspxArrayRemove(array,element){var index=_aspxArrayIndexOf(array,element);if(index>-1)_aspxArrayRemoveAt(array,index);}
function _aspxArrayRemoveAt(array,index){if(index>=0&&index<array.length){for(var i=index;i<array.length-1;i++)
array[i]=array[i+1];array.pop();}}
function _aspxArrayClear(array){while(array.length>0)
array.pop();}
function _aspxArrayIndexOf(array,element){for(var i=0;i<array.length;i++){if(array[i]==element)
return i;}
return-1;}
function _aspxCreateHashTableFromArray(array){var hash=[];for(var i=0;i<array.length;i++)
hash[array[i]]=1;return hash;}
var __aspxDefaultBinarySearchComparer=function(arrayElement,value){if(arrayElement==value)
return 0;else
return arrayElement<value?-1:1;};function _aspxArrayBinarySearch(array,value,binarySearchComparer,startIndex,length){if(!_aspxIsExists(binarySearchComparer))
binarySearchComparer=__aspxDefaultBinarySearchComparer;if(!_aspxIsExists(startIndex))
startIndex=0;if(!_aspxIsExists(length))
length=array.length-startIndex;var endIndex=(startIndex+length)-1;while(startIndex<=endIndex){var middle=(startIndex+((endIndex-startIndex)>>1));var compareResult=binarySearchComparer(array[middle],value);if(compareResult==0)
return middle;if(compareResult<0)
startIndex=middle+1;else
endIndex=middle-1;}
return-(startIndex+1);}
function _aspxApplyReplacement(text,replecementTable){for(var i=0;i<replecementTable.length;i++){var replacement=replecementTable[i];text=text.replace(replacement[0],replacement[1]);}
return text;}
function _aspxEncodeHtml(html){return _aspxApplyReplacement(html,[[/&quot;/g,'&quotx;'],[/"/g,'&quot;'],[/&amp;/g,'&ampx;'],[/&/g,'&amp;'],[/&lt;/g,'&ltx;'],[/</g,'&lt;'],[/&gt;/g,'&gtx;'],[/>/g,'&gt;']]);}
function _aspxDecodeHtml(html){return _aspxApplyReplacement(html,[[/&gt;/g,'>'],[/&gtx;/g,'&gt;'],[/&lt;/g,'<'],[/&ltx;/g,'&lt;'],[/&amp;/g,'&'],[/&ampx;/g,'&amp;'],[/&quot;/g,'"'],[/&quotx;/g,'&quot;']]);}
function _aspxParseShortcutString(shortcutString){var isCtrlKey=false;var isShiftKey=false;var isAltKey=false;var keyCode=null;var shcKeys=shortcutString.toString().split("+");if(shcKeys.length>0){for(var i=0;i<shcKeys.length;i++){var key=_aspxTrim(shcKeys[i].toUpperCase());switch(key){case"CTRL":isCtrlKey=true;break;case"SHIFT":isShiftKey=true;break;case"ALT":isAltKey=true;break;case"F1":keyCode=ASPxKey.F1;break;case"F2":keyCode=ASPxKey.F2;break;case"F3":keyCode=ASPxKey.F3;break;case"F4":keyCode=ASPxKey.F4;break;case"F5":keyCode=ASPxKey.F5;break;case"F6":keyCode=ASPxKey.F6;break;case"F7":keyCode=ASPxKey.F7;break;case"F8":keyCode=ASPxKey.F8;break;case"F9":keyCode=ASPxKey.F9;break;case"F10":keyCode=ASPxKey.F10;break;case"F11":keyCode=ASPxKey.F11;break;case"F12":keyCode=ASPxKey.F12;break;case"ENTER":keyCode=ASPxKey.Enter;break;case"HOME":keyCode=ASPxKey.Home;break;case"END":keyCode=ASPxKey.End;break;case"LEFT":keyCode=ASPxKey.Left;break;case"RIGHT":keyCode=ASPxKey.Right;break;case"UP":keyCode=ASPxKey.Up;break;case"DOWN":keyCode=ASPxKey.Down;break;case"PAGEUP":keyCode=ASPxKey.PageUp;break;case"PAGEDOWN":keyCode=ASPxKey.PageDown;break;case"SPACE":keyCode=ASPxKey.Space;break;case"TAB":keyCode=ASPxKey.Tab;break;case"BACK":keyCode=ASPxKey.Backspace;break;case"CONTEXT":keyCode=ASPxKey.ContextMenu;break;case"ESCAPE":case"ESC":keyCode=ASPxKey.Esc;break;case"DELETE":case"DEL":keyCode=ASPxKey.Delete;break;case"INSERT":case"INS":keyCode=ASPxKey.Insert;break;case"PLUS":keyCode="+".charCodeAt(0);break;default:keyCode=key.charCodeAt(0);break;}}}else
alert("Invalid shortcut");return _aspxGetShortcutCode(keyCode,isCtrlKey,isShiftKey,isAltKey);}
function _aspxGetShortcutCode(keyCode,isCtrlKey,isShiftKey,isAltKey){var value=keyCode&0xFFFF;var flags=0;flags|=(isCtrlKey?1<<0:0);flags|=(isShiftKey?1<<2:0);flags|=(isAltKey?1<<4:0);value|=(flags<<16);return value;}
var ASPxImageUtils={IsAlphaFilterNeed:function(src){return(__aspxIE&&!__aspxIE7&&this.IsPng(src));},IsPng:function(src){return src.slice(-3).toLowerCase()=="png";},GetImageFilterStyle:function(src){return"progid:DXImageTransform.Microsoft.AlphaImageLoader(src="+src+", sizingMethod=scale)";},GetImageSrc:function(image){if(_aspxIsAlphaFilterUsed(image)){var filter=image.style.filter;var regSrc=new RegExp("src=","g");var regPng=new RegExp(".png","g");var beginIndex=regSrc.exec(filter).lastIndex;var endIndex=regPng.exec(filter).lastIndex;return filter.substring(beginIndex,endIndex);}
return image.src;},SetImageSrc:function(image,src){var isAlphaFilterNeed=this.IsAlphaFilterNeed(src);if(isAlphaFilterNeed){image.src=__dxSpaceImageUrl;image.style.filter=this.GetImageFilterStyle(src);}else{image.src=src;image.style.filter="";}},SetSize:function(image,width,height){image.style.width=width+"px";image.style.height=height+"px";},GetSize:function(image,isWidth){return(isWidth?image.offsetWidth:image.offsetHeight);}};ASPxStringBuilder=_aspxCreateClass(null,{constructor:function(str){this.Initialize();if(str!=null)
this.Append(str);},Append:function(str){this.value=null;this.length+=(this.parts[this.partsCount++]=String(str)).length;return this;},Clear:function(){this.Initialize();},Initialize:function(){this.parts=[];this.partsCount=0;this.length=0;this.value=null;},ToString:function(){if(this.value!=null)
return this.value;var aggregate=this.parts.join('');this.partsCount=(this.parts=[aggregate]).length;this.length=aggregate.length;return(this.value=aggregate);}});function _aspxSetTimeout(callString,timeout){return window.setTimeout(callString,timeout);}
function _aspxClearTimer(timerID){if(timerID>-1)
window.clearTimeout(timerID);return-1;}
function _aspxSetInterval(callString,interval){return window.setInterval(callString,interval);}
function _aspxClearInterval(timerID){if(timerID>-1)
window.clearInterval(timerID);return-1;}
function _aspxSetInnerHtml(element,html){element.innerHTML="<em>&nbsp;</em>"+html;element.removeChild(element.firstChild);}
function _aspxGetInnerText(container){if(__aspxMozilla)
return container.textContent;else if(__aspxSafariFamily){var filter=_aspxGetHtml2PlainTextFilter();filter.innerHTML=container.innerHTML;_aspxSetElementDisplay(filter,true);var innerText=filter.innerText;_aspxSetElementDisplay(filter,false);return innerText;}else
return container.innerText;}
var __aspxHtml2PlainTextFilter=null;function _aspxGetHtml2PlainTextFilter(){if(__aspxHtml2PlainTextFilter==null){__aspxHtml2PlainTextFilter=document.createElement("DIV");__aspxHtml2PlainTextFilter.style.width="0";__aspxHtml2PlainTextFilter.style.height="0";_aspxSetElementDisplay(__aspxHtml2PlainTextFilter,false);document.body.appendChild(__aspxHtml2PlainTextFilter);}
return __aspxHtml2PlainTextFilter;}
function _aspxCreateHiddenField(name,id){var input=document.createElement("INPUT");input.setAttribute("type","hidden");if(_aspxIsExists(name))
input.setAttribute("name",name);if(_aspxIsExists(id))
input.setAttribute("id",id);return input;}
function _aspxCloneObject(srcObject){if(typeof(srcObject)!='object'||srcObject==null)
return srcObject;var newObject=new Object();for(var i in srcObject)
newObject[i]=srcObject[i];return newObject;}
function _aspxIsExistsType(type){return type!="undefined";}
function _aspxIsExists(obj){return(typeof(obj)!="undefined")&&(obj!=null);}
function _aspxIsFunction(obj){return typeof(obj)=="function";}
function _aspxGetDefinedValue(value,defaultValue){return(typeof(value)!="undefined")?value:defaultValue;}
function _aspxGetKeyCode(srcEvt){return __aspxNS?srcEvt.which:srcEvt.keyCode;}
function _aspxSetInputSelection(input,startPos,endPos){startPos=_aspxGetDefinedValue(startPos,0);endPos=_aspxGetDefinedValue(endPos,input.value.length);if(__aspxIE){var range=input.createTextRange();range.collapse(true);range.moveStart("character",startPos);range.moveEnd("character",endPos-startPos);range.select();}else
input.setSelectionRange(startPos,endPos);}
function _aspxGetSelectionInfo(input){var start,end;if(__aspxIE){var range=document.selection.createRange();var rangeCopy=range.duplicate();range.move('character',-input.value.length);range.setEndPoint('EndToStart',rangeCopy);start=range.text.length;end=start+rangeCopy.text.length;}else{start=input.selectionStart;end=input.selectionEnd;}
return{startPos:start,endPos:end};}
function _aspxHasInputSelection(input){var selectionInfo=_aspxGetSelectionInfo(input);return selectionInfo.startPos==selectionInfo.endPos;}
function _aspxPreventElementDragAndSelect(element,isSkipMouseMove){if(__aspxIE){_aspxAttachEventToElement(element,"selectstart",new function(){return false;});if(!isSkipMouseMove)
_aspxAttachEventToElement(element,"mousemove",_aspxClearSelectionOnMouseMove);_aspxAttachEventToElement(element,"dragstart",_aspxPreventDragStart);}}
function _aspxSetElementAsUnselectable(element,isWithChild){if(_aspxIsExists(element)&&(element.nodeType==1)){element.unselectable="on";if(__aspxNS)
element.onmousedown=new function(){return false;};if(isWithChild===true){for(var j=0;j<element.childNodes.length;j++)
_aspxSetElementAsUnselectable(element.childNodes[j]);}}}
function _aspxClearSelection(){try{if(_aspxIsExists(window.getSelection)){if(__aspxSafariFamily)
window.getSelection().collapse();else
window.getSelection().removeAllRanges();}
else if(_aspxIsExists(document.selection)){if(_aspxIsExists(document.selection.empty))
document.selection.empty();else if(_aspxIsExists(document.selection.clear))
document.selection.clear();}}catch(e){}}
function _aspxClearSelectionOnMouseMove(evt){if(!__aspxIE||(evt.button!=0))
_aspxClearSelection();}
function _aspxPreventDragStart(evt){evt=_aspxGetEvent(evt);var element=_aspxGetEventSource(evt);element.releaseCapture();return false;}
function _aspxGetElementById(id){if(_aspxIsExists(document.getElementById))
return document.getElementById(id);else
return document.all[id];}
function _aspxGetIsParent(parentElement,element){while(element!=null){if(element.tagName=="BODY")
return false;if(element==parentElement)
return true;element=element.parentNode;}
return false;}
function _aspxGetParentById(element,id){element=element.parentNode;while(element!=null){if(element.id==id)
return element;element=element.parentNode;}
return null;}
function _aspxGetParentByTagName(element,tagName){tagName=tagName.toUpperCase();while(element!=null){if(element.tagName=="BODY")
return null;if(element.tagName==tagName)
return element;element=element.parentNode;}
return null;}
function _aspxGetParentByClassName(element,className){while(element!=null){if(element.tagName=="BODY")
return null;if(element.className.indexOf(className)!=-1)
return element;element=element.parentNode;}
return null;}
function _aspxGetParentByTagNameAndAttributeValue(element,tagName,attrName,attrValue){tagName=tagName.toUpperCase();while(element!=null){if(element.tagName=="BODY")
return null;if(element.tagName==tagName&&_aspxIsExists(element[attrName])&&element[attrName]==attrValue)
return element;element=element.parentNode;}
return null;}
function _aspxGetChildById(element,id){if(!__aspxIE)
return _aspxGetElementById(id);else{var element=element.all[id];if(!_aspxIsExists(element))
return null;else if(!_aspxIsExists(element.length))
return element;else
return _aspxGetElementById(id);}}
function _aspxGetElementsByTagName(element,tagName){tagName=tagName.toUpperCase();if(element!=null){if(_aspxIsExists(element.all)&&!__aspxFirefox3)
return __aspxNetscape?element.all.tags[tagName]:element.all.tags(tagName);else
return element.getElementsByTagName(tagName);}
return null;}
function _aspxGetChildByTagName(element,tagName,index){if(element!=null){var collection=_aspxGetElementsByTagName(element,tagName);if(collection!=null){if(index<collection.length)
return collection[index];}}
return null;}
function _aspxGetChildTextNode(element,index){if(element!=null){var collection=new Array();_aspxGetChildTextNodeCollection(element,collection);if(index<collection.length)
return collection[index];}
return null;}
function _aspxGetChildTextNodeCollection(element,collection){for(var i=0;i<element.childNodes.length;i++){var childNode=element.childNodes[i];if(_aspxIsExists(childNode.nodeValue))
_aspxArrayPush(collection,childNode);_aspxGetChildTextNodeCollection(childNode,collection);}}
function _aspxGetChildsByClassName(element,className){var collection=_aspxIsExists(element.all)?element.all:element.getElementsByTagName('*');var ret=new Array();if(collection!=null){for(var i=0;i<collection.length;i++){if(collection[i].className.indexOf(className)!=-1)
ret.push(collection[i]);}}
return ret;}
function _aspxGetParentByPartialId(element,idPart){while(element!=null){if(_aspxIsExists(element.id)){if(element.id.indexOf(idPart)>-1)return element;}
element=element.parentNode;}
return null;}
function _aspxGetElementsByPartialId(element,partialName,list){if(!_aspxIsExists(element.id))return;if(element.id.indexOf(partialName)>-1){list.push(element);}
for(var i=0;i<element.childNodes.length;i++){_aspxGetElementsByPartialId(element.childNodes[i],partialName,list);}}
function _aspxIFrameWindow(name){if(__aspxIE)
return window.frames[name].window;else{var frameElement=document.getElementById(name);return(frameElement!=null)?frameElement.contentWindow:null;}}
function _aspxIFrameDocument(name){if(__aspxIE)
return window.frames[name].document;else{var frameElement=document.getElementById(name);return(frameElement!=null)?frameElement.contentDocument:null;}}
function _aspxIFrameDocumentBody(name){var doc=_aspxIFrameDocument(name);return(doc!=null)?doc.body:null;}
function _aspxIFrameElement(name){if(__aspxIE)
return window.frames[name].window.frameElement;else
return document.getElementById(name);}
function _aspxRemoveElement(element){if(_aspxIsExists(element)){var parent=element.parentNode;if(_aspxIsExists(parent))
parent.removeChild(element);}
element=null;}
function _aspxReplaceTagName(element,newTagName){if(__aspxIE){element.insertAdjacentHTML('beforeBegin',"<"+newTagName+">"+element.innerHTML+"</"+newTagName+">");_aspxRemoveElement(element);}else{var docFragment=element.ownerDocument.createDocumentFragment();var newElem=element.ownerDocument.createElement(newTagName);docFragment.appendChild(newElem);for(var i=0;i<element.childNodes.length;i++)
newElem.appendChild(element.childNodes[i].cloneNode(true));element.parentNode.replaceChild(docFragment,element);}}
function _aspxRemoveOuterTags(element){if(__aspxIE){element.insertAdjacentHTML('beforeBegin',element.innerHTML);_aspxRemoveElement(element);}else{var docFragment=element.ownerDocument.createDocumentFragment();for(var i=0;i<element.childNodes.length;i++)
docFragment.appendChild(element.childNodes[i].cloneNode(true));element.parentNode.replaceChild(docFragment,element);}}
function _aspxWrapElementInNewElement(element,newElementTagName){var wrapElement=null;if(__aspxIE){var id=(new Date()).getTime();element.insertAdjacentHTML('beforeBegin',"<"+newElementTagName+" id='"+id+"'>"+element.outerHTML+"</"+newElementTagName+">");wrapElement=element.ownerDocument.getElementById(id);_aspxRemoveElement(element);_aspxRemoveAttribute(wrapElement,"id");}else{var docFragment=element.ownerDocument.createDocumentFragment();wrapElement=element.ownerDocument.createElement(newElementTagName);docFragment.appendChild(wrapElement);wrapElement.appendChild(element.cloneNode(true));element.parentNode.replaceChild(docFragment,element);}
return wrapElement;}
function _aspxGetEvent(evt){return(typeof(event)!="undefined"&&event!=null)?event:evt;}
function _aspxPreventEvent(evt){if(__aspxNS)
evt.preventDefault();else
evt.returnValue=false;return false;}
function _aspxPreventEventAndBubble(evt){_aspxPreventEvent(evt);if(__aspxNS)
evt.stopPropagation();evt.cancelBubble=true;return false;}
function _aspxCancelBubble(evt){evt.cancelBubble=true;return false;}
function _aspxGetEventSource(evt){evt=_aspxGetEvent(evt);if(!_aspxIsExists(evt))return null;return __aspxIE?evt.srcElement:evt.target;}
function _aspxGetEventX(evt){return evt.clientX-_aspxGetIEDocumentClientOffsetInternal(true)+((__aspxSafari&&!__aspxSafari3)?0:_aspxGetDocumentScrollLeft());}
function _aspxGetEventY(evt){return evt.clientY-_aspxGetIEDocumentClientOffsetInternal(false)+((__aspxSafari&&!__aspxSafari3)?0:_aspxGetDocumentScrollTop());}
function _aspxGetIEDocumentClientOffset(IsX){return 0;}
function _aspxGetIEDocumentClientOffsetInternal(IsX){var clientOffset=0;if(__aspxIE){if(_aspxIsExists(document.documentElement))
clientOffset=IsX?document.documentElement.clientLeft:document.documentElement.clientTop;if(clientOffset==0&&_aspxIsExists(document.body))
var clientOffset=IsX?document.body.clientLeft:document.body.clientTop;}
return clientOffset;}
function _aspxGetIsLeftButtonPressed(evt){evt=_aspxGetEvent(evt);if(!_aspxIsExists(evt))return false;if(__aspxIE)
return evt.button==1;else if(__aspxNS||__aspxSafariFamily)
return evt.which==1;else if(__aspxOpera)
return evt.button==0;return true;}
function _aspxGetWheelDelta(evt){var ret=__aspxNS?-evt.detail:evt.wheelDelta;if(__aspxOpera&&!__aspxOpera9)
ret=-ret;return ret;}
function _aspxDelCookie(name){_aspxSetCookieInternal(name,"",new Date(1970,1,1));}
function _aspxGetCookie(name){var cookies=document.cookie.split(';');for(var i=0;i<cookies.length;i++){var cookie=_aspxTrim(cookies[i]);if(cookie.indexOf(name+"=")==0)
return cookie.substring(name.length+1,cookie.length);}
return null;}
function _aspxSetCookie(name,value){var date=new Date();date.setFullYear(date.getFullYear()+1);_aspxSetCookieInternal(name,value,date);}
function _aspxSetCookieInternal(name,value,date){document.cookie=name+"="+escape(value)+"; expires="+date.toGMTString()+"; path=/";}
function _aspxGetElementDisplay(element){return element.style.display!="none";}
function _aspxSetElementDisplay(element,value){element.style.display=value?"":"none";}
function _aspxGetElementVisibility(element){return element.style.visibility!="hidden";}
function _aspxSetElementVisibility(element,value){element.style.visibility=value?"":"hidden";}
function _aspxAddStyleSheetLinkToDocument(doc,linkUrl){var newLink=_aspxCreateStyleLink(doc,linkUrl);var head=_aspxGetHeadElementOrCreateIfNotExist(doc);head.appendChild(newLink);}
function _aspxGetHeadElementOrCreateIfNotExist(doc){var elements=_aspxGetElementsByTagName(doc,"head");var head=null;if(elements.length==0){head=doc.createElement("head");head.visibility="hidden";doc.insertBefore(head,doc.body);}else
head=elements[0];return head;}
function _aspxCreateStyleLink(doc,url){var newLink=doc.createElement("link");_aspxSetAttribute(newLink,"href",url);_aspxSetAttribute(newLink,"type","text/css");_aspxSetAttribute(newLink,"rel","stylesheet");return newLink;}
function _aspxGetCurrentStyle(element){if(__aspxIE)
return element.currentStyle;else if(__aspxOpera&&!__aspxOpera9)
return window.getComputedStyle(element,null);else
return document.defaultView.getComputedStyle(element,null);}
function _aspxIsElementRigthToLeft(element){var style=_aspxGetCurrentStyle(element);if(__aspxIE)
style.writingMode.toUpperCase().indexOf("RL")>-1;return style.direction.toUpperCase().indexOf("RTL")>-1;}
function _aspxCreateStyleSheetInDocument(doc){if(__aspxIE)
return doc.createStyleSheet();else{var styleSheet=doc.createElement("STYLE");_aspxGetChildByTagName(doc,"HEAD",0).appendChild(styleSheet);return doc.styleSheets[doc.styleSheets.length-1];}}
function _aspxCreateStyleSheet(){return _aspxCreateStyleSheetInDocument(document);}
function _aspxGetStyleSheetRules(styleSheet){try{return __aspxIE?styleSheet.rules:styleSheet.cssRules;}
catch(e){return null;}}
function _aspxGetStyleSheetRule(className){if(_aspxIsExists(__aspxCachedRules[className])){if(__aspxCachedRules[className]!=__aspxEmptyCachedValue)
return __aspxCachedRules[className];return null;}
for(var i=0;i<document.styleSheets.length;i++){var styleSheet=document.styleSheets[i];var rules=_aspxGetStyleSheetRules(styleSheet);if(rules!=null){for(var j=0;j<rules.length;j++){if(rules[j].selectorText=="."+className){__aspxCachedRules[className]=rules[j];return rules[j];}}}}
__aspxCachedRules[className]=__aspxEmptyCachedValue;return null;}
function _aspxRemoveStyleSheetRule(styleSheet,index){var rules=_aspxGetStyleSheetRules(styleSheet);if(rules!=null&&rules.length>0&&rules.length>=index){if(__aspxIE)
styleSheet.removeRule(index);else
styleSheet.deleteRule(index);}}
function _aspxAddStyleSheetRule(styleSheet,selector,cssText){if(!_aspxIsExists(cssText)||cssText=="")return;if(__aspxIE)
styleSheet.addRule(selector,cssText);else
styleSheet.insertRule(selector+" { "+cssText+" }",styleSheet.cssRules.length);}
function _aspxGetPointerCursor(){return __aspxIE?"hand":"pointer";}
function _aspxSetPointerCursor(element){if(element.style.cursor=="")
element.style.cursor=_aspxGetPointerCursor();}
var _aspxWebKit3TDRealInfo={GetOffsetTop:function(tdElement){switch(_aspxGetCurrentStyle(tdElement).verticalAlign){case"middle":return Math.round(tdElement.offsetTop-(tdElement.offsetHeight-tdElement.clientHeight)/2+tdElement.clientTop);case"bottom":return tdElement.offsetTop-tdElement.offsetHeight+tdElement.clientHeight+tdElement.clientTop;}
return tdElement.offsetTop;},GetClientHeight:function(tdElement){var valign=_aspxGetCurrentStyle(tdElement).verticalAlign;switch(valign){case"middle":return tdElement.clientHeight+tdElement.offsetTop*2;case"top":return tdElement.offsetHeight-tdElement.clientTop*2;case"bottom":return tdElement.clientHeight+tdElement.offsetTop;}
return tdElement.clientHeight;}}
function _aspxGetIsValidPosition(pos){return pos!=__aspxInvalidPosition&&pos!=-__aspxInvalidPosition;}
function _aspxGetAbsoluteX(curEl){return _aspxGetAbsolutePositionX(curEl);}
function _aspxGetAbsoluteY(curEl){return _aspxGetAbsolutePositionY(curEl);}
function _aspxSetAbsoluteX(element,x){element.style.left=_aspxPrepareClientPosForElement(x,element,true)+"px";}
function _aspxSetAbsoluteY(element,y){element.style.top=_aspxPrepareClientPosForElement(y,element,false)+"px";}
function _aspxGetAbsolutePositionX(element){if(__aspxIE)
return _aspxGetAbsolutePositionX_IE(element);else if(__aspxFirefox3)
return _aspxGetAbsolutePositionX_FF3(element);else if(__aspxOpera)
return _aspxGetAbsolutePositionX_Opera(element);else if(__aspxNS&&!__aspxFirefox3)
return _aspxGetAbsolutePositionX_NS(element);else if(__aspxSafariFamily)
return _aspxGetAbsolutePositionX_Safari(element);else
return _aspxGetAbsolutePositionX_Other(element);}
function _aspxGetAbsolutePositionX_Opera(curEl){var pos=_aspxGetAbsoluteOffsetX_OperaFFSafari(curEl);while(curEl!=null){pos+=curEl.offsetLeft;pos-=curEl.scrollLeft;curEl=curEl.offsetParent;}
pos+=document.body.scrollLeft;return pos;}
function _aspxGetAbsolutePositionX_IE(element){if(element==null||__aspxIE&&element.parentNode==null)return 0;return element.getBoundingClientRect().left+_aspxGetDocumentScrollLeft()-_aspxGetIEDocumentClientOffsetInternal(true);}
function _aspxGetAbsolutePositionX_FF3(element){if(element==null)return 0;var x=element.getBoundingClientRect().left+_aspxGetDocumentScrollLeft()-_aspxGetIEDocumentClientOffsetInternal(true);return Math.round(x);}
function _aspxGetAbsolutePositionX_NS(curEl){var pos=_aspxGetAbsoluteOffsetX_OperaFFSafari(curEl);var isFirstCycle=true;while(curEl!=null){pos+=curEl.offsetLeft;if(!isFirstCycle&&curEl.offsetParent!=null)
pos-=curEl.scrollLeft;if(!isFirstCycle&&__aspxFirefox){var style=_aspxGetCurrentStyle(curEl);if(curEl.tagName=="DIV"&&style.overflow!="visible")
pos+=_aspxPxToInt(style.borderLeftWidth);}
isFirstCycle=false;curEl=curEl.offsetParent;}
return pos;}
function _aspxGetAbsolutePositionX_Safari(curEl){var pos=_aspxGetAbsoluteOffsetX_OperaFFSafari(curEl);var isSafari3OrChrome=__aspxSafari3||__aspxChrome;if(curEl!=null){var isFirstCycle=true;if(isSafari3OrChrome&&curEl.tagName=="TD"){pos+=curEl.offsetLeft;curEl=curEl.offsetParent;isFirstCycle=false;}
while(curEl!=null){pos+=curEl.offsetLeft;if(isSafari3OrChrome&&!isFirstCycle&&(curEl.tagName=="TD"||curEl.tagName=="TABLE"))
pos+=curEl.clientLeft;isFirstCycle=false;curEl=curEl.offsetParent;}}
return pos;}
function _aspxGetAbsoluteOffsetX_OperaFFSafari(curEl){var pos=0;while(curEl!=null){if(curEl.tagName=="BODY")
break;var style=_aspxGetCurrentStyle(curEl);if(!__aspxSafariFamily&&style.position=="absolute")
break;if(curEl.tagName=="DIV"&&(__aspxSafariFamily||style.position==""||style.position=="static"))
pos-=curEl.scrollLeft;curEl=curEl.parentNode;}
return pos;}
function _aspxGetAbsolutePositionX_Other(curEl){var pos=0;var isFirstCycle=true;while(curEl!=null){pos+=curEl.offsetLeft;if(!isFirstCycle&&curEl.offsetParent!=null)
pos-=curEl.scrollLeft;isFirstCycle=false;curEl=curEl.offsetParent;}
return pos;}
function _aspxGetAbsolutePositionY(element){if(__aspxIE)
return _aspxGetAbsolutePositionY_IE(element);else if(__aspxFirefox3)
return _aspxGetAbsolutePositionY_FF3(element);else if(__aspxOpera)
return _aspxGetAbsolutePositionY_Opera(element);else if(__aspxNS&&!__aspxFirefox3)
return _aspxGetAbsolutePositionY_NS(element);else if(__aspxSafariFamily)
return _aspxGetAbsolutePositionY_Safari(element);else
return _aspxGetAbsolutePositionY_Other(element);}
function _aspxGetAbsolutePositionY_Opera(curEl){if(curEl&&curEl.tagName=="TR"&&curEl.cells.length>0)
curEl=curEl.cells[0];var pos=_aspxGetAbsoluteOffsetY_OperaFFSafari(curEl);while(curEl!=null){pos+=curEl.offsetTop;pos-=curEl.scrollTop;curEl=curEl.offsetParent;}
pos+=document.body.scrollTop;return pos;}
function _aspxGetAbsolutePositionY_IE(element){if(element==null||__aspxIE&&element.parentNode==null)return 0;return element.getBoundingClientRect().top+_aspxGetDocumentScrollTop()-_aspxGetIEDocumentClientOffsetInternal(false);}
function _aspxGetAbsolutePositionY_FF3(element){if(element==null)return 0;var y=element.getBoundingClientRect().top+_aspxGetDocumentScrollTop()-_aspxGetIEDocumentClientOffsetInternal(false);return Math.round(y);}
function _aspxGetAbsolutePositionY_NS(curEl){var pos=_aspxGetAbsoluteOffsetY_OperaFFSafari(curEl);var isFirstCycle=true;while(curEl!=null){pos+=curEl.offsetTop;if(!isFirstCycle&&curEl.offsetParent!=null)
pos-=curEl.scrollTop;if(!isFirstCycle&&__aspxFirefox){var style=_aspxGetCurrentStyle(curEl);if(curEl.tagName=="DIV"&&style.overflow!="visible")
pos+=_aspxPxToInt(style.borderTopWidth);}
isFirstCycle=false;curEl=curEl.offsetParent;}
return pos;}
function _aspxGetAbsolutePositionY_Safari(curEl){var pos=_aspxGetAbsoluteOffsetY_OperaFFSafari(curEl);var isSafari3OrChrome=__aspxSafari3||__aspxChrome;if(curEl!=null){var isFirstCycle=true;if(isSafari3OrChrome&&curEl.tagName=="TD"){pos+=_aspxWebKit3TDRealInfo.GetOffsetTop(curEl);curEl=curEl.offsetParent;isFirstCycle=false;}
while(curEl!=null){pos+=curEl.offsetTop;if(isSafari3OrChrome&&!isFirstCycle&&(curEl.tagName=="TD"||curEl.tagName=="TABLE"))
pos+=curEl.clientTop;isFirstCycle=false;curEl=curEl.offsetParent;}}
return pos;}
function _aspxGetAbsoluteOffsetY_OperaFFSafari(curEl){var pos=0;while(curEl!=null){if(curEl.tagName=="BODY")
break;var style=_aspxGetCurrentStyle(curEl);if(!__aspxSafariFamily&&style.position=="absolute")
break;if(curEl.tagName=="DIV"&&(__aspxSafariFamily||style.position==""||style.position=="static"))
pos-=curEl.scrollTop;curEl=curEl.parentNode;}
return pos;}
function _aspxGetAbsolutePositionY_Other(curEl){var pos=0;var isFirstCycle=true;while(curEl!=null){pos+=curEl.offsetTop;if(!isFirstCycle&&curEl.offsetParent!=null)
pos-=curEl.scrollTop;isFirstCycle=false;curEl=curEl.offsetParent;}
return pos;}
function _aspxPrepareClientPosForElement(pos,element,isX){pos-=_aspxGetPositionElementOffset(element,isX);return pos;}
function _aspxGetPositionElementOffset(element,isX){var curEl=element.offsetParent;var offset=0;var scroll=0;var isThereFixedParent=false;var isFixed=false;var position="";while(curEl!=null){var tagName=curEl.tagName;if(tagName=="HTML"||tagName=="BODY")
break;if(tagName!="TD"&&tagName!="TR"){var style=_aspxGetCurrentStyle(curEl);isFixed=style.position=="fixed";if(isFixed)
isThereFixedParent=true;if(style.position=="absolute"||isFixed||style.position=="relative"){offset+=isX?curEl.offsetLeft:curEl.offsetTop;if(__aspxIE||__aspxOpera9||__aspxSafariMacOS)
offset+=_aspxPxToInt(isX?style.borderLeftWidth:style.borderTopWidth);}}
scroll+=isX?curEl.scrollLeft:curEl.scrollTop;curEl=curEl.offsetParent;}
offset-=scroll;if((__aspxIE7||__aspxFirefox3)&&isThereFixedParent)
offset+=isX?_aspxGetDocumentScrollLeft():_aspxGetDocumentScrollTop();return offset;}
function _aspxPxToInt(px){var result=0;if(px!=null&&px!=""){try{var indexOfPx=px.indexOf("px");if(indexOfPx>-1)
result=parseInt(px.substr(0,indexOfPx));}catch(e){}}
return result;}
function _aspxGetClearClientWidth(element){var currentStyle=_aspxGetCurrentStyle(element);return element.offsetWidth-_aspxPxToInt(currentStyle.paddingLeft)-_aspxPxToInt(currentStyle.paddingRight)-
_aspxPxToInt(currentStyle.borderLeftWidth)-_aspxPxToInt(currentStyle.borderRightWidth);}
function _aspxGetClearClientHeight(element){var currentStyle=_aspxGetCurrentStyle(element);return element.offsetHeight-_aspxPxToInt(currentStyle.paddingTop)-_aspxPxToInt(currentStyle.paddingBottom)-
_aspxPxToInt(currentStyle.borderTopWidth)-_aspxPxToInt(currentStyle.borderBottomWidth);}
function _aspxSetOffsetWidth(element,widthValue){var currentStyle=_aspxGetCurrentStyle(element);var value=widthValue-_aspxPxToInt(currentStyle.marginLeft)-_aspxPxToInt(currentStyle.marginRight);if(__aspxIE)
value-=_aspxPxToInt(currentStyle.paddingLeft)+_aspxPxToInt(currentStyle.paddingRight)+
_aspxPxToInt(currentStyle.borderLeftWidth)+_aspxPxToInt(currentStyle.borderRightWidth);if(value>-1)
element.style.width=value+"px";}
function _aspxSetOffsetHeight(element,heightValue){var currentStyle=_aspxGetCurrentStyle(element);var value=heightValue-_aspxPxToInt(currentStyle.marginTop)-_aspxPxToInt(currentStyle.marginBottom);if(__aspxIE)
value-=_aspxPxToInt(currentStyle.paddingTop)+_aspxPxToInt(currentStyle.paddingBottom)+
_aspxPxToInt(currentStyle.borderTopWidth)+_aspxPxToInt(currentStyle.borderBottomWidth);if(value>-1)
element.style.height=value+"px";}
function _aspxFindOffsetParent(element){if(__aspxIE)
return element.offsetParent;var currentElement=element.parentNode;while(_aspxIsExistsElement(currentElement)&&currentElement.tagName!="BODY"){if(currentElement.offsetWidth>0&&currentElement.offsetHeight>0)
return currentElement;currentElement=currentElement.parentNode;}
return document.body;}
function _aspxGetDocumentScrollTop(){if(__aspxSafariFamily||__aspxIE55||document.documentElement.scrollTop==0)
return document.body.scrollTop;else
return document.documentElement.scrollTop;}
function _aspxGetDocumentScrollLeft(){if(__aspxSafariFamily||__aspxIE55||document.documentElement.scrollLeft==0)
return document.body.scrollLeft;else
return document.documentElement.scrollLeft;}
function _aspxGetDocumentClientWidth(){if(__aspxSafariFamily||__aspxIE55||document.documentElement.clientWidth==0)
return document.body.clientWidth;else
return document.documentElement.clientWidth;}
function _aspxGetDocumentClientHeight(){if(__aspxSafariFamily)
return window.innerHeight;else if(__aspxIE55||__aspxOpera||document.documentElement.clientHeight==0)
return document.body.clientHeight;else
return document.documentElement.clientHeight;}
function _aspxSetStylePosition(element,x,y){element.style.left=x+"px";element.style.top=y+"px";}
function _aspxSetStyleSize(element,width,height){element.style.width=width+"px";element.style.height=height+"px";}
function _aspxGetDocumentWidth(){var bodyWidth=document.body.offsetWidth;var docWidth=document.documentElement.offsetWidth;var bodyScrollWidth=document.body.scrollWidth;var docScrollWidth=document.documentElement.scrollWidth;return _aspxGetMaxDimensionOf(bodyWidth,docWidth,bodyScrollWidth,docScrollWidth);}
function _aspxGetDocumentHeight(){var bodyHeight=document.body.offsetHeight;var docHeight=document.documentElement.offsetHeight;var bodyScrollHeight=document.body.scrollHeight;var docScrollHeight=document.documentElement.scrollHeight;return _aspxGetMaxDimensionOf(bodyHeight,docHeight,bodyScrollHeight,docScrollHeight);}
function _aspxGetDocumentMaxClientWidth(){var bodyWidth=document.body.offsetWidth;var docWidth=document.documentElement.offsetWidth;return _aspxGetMaxDimensionOf(bodyWidth,docWidth);}
function _aspxGetDocumentMaxClientHeight(){var bodyHeight=document.body.offsetHeight;var docHeight=document.documentElement.offsetHeight;return _aspxGetMaxDimensionOf(bodyHeight,docHeight);}
function _aspxGetMaxDimensionOf(){var max=__aspxInvalidDimension;for(var i=0;i<arguments.length;i++){if(max<arguments[i])
max=arguments[i];}
return max;}
function _aspxGetClientLeft(element){return _aspxIsExists(element.clientLeft)?element.clientLeft:(element.offsetWidth-element.clientWidth)/2;}
function _aspxGetClientTop(element){return _aspxIsExists(element.clientTop)?element.clientTop:(element.offsetHeight-element.clientHeight)/2;}
function _aspxRemoveBorders(element){if(!_aspxIsExists(element))
return;element.style.borderWidth=0;for(var i=0;i<element.childNodes.length;i++){var child=element.childNodes[i];if(_aspxIsExists(child.style))
child.style.border="0";}}
function _aspxSetBackground(element,background){if(!_aspxIsExists(element))
return;element.style.backgroundColor=background;for(var i=0;i<element.childNodes.length;i++){var child=element.childNodes[i];if(_aspxIsExists(child.style))
child.style.backgroundColor=background;}}
function _aspxSetFocus(element){try{element.focus();if(__aspxIE&&document.activeElement!=element)
element.focus();}catch(e){}}
function _aspxIsFocusableCore(element,skipContainerVisibilityCheck){var current=element;while(_aspxIsExists(current)){if(current==element||!skipContainerVisibilityCheck(current)){if(current.tagName=="BODY")
return true;if(current.disabled||!_aspxGetElementDisplay(current)||!_aspxGetElementVisibility(current))
return false;}
current=current.parentNode;}
return true;}
function _aspxIsFocusable(element){return _aspxIsFocusableCore(element,function(){return false;});}
function _aspxAttachEventToElement(element,eventName,func){if(__aspxNS||__aspxSafariFamily)
element.addEventListener(eventName,func,true);else{if(eventName.toLowerCase().indexOf("on")!=0)
eventName="on"+eventName;element.attachEvent(eventName,func);}}
function _aspxDetachEventFromElement(element,eventName,func){if(__aspxNS||__aspxSafariFamily)
element.removeEventListener(eventName,func,true);else{if(eventName.toLowerCase().indexOf("on")!=0)
eventName="on"+eventName;element.detachEvent(eventName,func);}}
function _aspxAttachEventToDocument(eventName,func){_aspxAttachEventToElement(document,eventName,func);}
function _aspxDetachEventFromDocument(eventName,func){_aspxAttachEventToElement(document,eventName,func);}
function _aspxCreateEventHandlerFunction(funcName,controlName,withHtmlEventArg){return withHtmlEventArg?new Function("event",funcName+"('"+controlName+"', event);"):new Function(funcName+"('"+controlName+"');");}
function _aspxCreateClass(parentClass,properties){var ret=function(){if(ret.preparing)
return delete(ret.preparing);if(ret.constr){this.constructor=ret;ret.constr.apply(this,arguments);}}
ret.prototype={};if(_aspxIsExists(parentClass)){parentClass.preparing=true;ret.prototype=new parentClass;ret.prototype.constructor=parentClass;ret.constr=parentClass;}
if(_aspxIsExists(properties)){var constructorName="constructor";for(var name in properties){if(name!=constructorName)
ret.prototype[name]=properties[name];}
if(properties[constructorName]&&properties[constructorName]!=Object)
ret.constr=properties[constructorName];}
return ret;}
function _aspxGetAttribute(obj,attrName){if(_aspxIsExists(obj.getAttribute))
return obj.getAttribute(attrName);else if(_aspxIsExists(obj.getPropertyValue))
return obj.getPropertyValue(attrName);return null;}
function _aspxSetAttribute(obj,attrName,value){if(_aspxIsExists(obj.setAttribute))
obj.setAttribute(attrName,value);else if(_aspxIsExists(obj.setProperty))
obj.setProperty(attrName,value,"");}
function _aspxRemoveAttribute(obj,attrName){if(_aspxIsExists(obj.removeAttribute))
obj.removeAttribute(attrName);else if(_aspxIsExists(obj.removeProperty))
obj.removeProperty(attrName);}
function _aspxIsExistsAttribute(obj,attrName){var value=_aspxGetAttribute(obj,attrName);return(value!=null)&&(value!="");}
function _aspxSetOrRemoveAttribute(obj,attrName,value){if(!value)
_aspxRemoveAttribute(obj,attrName);else
_aspxSetAttribute(obj,attrName,value);}
function _aspxChangeAttributeExtended(obj,attrName,savedObj,savedAttrName,newValue){if(!_aspxIsExistsAttribute(savedObj,savedAttrName)){var oldValue=_aspxIsExistsAttribute(obj,attrName)?_aspxGetAttribute(obj,attrName):__aspxEmptyAttributeValue;_aspxSetAttribute(savedObj,savedAttrName,oldValue);}
_aspxSetAttribute(obj,attrName,newValue);}
function _aspxChangeAttribute(obj,attrName,newValue){_aspxChangeAttributeExtended(obj,attrName,obj,"saved"+attrName,newValue);}
function _aspxChangeStyleAttribute(obj,attrName,newValue){_aspxChangeAttributeExtended(obj.style,attrName,obj,"saved"+attrName,newValue);}
function _aspxResetAttributeExtended(obj,attrName,savedObj,savedAttrName){if(!_aspxIsExistsAttribute(savedObj,savedAttrName)){var oldValue=_aspxIsExistsAttribute(obj,attrName)?_aspxGetAttribute(obj,attrName):__aspxEmptyAttributeValue;_aspxSetAttribute(savedObj,savedAttrName,oldValue);}
_aspxSetAttribute(obj,attrName,"");_aspxRemoveAttribute(obj,attrName);}
function _aspxResetAttribute(obj,attrName){_aspxResetAttributeExtended(obj,attrName,obj,"saved"+attrName);}
function _aspxResetStyleAttribute(obj,attrName){_aspxResetAttributeExtended(obj.style,attrName,obj,"saved"+attrName);}
function _aspxRestoreAttributeExtended(obj,attrName,savedObj,savedAttrName){if(_aspxIsExistsAttribute(savedObj,savedAttrName)){var oldValue=_aspxGetAttribute(savedObj,savedAttrName);if(oldValue!=__aspxEmptyAttributeValue)
_aspxSetAttribute(obj,attrName,oldValue);else
_aspxRemoveAttribute(obj,attrName);_aspxRemoveAttribute(savedObj,savedAttrName);}}
function _aspxRestoreAttribute(obj,attrName){_aspxRestoreAttributeExtended(obj,attrName,obj,"saved"+attrName);}
function _aspxRestoreStyleAttribute(obj,attrName){_aspxRestoreAttributeExtended(obj.style,attrName,obj,"saved"+attrName);}
function _aspxRemoveAllAttributes(element,excludedAttributes){var excludedAttributesHashTable={};if(_aspxIsExists(excludedAttributes))
excludedAttributesHashTable=_aspxCreateHashTableFromArray(excludedAttributes);if(_aspxIsExists(element.attributes)){var attrArray=element.attributes;for(var i=0;i<attrArray.length;i++){var attrName=attrArray[i].name;if(!_aspxIsExists(excludedAttributesHashTable[attrName.toLowerCase()]))
attrArray.removeNamedItem(attrName);}}}
function _aspxRemoveStyleAttribute(element,attrName){if(_aspxIsExists(element.style)){if(_aspxIsExists(element.style.removeAttribute))
element.style.removeAttribute(attrName);else if(_aspxIsExists(element.style.removeProperty))
element.style.removeProperty(attrName);}}
function _aspxRemoveAllStyles(element){if(_aspxIsExists(element.style)){for(var key in element.style)
_aspxRemoveStyleAttribute(element,key);_aspxRemoveAttribute(element,"style");}}
function _aspxChangeAttributesMethod(enabled){return enabled?_aspxRestoreAttribute:_aspxResetAttribute;}
function _aspxInitiallyChangeAttributesMethod(enabled){return enabled?_aspxChangeAttribute:_aspxResetAttribute;}
function _aspxChangeStyleAttributesMethod(enabled){return enabled?_aspxRestoreStyleAttribute:_aspxResetStyleAttribute;}
function _aspxInitiallyChangeStyleAttributesMethod(enabled){return enabled?_aspxChangeStyleAttribute:_aspxResetStyleAttribute;}
function _aspxChangeEventsMethod(enabled){return enabled?_aspxAttachEventToElement:_aspxDetachEventFromElement;}
function _aspxChangeDocumentEventsMethod(enabled){return enabled?_aspxAttachEventToDocument:_aspxDetachEventFromDocument;}
function _aspxLTrim(str){var re=/\s*((\S+\s*)*)/;return str.replace(re,"$1");}
function _aspxRTrim(str){var re=/((\s*\S+)*)\s*/;return str.replace(re,"$1");}
function _aspxTrim(str){return _aspxLTrim(_aspxRTrim(str));}
function _aspxInsert(str,subStr,index){var leftText=str.slice(0,index);var rightText=str.slice(index);return leftText+subStr+rightText;}
function _aspxInsertEx(str,subStr,startIndex,endIndex){var leftText=str.slice(0,startIndex);var rightText=str.slice(endIndex);return leftText+subStr+rightText;}
function _aspxNavigateUrl(url,target){var javascriptPrefix="javascript:";if(url=="")
return;else if(url.indexOf(javascriptPrefix)!=-1)
eval(url.substr(javascriptPrefix.length));else{if(target!="")
_aspxNavigateTo(url,target);else
location.href=url;}}
function _aspxNavigateTo(url,target){target=target.toLowerCase();if("_top"==target)
top.location.href=url;else if("_self"==target)
location.href=url;else if("_search"==target)
window.open(url,'blank');else if("_media"==target)
window.open(url,'blank');else if("_parent"==target)
window.parent.location.href=url;else if("_blank"==target)
window.open(url,'blank');else{var frame=_aspxGetFrame(top.frames,target);if(frame!=null)
frame.location.href=url;else
window.open(url,'blank');}}
function _aspxGetFrame(frames,name){if(_aspxIsExists(frames[name]))
return frames[name];for(var i=0;i<frames.length;i++){try{var frame=frames[i];if(frame.name==name)
return frame;frame=_aspxGetFrame(frame.frames,name);if(frame!=null)
return frame;}catch(e){}}
return null;}
function _aspxToHex(d){return(d<16)?("0"+d.toString(16)):d.toString(16);}
function _aspxColorToHexadecimal(colorValue){if(typeof(colorValue)=="number"){var r=colorValue&0xFF;var g=(colorValue>>8)&0xFF;var b=(colorValue>>16)&0xFF;return"#"+_aspxToHex(r)+_aspxToHex(g)+_aspxToHex(b);}
if(colorValue&&(colorValue.substr(0,3)=="rgb")){var re=/rgb\s*\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*\)/;var regResult=colorValue.match(re);if(regResult){var r=parseInt(regResult[1]);var g=parseInt(regResult[2]);var b=parseInt(regResult[3]);return"#"+_aspxToHex(r)+_aspxToHex(g)+_aspxToHex(b);}
return null;}
if(colorValue&&(colorValue.charAt(0)=="#"))
return colorValue;return null;}
function _aspxFormatCallbackArg(prefix,arg){if(prefix==null||prefix==""||arg==null)
return"";if(arg!=null&&!_aspxIsExists(arg.length)&&_aspxIsExists(arg.value))
arg=arg.value;arg=arg.toString();return[prefix,'|',arg.length,'|',arg].join('');}
function _aspxFormatCallbackArgs(callbackData){var sb=new ASPxStringBuilder();for(var i=0;i<callbackData.length;i++)
sb.Append(_aspxFormatCallbackArg(callbackData[i][0],callbackData[i][1]));return sb.ToString();}
function _aspxIsValidElement(element){if(__aspxIE)
return _aspxIsExists(element.parentNode)&&_aspxIsExists(element.parentNode.tagName);else{if(!__aspxOpera&&element.offsetParent!=null)
return true;while(element!=null){if(_aspxIsExists(element.tagName)&&element.tagName=="BODY")
return true;element=element.parentNode;}
return false;}}
function _aspxIsValidElements(elements){if(!_aspxIsExists(elements))
return false;for(var i=0;i<elements.length;i++){if(_aspxIsExists(elements[i])&&!_aspxIsValidElement(elements[i]))
return false;}
return true;}
function _aspxIsExistsElement(element){return _aspxIsExists(element)&&_aspxIsValidElement(element);}
ASPxClientEvent=_aspxCreateClass(null,{constructor:function(){this.handlerInfoList=[];},AddHandler:function(handler,executionContext){if(typeof(executionContext)=="undefined")
executionContext=null;var handlerInfo=ASPxClientEvent.CreateHandlerInfo(handler,executionContext);this.handlerInfoList.push(handlerInfo);},RemoveHandler:function(handler,executionContext){for(var i=this.handlerInfoList.length-1;i>=0;i--){var handlerInfo=this.handlerInfoList[i];if(handlerInfo.handler==handler&&(!executionContext||handlerInfo.executionContext==executionContext)){_aspxArrayRemoveAt(this.handlerInfoList,i);return;}}},ClearHandlers:function(){this.handlerInfoList.length=0;},FireEvent:function(obj,args){for(var i=0;i<this.handlerInfoList.length;i++){var handlerInfo=this.handlerInfoList[i];handlerInfo.handler.call(handlerInfo.executionContext,obj,args);}},IsEmpty:function(){return this.handlerInfoList.length==0;}});ASPxClientEvent.CreateHandlerInfo=function(handler,executionContext){var info=new Object();info.handler=handler;info.executionContext=executionContext;return info;};ASPxClientEventArgs=_aspxCreateClass(null,{constructor:function(){}});ASPxClientEventArgs.Empty=new ASPxClientEventArgs();ASPxClientProcessingModeEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(processOnServer){this.constructor.prototype.constructor.call(this);this.processOnServer=processOnServer;}});ASPxClientCancelEventArgs=_aspxCreateClass(ASPxClientProcessingModeEventArgs,{constructor:function(processOnServer){this.constructor.prototype.constructor.call(this,processOnServer);this.cancel=false;}});ASPxClientBeginCallbackEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(command){this.constructor.prototype.constructor.call();this.command=command;}});ASPxClientEndCallbackEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(){this.constructor.prototype.constructor.call();}});ASPxClientCallbackErrorEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(message){this.constructor.prototype.constructor.call();this.message=message;this.handled=false;}});ASPxPostHandler=_aspxCreateClass(null,{constructor:function(){this.Post=new ASPxClientEvent();this.ReplaceGlobalPostFunctions();},OnPost:function(){this.Post.FireEvent(this,ASPxClientEventArgs.Empty);},ReplaceGlobalPostFunctions:function(){if(_aspxIsFunction(window.__doPostBack))
this.ReplaceDoPostBack();var form=_aspxGetServerForm();if(_aspxIsFunction(form.submit))
this.ReplaceFormSubmit(form);this.ReplaceFormOnSumbit(form);form=null;},ReplaceDoPostBack:function(){var original=__doPostBack;__doPostBack=function(eventTarget,eventArgument){aspxGetPostHandler().OnPost();original(eventTarget,eventArgument);};},ReplaceFormSubmit:function(form){var original=form.submit;form.submit=function(){aspxGetPostHandler().OnPost();var callee=arguments.callee;this.submit=original;var submitResult=this.submit();this.submit=callee;return submitResult;};},ReplaceFormOnSumbit:function(form){var original=form.onsubmit;form.onsubmit=function(){aspxGetPostHandler().OnPost();return _aspxIsFunction(original)?original():true;};form=null;}});function aspxGetPostHandler(){if(!_aspxIsExistsType(typeof(window.__aspxPostHandler)))
window.__aspxPostHandler=new ASPxPostHandler();return window.__aspxPostHandler;}
ASPxClientControlCollection=_aspxCreateClass(null,{constructor:function(){this.elements=new Object();this.BeforeInitCallback=new ASPxClientEvent();this.ControlsInitialized=new ASPxClientEvent();},Add:function(element){this.elements[element.name]=element;},Get:function(name){return this.elements[name];},AdjustControls:function(container,checkSizeCorrectedFlag){this.ProcessControlsInConatiner(container,checkSizeCorrectedFlag,function(control,check){control.AdjustControl(check);});},CollapseControls:function(container,checkSizeCorrectedFlag){this.ProcessControlsInConatiner(container,checkSizeCorrectedFlag,function(control,check){control.CollapseControl(check);});},AtlasInitialize:function(){_aspxProcessScripts("");_aspxSweepDuplicatedLinks();_aspxMoveLinkElements();__aspxCachedRules={};},Initialize:function(){this.InitializeElements();if(_aspxIsExistsType(typeof(Sys))&&_aspxIsExistsType(typeof(Sys.Application)))
Sys.Application.add_load(aspxCAInit);},InitializeElements:function(){for(var name in this.elements){var control=this.elements[name];if(!ASPxIdent.IsASPxClientControl(control))
continue;if(!control.isInitialized)
control.Initialize();}
this.AfterInitializeElements(true);this.AfterInitializeElements(false);this.RaiseControlsInitialized();},AfterInitializeElements:function(leadingCall){for(var name in this.elements){var control=this.elements[name];if(!ASPxIdent.IsASPxClientControl(control))
continue;if(control.leadingAfterInitCall&&leadingCall||!control.leadingAfterInitCall&&!leadingCall){if(!this.elements[name].isInitialized)
this.elements[name].AfterInitialize();}}},DoFinalizeCallback:function(){for(var name in this.elements){var control=this.elements[name];if(!ASPxIdent.IsASPxClientControl(control))
continue;control.DoFinalizeCallback();}},ProcessControlsInConatiner:function(container,checkSizeCorrectedFlag,processingProc){for(var controlName in this.elements){var control=this.elements[controlName];if(!ASPxIdent.IsASPxClientControl(control))
continue;if(_aspxIsExists(container)&&_aspxIsExists(control.GetMainElement)){var mainElement=control.GetMainElement();if(_aspxIsExists(mainElement)&&!_aspxGetIsParent(container,mainElement))
continue;}
processingProc(control,checkSizeCorrectedFlag);}},RaiseControlsInitialized:function(){if(!this.ControlsInitialized.IsEmpty()){var args=new ASPxClientEventArgs();this.ControlsInitialized.FireEvent(this,args);}},Before_WebForm_InitCallback:function(){var args=new ASPxClientEventArgs();this.BeforeInitCallback.FireEvent(this,args);}});ASPxClientControl=_aspxCreateClass(null,{constructor:function(name){this.isASPxClientControl=true;this.name=name;this.uniqueID=name;this.enabled=true;this.clientEnabled=true;this.clientVisible=true;this.autoPostBack=false;this.allowMultipleCallbacks=true;this.callBack=null;this.savedCallbacks=null;this.isNative=false;this.requestCount=0;this.isInitialized=false;this.initialFocused=false;this.leadingAfterInitCall=false;this.sizeCorrectedOnce=false;this.serverEvents=[];this.dialogContentHashTable={};this.sizeCorrectedOnce=false;this.loadingPanelElement=null;this.loadingDivElement=null;this.mainElement=null;this.renderIFrameForPopupElements=false;this.Init=new ASPxClientEvent();this.BeginCallback=new ASPxClientEvent();this.EndCallback=new ASPxClientEvent();this.CallbackError=new ASPxClientEvent();aspxGetControlCollection().Add(this);},Initialize:function(){if(this.callBack!=null)
this.InitializeCallBackData();},InlineInitialize:function(){},InitailizeFocus:function(){if(this.initialFocused&&this.IsVisible())
this.Focus();},AfterInitialize:function(){this.AdjustControl(__aspxCheckSizeCorrectedFlag);this.InitailizeFocus();this.isInitialized=true;this.RaiseInit();if(_aspxIsExists(this.savedCallbacks)){for(var i=0;i<this.savedCallbacks.length;i++)
this.CreateCallbackInternal(this.savedCallbacks[i][0],this.savedCallbacks[i][1],false);this.savedCallbacks=null;}},InitializeCallBackData:function(){},CollapseControl:function(checkSizeCorrectedFlag){},IsVisibleWhenCorrectingSize:function(){return this.IsVisible();},AdjustControl:function(checkSizeCorrectedFlag){if(checkSizeCorrectedFlag&&this.sizeCorrectedOnce)
return;var mainElement=this.GetMainElement();if(!_aspxIsExists(mainElement)||!this.IsVisibleWhenCorrectingSize())
return;this.AdjustControlCore();this.sizeCorrectedOnce=true;},AdjustControlCore:function(){},RegisterServerEventAssigned:function(eventNames){for(var i=0;i<eventNames.length;i++)
this.serverEvents[eventNames[i]]=true;},IsServerEventAssigned:function(eventName){return _aspxIsExists(this.serverEvents[eventName]);},GetChild:function(idPostfix){var mainElement=this.GetMainElement();return _aspxIsExists(mainElement)?_aspxGetChildById(this.GetMainElement(),this.name+idPostfix):null;},GetItemElementName:function(element){var name="";if(_aspxIsExists(element.id))
name=element.id.substring(this.name.length+1);return name;},GetLinkElement:function(element){if(element==null)return null;return(element.tagName=="A")?element:_aspxGetChildByTagName(element,"A",0);},GetMainElement:function(){if(!_aspxIsExistsElement(this.mainElement))
this.mainElement=_aspxGetElementById(this.name);return this.mainElement;},IsRightToLeft:function(){return _aspxIsElementRigthToLeft(this.GetMainElement());},OnControlClick:function(clickedElement,htmlEvent){},GetLoadingPanelElement:function(){return _aspxGetElementById(this.name+"_LP");},CloneLoadingPanel:function(element,parent){var clone=element.cloneNode(true);clone.id=element.id+"V";parent.appendChild(clone);return clone;},CreateLoadingPanelInsideContainer:function(parentElement){if(parentElement==null)
return null;var element=this.GetLoadingPanelElement();if(element!=null){var width=0;var height=0;var itemsTable=_aspxGetChildByTagName(parentElement,"TABLE",0);if(itemsTable!=null){width=itemsTable.offsetWidth;height=itemsTable.offsetHeight;}else if(parentElement.childNodes.length==0){var dummyDiv=document.createElement("DIV");parentElement.appendChild(dummyDiv);width=dummyDiv.offsetWidth;}else{width=parentElement.clientWidth;height=parentElement.clientHeight;}
parentElement.innerHTML="";var table=document.createElement("TABLE");parentElement.appendChild(table);table.border=0;table.cellPadding=0;table.cellSpacing=0;table.style.height=(height>0)?height+"px":"100%";table.style.width=(width>0)?width+"px":"100%";var tbody=document.createElement("TBODY");table.appendChild(tbody);var tr=document.createElement("TR");tbody.appendChild(tr);var td=document.createElement("TD");tr.appendChild(td);td.align="center";td.vAlign="middle";element=this.CloneLoadingPanel(element,td);_aspxSetElementDisplay(element,true);this.loadingPanelElement=element;return element;}else
parentElement.innerHTML="&nbsp;";return null;},CreateLoadingPanelWithAbsolutePosition:function(parentElement,offsetElement){if(parentElement==null)
return null;if(!_aspxIsExists(offsetElement))
offsetElement=parentElement;var element=this.GetLoadingPanelElement();if(element!=null){element=this.CloneLoadingPanel(element,parentElement);element.style.position="absolute";_aspxSetElementDisplay(element,true);this.SetLoadingPanelLocation(offsetElement,element);this.loadingPanelElement=element;return element;}
return null;},CreateLoadingPanelInline:function(parentElement){if(parentElement==null)
return null;var element=this.GetLoadingPanelElement();if(element!=null){element=this.CloneLoadingPanel(element,parentElement);_aspxSetElementDisplay(element,true);this.loadingPanelElement=element;return element;}
return null;},HideLoadingPanel:function(){if(_aspxIsExistsElement(this.loadingPanelElement)){_aspxRemoveElement(this.loadingPanelElement);this.loadingPanelElement=null;}},SetLoadingPanelLocation:function(offsetElement,loadingPanel,x,y,offsetX,offsetY){if(!_aspxIsExists(x)||!_aspxIsExists(y)){var x1=_aspxGetAbsoluteX(offsetElement)-_aspxGetIEDocumentClientOffset(true);var y1=_aspxGetAbsoluteY(offsetElement)-_aspxGetIEDocumentClientOffset(false);var x2=x1;var y2=y1;if(offsetElement==document.body){x2+=_aspxGetDocumentMaxClientWidth();y2+=_aspxGetDocumentMaxClientHeight();}
else{x2+=offsetElement.offsetWidth;y2+=offsetElement.offsetHeight;}
if(x1<_aspxGetDocumentScrollLeft())
x1=_aspxGetDocumentScrollLeft();if(y1<_aspxGetDocumentScrollTop())
y1=_aspxGetDocumentScrollTop();if(x2>_aspxGetDocumentScrollLeft()+_aspxGetDocumentClientWidth())
x2=_aspxGetDocumentScrollLeft()+_aspxGetDocumentClientWidth();if(y2>_aspxGetDocumentScrollTop()+_aspxGetDocumentClientHeight())
y2=_aspxGetDocumentScrollTop()+_aspxGetDocumentClientHeight();x=x1+((x2-x1-loadingPanel.offsetWidth)/2);y=y1+((y2-y1-loadingPanel.offsetHeight)/2);}
if(_aspxIsExists(offsetX)&&_aspxIsExists(offsetY)){x+=offsetX;y+=offsetY;}
loadingPanel.style.left=_aspxPrepareClientPosForElement(x,loadingPanel,true)+"px";loadingPanel.style.top=_aspxPrepareClientPosForElement(y,loadingPanel,false)+"px";},GetLoadingDiv:function(){return _aspxGetElementById(this.name+"_LD");},CreateLoadingDiv:function(parentElement,offsetElement){if(parentElement==null)return null;if(!_aspxIsExists(offsetElement))
offsetElement=parentElement;var div=this.GetLoadingDiv();if(div!=null){div=div.cloneNode(true);parentElement.appendChild(div);_aspxSetElementDisplay(div,true);this.SetLoadingDivBounds(offsetElement,div);this.loadingDivElement=div;return div;}
return null;},SetLoadingDivBounds:function(offsetElement,loadingDiv){var absX=(offsetElement==document.body)?0:_aspxGetAbsoluteX(offsetElement);var absY=(offsetElement==document.body)?0:_aspxGetAbsoluteY(offsetElement);loadingDiv.style.left=_aspxPrepareClientPosForElement(absX,loadingDiv,true)+"px";loadingDiv.style.top=_aspxPrepareClientPosForElement(absY,loadingDiv,false)+"px";if(__aspxNS)_aspxSetStyleSize(loadingDiv,1,1);var width=(offsetElement==document.body)?_aspxGetDocumentWidth():offsetElement.offsetWidth;var height=(offsetElement==document.body)?_aspxGetDocumentHeight():offsetElement.offsetHeight;_aspxSetStyleSize(loadingDiv,width,height);},HideLoadingDiv:function(){if(_aspxIsExistsElement(this.loadingDivElement)){_aspxRemoveElement(this.loadingDivElement);this.loadingDivElement=null;}},RaiseInit:function(){if(!this.Init.IsEmpty()){var args=new ASPxClientEventArgs();this.Init.FireEvent(this,args);}},RaiseBeginCallback:function(command){if(!this.BeginCallback.IsEmpty()){var args=new ASPxClientBeginCallbackEventArgs(command);this.BeginCallback.FireEvent(this,args);}
if(_aspxIsExistsType(typeof(aspxGetGlobalEvents)))
aspxGetGlobalEvents().OnBeginCallback(this,command);},RaiseEndCallback:function(){if(!this.EndCallback.IsEmpty()){var args=new ASPxClientEndCallbackEventArgs();this.EndCallback.FireEvent(this,args);}
if(_aspxIsExistsType(typeof(aspxGetGlobalEvents)))
aspxGetGlobalEvents().OnEndCallback(this);},RaiseCallbackError:function(message){if(!this.CallbackError.IsEmpty()){var args=new ASPxClientCallbackErrorEventArgs(message);this.CallbackError.FireEvent(this,args);if(args.handled)
return{isHandled:true,errorMessage:args.message};}
if(_aspxIsExistsType(typeof(aspxGetGlobalEvents))){var args=new ASPxClientCallbackErrorEventArgs(message);aspxGetGlobalEvents().OnCallbackError(this,args);if(args.handled)
return{isHandled:true,errorMessage:args.message};}
return{isHandled:false,errorMessage:message};},IsVisible:function(){var element=this.GetMainElement();while(_aspxIsExists(element)&&element.tagName!="BODY"){if(!_aspxGetElementVisibility(element)||!_aspxGetElementDisplay(element))
return false;element=element.parentNode;}
return true;},IsDisplayed:function(){var element=this.GetMainElement();while(_aspxIsExists(element)&&element.tagName!="BODY"){if(!_aspxGetElementDisplay(element))
return false;element=element.parentNode;}
return true;},Focus:function(){},GetClientVisible:function(){return this.GetVisible();},SetClientVisible:function(visible){this.SetVisible(visible);},GetVisible:function(){return this.clientVisible;},SetVisible:function(visible){if(this.clientVisible!=visible){this.clientVisible=visible;_aspxSetElementDisplay(this.GetMainElement(),visible);if(visible){this.AdjustControl(__aspxCheckSizeCorrectedFlag);var mainElement=this.GetMainElement();if(_aspxIsExists(mainElement))
aspxGetControlCollection().AdjustControls(mainElement,__aspxCheckSizeCorrectedFlag);}}},InCallback:function(){return this.requestCount>0;},DoBeginCallback:function(command){if(!_aspxIsExists(command))command="";this.RaiseBeginCallback(command);aspxGetControlCollection().Before_WebForm_InitCallback();if(_aspxIsExistsType(typeof(WebForm_InitCallback))&&_aspxIsExists(WebForm_InitCallback)){__theFormPostData="";__theFormPostCollection=new Array();this.ClearPostBackEventInput("__EVENTTARGET");this.ClearPostBackEventInput("__EVENTARGUMENT");WebForm_InitCallback();this.savedFormPostData=__theFormPostData;this.savedFormPostCollection=__theFormPostCollection;}},ClearPostBackEventInput:function(id){var element=_aspxGetElementById(id);if(element!=null)element.value="";},CreateCallback:function(arg,command){if(!this.isInitialized){if(!_aspxIsExists(this.savedCallbacks))
this.savedCallbacks=[];this.savedCallbacks.push([arg,command]);}
else
this.CreateCallbackInternal(arg,command,true);},CreateCallbackInternal:function(arg,command,viaTimer){if(!this.CanCreateCallback())
return;this.requestCount++;this.DoBeginCallback(command);if(typeof(arg)=="undefined")
arg="";if(typeof(command)=="undefined")
command="";if(viaTimer)
window.setTimeout("aspxCreateCallback('"+this.name+"', '"+escape(arg)+"', '"+escape(command)+"');",0);else
this.CreateCallbackCore(arg,command);},CreateCallbackCore:function(arg,command){__theFormPostData=this.savedFormPostData;__theFormPostCollection=this.savedFormPostCollection;this.callBack(arg);},CanCreateCallback:function(){return this.allowMultipleCallbacks||!this.InCallback();},DoLoadCallbackScripts:function(){_aspxProcessScripts(this.name);_aspxSweepDuplicatedLinks();_aspxMoveLinkElements();__aspxCachedRules={};},DoEndCallback:function(){this.RaiseEndCallback();},DoFinalizeCallback:function(){},HideLoadingPanelOnCallback:function(){return true;},DoCallback:function(result){this.requestCount--;if(this.HideLoadingPanelOnCallback()){this.HideLoadingDiv();this.HideLoadingPanel();}
if(result.indexOf(__aspxCallbackResultPrefix)!=0)
this.ProcessCallbackGeneralError(result);else{try{var resultObj=eval(result);if(_aspxIsExists(resultObj.redirect))
window.location.href=resultObj.redirect;else if(_aspxIsExists(resultObj.generalError))
this.ProcessCallbackGeneralError(resultObj.generalError);else{var errorObj=resultObj.error;if(_aspxIsExists(errorObj))
this.ProcessCallbackError(errorObj);else{if(resultObj.cp){for(var name in resultObj.cp)
this[name]=resultObj.cp[name];}
this.ProcessCallback(resultObj.result);}
this.DoLoadCallbackScripts();}}catch(e){this.ProcessCallbackGeneralError(e.message);}}},DoCallbackError:function(result){this.HideLoadingDiv();this.HideLoadingPanel();this.OnCallbackGeneralError(result);},DoControlClick:function(evt){this.OnControlClick(_aspxGetEventSource(evt),evt);},ProcessCallback:function(result){this.OnCallback(result);},OnCallback:function(result){},ProcessCallbackError:function(errorObj){var data=_aspxIsExists(errorObj.data)?errorObj.data:null;var result=this.RaiseCallbackError(errorObj.message);if(!result.isHandled)
this.OnCallbackError(result.errorMessage,data);},OnCallbackError:function(errorMessage,data){if(errorMessage)
alert(errorMessage);},ProcessCallbackGeneralError:function(errorMessage){var result=this.RaiseCallbackError(errorMessage);if(!result.isHandled)
this.OnCallbackGeneralError(result.errorMessage);},OnCallbackGeneralError:function(errorMessage){this.OnCallbackError(errorMessage,null);},SendPostBack:function(params){__doPostBack(this.uniqueID,params);}});ASPxIdent={};ASPxIdent.IsDate=function(obj){return _aspxIsExists(obj)&&obj.constructor==Date;};ASPxIdent.IsRegExp=function(obj){return _aspxIsExists(obj)&&obj.constructor===RegExp;};ASPxIdent.IsArray=function(obj){return _aspxIsExists(obj)&&obj.constructor==Array;}
ASPxIdent.IsASPxClientControl=function(obj){return _aspxIsExists(obj.isASPxClientControl)&&obj.isASPxClientControl;};ASPxIdent.IsASPxClientEdit=function(obj){return _aspxIsExists(obj.isASPxClientEdit)&&obj.isASPxClientEdit;};ASPxClientControl.GetControlCollection=function(){return aspxGetControlCollection();}
var __aspxControlCollection=null;function aspxGetControlCollection(){if(__aspxControlCollection==null)
__aspxControlCollection=new ASPxClientControlCollection();return __aspxControlCollection;}
function aspxCAInit(){aspxGetControlCollection().AtlasInitialize();}
function aspxCreateCallback(name,arg,command){var control=aspxGetControlCollection().Get(name);if(control!=null)
control.CreateCallbackCore(unescape(arg),unescape(command));}
function aspxCallback(result,context){var collection=aspxGetControlCollection();collection.DoFinalizeCallback();var control=collection.Get(context);if(control!=null)
control.DoCallback(result);}
function aspxCallbackError(result,context){var control=aspxGetControlCollection().Get(context);if(control!=null)
control.DoCallbackError(result,false);}
function aspxCClick(name,evt){var control=aspxGetControlCollection().Get(name);if(control!=null)control.DoControlClick(evt);}
var __aspxStateItemsExist=false;var __aspxHoverStyleSheet=null;var __aspxPressedStyleSheet=null;var __aspxSelectedStyleSheet=null;var __aspxDisabledStyleSheet=null;var __aspxFocusedItemKind="FocusedStateItem";var __aspxHoverItemKind="HoverStateItem";var __aspxPressedItemKind="PressedStateItem";var __aspxSelectedItemKind="SelectedStateItem";var __aspxDisabledItemKind="DisabledStateItem";var __aspxStyleCount=0;var __aspxStyleNameCache=new Object();ASPxStateItem=_aspxCreateClass(null,{constructor:function(name,className,cssText,postfixes,imageUrls,imagePostfixes,kind){this.name=name;this.className=className;this.customClassName="";this.resultClassName="";this.cssText=cssText;this.postfixes=postfixes;this.imageUrls=imageUrls;this.imagePostfixes=imagePostfixes;this.kind=kind;this.enabled=true;this.elements=null;this.images=null;this.linkColor=null;this.lintTextDecoration=null;},CreateStyleRule:function(){if(this.cssText=="")return"";var styleSheet=this.GetStyleSheet();if(_aspxIsExists(styleSheet)){if(_aspxIsExists(__aspxStyleNameCache[this.cssText]))
return __aspxStyleNameCache[this.cssText];else{var cssText="";var attributes=this.cssText.split(";");for(var i=0;i<attributes.length;i++){if(attributes[i]!="")
cssText+=attributes[i]+" !important;";}
var className="dxh"+__aspxStyleCount;_aspxAddStyleSheetRule(styleSheet,"."+className,cssText);__aspxStyleCount++;__aspxStyleNameCache[this.cssText]=className;return className;}}
return"";},GetResultClassName:function(){if(this.resultClassName==""){if(this.customClassName=="")
this.customClassName=this.CreateStyleRule();if(this.className!=""&&this.customClassName!="")
this.resultClassName=this.className+" "+this.customClassName;else if(this.className!="")
this.resultClassName=this.className;else if(this.customClassName!="")
this.resultClassName=this.customClassName;}
return this.resultClassName;},GetStyleSheet:function(){if(!_aspxIsExists(__aspxDisabledStyleSheet))
__aspxDisabledStyleSheet=_aspxCreateStyleSheet();if(!_aspxIsExists(__aspxSelectedStyleSheet))
__aspxSelectedStyleSheet=_aspxCreateStyleSheet();if(!_aspxIsExists(__aspxHoverStyleSheet))
__aspxHoverStyleSheet=_aspxCreateStyleSheet();if(!_aspxIsExists(__aspxPressedStyleSheet))
__aspxPressedStyleSheet=_aspxCreateStyleSheet();switch(this.kind){case __aspxDisabledItemKind:return __aspxDisabledStyleSheet;case __aspxHoverItemKind:return __aspxHoverStyleSheet;case __aspxPressedItemKind:return __aspxPressedStyleSheet;case __aspxSelectedItemKind:return __aspxSelectedStyleSheet;}
return null;},GetElements:function(element){if(!_aspxIsExists(this.elements)||!_aspxIsValidElements(this.elements)){if(_aspxIsExists(this.postfixes)&&this.postfixes.length>0){this.elements=new Array();var parentNode=element.parentNode;if(_aspxIsExists(parentNode)){for(var i=0;i<this.postfixes.length;i++){var id=this.name+this.postfixes[i];this.elements[i]=_aspxGetChildById(parentNode,id);if(!_aspxIsExists(this.elements[i]))
this.elements[i]=_aspxGetElementById(id);}}}
else
this.elements=[element];}
return this.elements;},GetImages:function(element){if(!_aspxIsExists(this.images)||!_aspxIsValidElements(this.images)){this.images=new Array();if(_aspxIsExists(this.imagePostfixes)&&this.imagePostfixes.length>0){var elements=this.GetElements(element);for(var i=0;i<this.imagePostfixes.length;i++){var id=this.name+this.imagePostfixes[i];for(var j=0;j<elements.length;j++){if(!_aspxIsExists(elements[j]))continue;this.images[i]=_aspxGetChildById(elements[j],id);if(_aspxIsExists(this.images[i]))
break;}}}}
return this.images;},Apply:function(element){if(!this.enabled)return;try{this.ApplyStyle(element);if(_aspxIsExists(this.imageUrls)&&this.imageUrls.length>0)
this.ApplyImage(element);}
catch(e){}},ApplyStyle:function(element){var elements=this.GetElements(element);for(var i=0;i<elements.length;i++){if(!_aspxIsExists(elements[i]))continue;var className=elements[i].className.replace(this.GetResultClassName(),"");elements[i].className=_aspxTrim(className)+" "+this.GetResultClassName();if(!__aspxOpera||__aspxOpera9)
this.ApplyStyleToLinks(elements,i);}},ApplyStyleToLinks:function(elements,index){var linkCount=0;var savedLinkCount=-1;if(_aspxIsExists(elements[index]["savedLinkCount"]))
savedLinkCount=parseInt(elements[index]["savedLinkCount"]);do{if(savedLinkCount>-1&&savedLinkCount<=linkCount)
break;var link=elements[index]["link"+linkCount];if(!_aspxIsExists(link)){link=_aspxGetChildByTagName(elements[index],"A",linkCount);if(!_aspxIsExists(link))
link=_aspxGetChildByTagName(elements[index],"SPAN",linkCount);if(_aspxIsExists(link))
elements[index]["link"+linkCount]=link;}
if(_aspxIsExists(link))
this.ApplyStyleToLinkElement(link);else
elements[index]["savedLinkCount"]=linkCount;linkCount++;}
while(link!=null)},ApplyStyleToLinkElement:function(link){if(this.GetLinkColor()!="")
_aspxChangeAttributeExtended(link.style,"color",link,"saved"+this.kind+"Color",this.GetLinkColor());if(this.GetLinkTextDecoration()!="")
_aspxChangeAttributeExtended(link.style,"textDecoration",link,"saved"+this.kind+"TextDecoration",this.GetLinkTextDecoration());},ApplyImage:function(element){var images=this.GetImages(element);for(var i=0;i<images.length;i++){if(!_aspxIsExists(images[i])||!_aspxIsExists(this.imageUrls[i])||this.imageUrls[i]=="")continue;if(_aspxIsAlphaFilterUsed(images[i]))
_aspxChangeAttributeExtended(images[i].style,"filter",images[i],"saved"+this.kind+"Filter","progid:DXImageTransform.Microsoft.AlphaImageLoader(src="+this.imageUrls[i]+", sizingMethod=scale)");else
_aspxChangeAttributeExtended(images[i],"src",images[i],"saved"+this.kind+"Src",this.imageUrls[i]);}},Cancel:function(element){if(!this.enabled)return;try{this.CancelStyle(element);if(_aspxIsExists(this.imageUrls)&&this.imageUrls.length>0)
this.CancelImage(element);}
catch(e){}},CancelStyle:function(element){var elements=this.GetElements(element);for(var i=0;i<elements.length;i++){if(!_aspxIsExists(elements[i]))continue;var className=_aspxTrim(elements[i].className.replace(this.GetResultClassName(),""));elements[i].className=className;if(!__aspxOpera||__aspxOpera9)
this.CancelStyleFromLinks(elements,i);}},CancelStyleFromLinks:function(elements,index){var linkCount=0;var savedLinkCount=-1;if(_aspxIsExists(elements[index]["savedLinkCount"]))
savedLinkCount=parseInt(elements[index]["savedLinkCount"]);do{if(savedLinkCount>-1&&savedLinkCount<=linkCount)
break;var link=elements[index]["link"+linkCount];if(!_aspxIsExists(link)){link=_aspxGetChildByTagName(elements[index],"A",linkCount);if(!_aspxIsExists(link))
link=_aspxGetChildByTagName(elements[index],"SPAN",linkCount);if(_aspxIsExists(link))
elements[index]["link"+linkCount]=link;}
if(_aspxIsExists(link))
this.CancelStyleFromLinkElement(link);else
elements[index]["savedLinkCount"]=linkCount;linkCount++;}
while(link!=null)},CancelStyleFromLinkElement:function(link){if(this.GetLinkColor()!="")
_aspxRestoreAttributeExtended(link.style,"color",link,"saved"+this.kind+"Color");if(this.GetLinkTextDecoration()!="")
_aspxRestoreAttributeExtended(link.style,"textDecoration",link,"saved"+this.kind+"TextDecoration");},CancelImage:function(element){var images=this.GetImages(element);for(var i=0;i<images.length;i++){if(!_aspxIsExists(images[i])||!_aspxIsExists(this.imageUrls[i])||this.imageUrls[i]=="")continue;if(_aspxIsAlphaFilterUsed(images[i]))
_aspxRestoreAttributeExtended(images[i].style,"filter",images[i],"saved"+this.kind+"Filter");else
_aspxRestoreAttributeExtended(images[i],"src",images[i],"saved"+this.kind+"Src");}},Clone:function(){return new ASPxStateItem(this.name,this.className,this.cssText,this.postfixes,this.imageUrls,this.imagePostfixes,this.kind);},IsChildElement:function(element){if(element!=null){var elements=this.GetElements(element);for(var i=0;i<elements.length;i++){if(!_aspxIsExists(elements[i]))continue;if(_aspxGetIsParent(elements[i],element))
return true;}}
return false;},GetLinkColor:function(){if(!_aspxIsExists(this.linkColor)){var rule=_aspxGetStyleSheetRule(this.customClassName);this.linkColor=_aspxIsExists(rule)?rule.style.color:null;if(!_aspxIsExists(this.linkColor)){var rule=_aspxGetStyleSheetRule(this.className);this.linkColor=_aspxIsExists(rule)?rule.style.color:null;}
if(this.linkColor==null)
this.linkColor="";}
return this.linkColor;},GetLinkTextDecoration:function(){if(!_aspxIsExists(this.linkTextDecoration)){var rule=_aspxGetStyleSheetRule(this.customClassName);this.linkTextDecoration=_aspxIsExists(rule)?rule.style.textDecoration:null;if(!_aspxIsExists(this.linkTextDecoration)){var rule=_aspxGetStyleSheetRule(this.className);this.linkTextDecoration=_aspxIsExists(rule)?rule.style.textDecoration:null;}
if(this.linkTextDecoration==null)
this.linkTextDecoration="";}
return this.linkTextDecoration;}});ASPxClientStateEventArgs=_aspxCreateClass(null,{constructor:function(item,element){this.item=item;this.element=element;this.toElement=null;this.fromElement=null;this.htmlEvent=null;}});ASPxStateController=_aspxCreateClass(null,{constructor:function(){this.focusedItems=new Object();this.hoverItems=new Object();this.pressedItems=new Object();this.selectedItems=new Object();this.disabledItems=new Object();this.currentFocusedElement=null;this.currentFocusedItemName=null;this.currentHoverElement=null;this.currentHoverItemName=null;this.currentPressedElement=null;this.currentPressedItemName=null;this.savedCurrentPressedElement=null;this.savedCurrentMouseMoveSrcElement=null;this.AfterSetFocusedState=new ASPxClientEvent();this.AfterClearFocusedState=new ASPxClientEvent();this.AfterSetHoverState=new ASPxClientEvent();this.AfterClearHoverState=new ASPxClientEvent();this.AfterSetPressedState=new ASPxClientEvent();this.AfterClearPressedState=new ASPxClientEvent();this.AfterDisabled=new ASPxClientEvent();this.AfterEnabled=new ASPxClientEvent();this.BeforeSetFocusedState=new ASPxClientEvent();this.BeforeClearFocusedState=new ASPxClientEvent();this.BeforeSetHoverState=new ASPxClientEvent();this.BeforeClearHoverState=new ASPxClientEvent();this.BeforeSetPressedState=new ASPxClientEvent();this.BeforeClearPressedState=new ASPxClientEvent();this.BeforeDisabled=new ASPxClientEvent();this.BeforeEnabled=new ASPxClientEvent();this.FocusedItemKeyDown=new ASPxClientEvent();},AddHoverItem:function(name,className,cssText,postfixes,imageUrls,imagePostfixes){this.AddItem(this.hoverItems,name,className,cssText,postfixes,imageUrls,imagePostfixes,__aspxHoverItemKind);this.AddItem(this.focusedItems,name,className,cssText,postfixes,imageUrls,imagePostfixes,__aspxFocusedItemKind);},AddPressedItem:function(name,className,cssText,postfixes,imageUrls,imagePostfixes){this.AddItem(this.pressedItems,name,className,cssText,postfixes,imageUrls,imagePostfixes,__aspxPressedItemKind);},AddSelectedItem:function(name,className,cssText,postfixes,imageUrls,imagePostfixes){this.AddItem(this.selectedItems,name,className,cssText,postfixes,imageUrls,imagePostfixes,__aspxSelectedItemKind);},AddDisabledItem:function(name,className,cssText,postfixes,imageUrls,imagePostfixes){this.AddItem(this.disabledItems,name,className,cssText,postfixes,imageUrls,imagePostfixes,__aspxDisabledItemKind);},AddItem:function(items,name,className,cssText,postfixes,imageUrls,imagePostfixes,kind){var stateItem=new ASPxStateItem(name,className,cssText,postfixes,imageUrls,imagePostfixes,kind);if(_aspxIsExists(postfixes)&&postfixes.length>0){for(var i=0;i<postfixes.length;i++){items[name+postfixes[i]]=stateItem;}}
else
items[name]=stateItem;__aspxStateItemsExist=true;},GetFocusedElement:function(srcElement){return this.GetItemElement(srcElement,this.focusedItems,__aspxFocusedItemKind);},GetHoverElement:function(srcElement){return this.GetItemElement(srcElement,this.hoverItems,__aspxHoverItemKind);},GetPressedElement:function(srcElement){return this.GetItemElement(srcElement,this.pressedItems,__aspxPressedItemKind);},GetSelectedElement:function(srcElement){return this.GetItemElement(srcElement,this.selectedItems,__aspxSelectedItemKind);},GetDisabledElement:function(srcElement){return this.GetItemElement(srcElement,this.disabledItems,__aspxDisabledItemKind);},GetItemElement:function(srcElement,items,kind){if(_aspxIsExists(srcElement)&&_aspxIsExists(srcElement["cached"+kind])){var cachedElement=srcElement["cached"+kind];if(cachedElement!=__aspxEmptyCachedValue)
return cachedElement;return null;}
var element=srcElement;while(element!=null){var item=items[element.id];if(_aspxIsExists(item)){this.CacheItemElement(srcElement,kind,element);element[kind]=item;return element;}
element=element.parentNode;}
this.CacheItemElement(srcElement,kind,__aspxEmptyCachedValue);return null;},CacheItemElement:function(srcElement,kind,value){if(_aspxIsExists(srcElement)&&!_aspxIsExists(srcElement["cached"+kind]))
srcElement["cached"+kind]=value;},DoSetFocusedState:function(element,fromElement){var item=element[__aspxFocusedItemKind];if(_aspxIsExists(item)){var args=new ASPxClientStateEventArgs(item,element);args.fromElement=fromElement;this.BeforeSetFocusedState.FireEvent(this,args);item.Apply(element);this.AfterSetFocusedState.FireEvent(this,args);}},DoClearFocusedState:function(element,toElement){var item=element[__aspxFocusedItemKind];if(_aspxIsExists(item)){var args=new ASPxClientStateEventArgs(item,element);args.toElement=toElement;this.BeforeClearFocusedState.FireEvent(this,args);item.Cancel(element);this.AfterClearFocusedState.FireEvent(this,args);}},DoSetHoverState:function(element,fromElement){var item=element[__aspxHoverItemKind];if(_aspxIsExists(item)){var args=new ASPxClientStateEventArgs(item,element);args.fromElement=fromElement;this.BeforeSetHoverState.FireEvent(this,args);item.Apply(element);this.AfterSetHoverState.FireEvent(this,args);}},DoClearHoverState:function(element,toElement){var item=element[__aspxHoverItemKind];if(_aspxIsExists(item)){var args=new ASPxClientStateEventArgs(item,element);args.toElement=toElement;this.BeforeClearHoverState.FireEvent(this,args);item.Cancel(element);this.AfterClearHoverState.FireEvent(this,args);}},DoSetPressedState:function(element){var item=element[__aspxPressedItemKind];if(_aspxIsExists(item)){var args=new ASPxClientStateEventArgs(item,element);this.BeforeSetPressedState.FireEvent(this,args);item.Apply(element);this.AfterSetPressedState.FireEvent(this,args);}},DoClearPressedState:function(element){var item=element[__aspxPressedItemKind];if(_aspxIsExists(item)){var args=new ASPxClientStateEventArgs(item,element);this.BeforeClearPressedState.FireEvent(this,args);item.Cancel(element);this.AfterClearPressedState.FireEvent(this,args);}},SetCurrentFocusedElement:function(element){if(_aspxIsExists(this.currentFocusedElement)&&!_aspxIsValidElement(this.currentFocusedElement)){this.currentFocusedElement=null;this.currentFocusedItemName="";}
if(this.currentFocusedElement!=element){var oldCurrentFocusedElement=this.currentFocusedElement;var item=(element!=null)?element[__aspxFocusedItemKind]:null;var itemName=(item!=null)?item.name:"";if(this.currentFocusedItemName!=itemName){if(this.currentHoverItemName!="")
this.SetCurrentHoverElement(null);if(this.currentFocusedElement!=null)
this.DoClearFocusedState(this.currentFocusedElement,element);this.currentFocusedElement=element;item=(element!=null)?element[__aspxFocusedItemKind]:null;this.currentFocusedItemName=(item!=null)?item.name:"";if(this.currentFocusedElement!=null)
this.DoSetFocusedState(this.currentFocusedElement,oldCurrentFocusedElement);}}},SetCurrentHoverElement:function(element){if(_aspxIsExists(this.currentHoverElement)&&!_aspxIsValidElement(this.currentHoverElement)){this.currentHoverElement=null;this.currentHoverItemName="";}
if(this.currentHoverElement!=element){var oldCurrentHoverElement=this.currentHoverElement;var item=(element!=null)?element[__aspxHoverItemKind]:null;var itemName=(item!=null)?item.name:"";if(this.currentHoverItemName!=itemName){if(this.currentFocusedItemName!="")
this.SetCurrentFocusedElement(null);if(this.currentHoverElement!=null)
this.DoClearHoverState(this.currentHoverElement,element);this.currentHoverElement=element;item=(element!=null)?element[__aspxHoverItemKind]:null;this.currentHoverItemName=(item!=null)?item.name:"";if(this.currentHoverElement!=null)
this.DoSetHoverState(this.currentHoverElement,oldCurrentHoverElement);}}},SetCurrentPressedElement:function(element){if(_aspxIsExists(this.currentPressedElement)&&!_aspxIsValidElement(this.currentPressedElement)){this.currentPressedElement=null;this.currentPressedItemName="";}
if(this.currentPressedElement!=element){if(this.currentPressedElement!=null)
this.DoClearPressedState(this.currentPressedElement);this.currentPressedElement=element;var item=(element!=null)?element[__aspxPressedItemKind]:null;this.currentPressedItemName=(item!=null)?item.name:"";if(this.currentPressedElement!=null)
this.DoSetPressedState(this.currentPressedElement);}},SetCurrentFocusedElementBySrcElement:function(srcElement){var element=this.GetFocusedElement(srcElement);this.SetCurrentFocusedElement(element);},SetCurrentHoverElementBySrcElement:function(srcElement){var element=this.GetHoverElement(srcElement);this.SetCurrentHoverElement(element);},SetCurrentPressedElementBySrcElement:function(srcElement){var element=this.GetPressedElement(srcElement);this.SetCurrentPressedElement(element);},SelectElement:function(element){var item=element[__aspxSelectedItemKind];if(_aspxIsExists(item))
item.Apply(element);},SelectElementBySrcElement:function(srcElement){var element=this.GetSelectedElement(srcElement);if(element!=null)this.SelectElement(element);},DeselectElement:function(element){var item=element[__aspxSelectedItemKind];if(_aspxIsExists(item))
item.Cancel(element);},DeselectElementBySrcElement:function(srcElement){var element=this.GetSelectedElement(srcElement);if(element!=null)this.DeselectElement(element);},SetElementEnabled:function(element,enable){if(enable)
this.EnableElement(element);else
this.DisableElement(element);},DisableElement:function(element){var element=this.GetDisabledElement(element);if(element!=null){var item=element[__aspxDisabledItemKind];if(_aspxIsExists(item)){var args=new ASPxClientStateEventArgs(item,element);this.BeforeDisabled.FireEvent(this,args);if(item.name==this.currentPressedItemName)
this.SetCurrentPressedElement(null);if(item.name==this.currentHoverItemName)
this.SetCurrentHoverElement(null);item.Apply(element);this.SetMouseStateItemsEnabled(item.name,item.postfixes,false);this.AfterDisabled.FireEvent(this,args);}}},EnableElement:function(element){var element=this.GetDisabledElement(element);if(element!=null){var item=element[__aspxDisabledItemKind];if(_aspxIsExists(item)){var args=new ASPxClientStateEventArgs(item,element);this.BeforeEnabled.FireEvent(this,args);item.Cancel(element);this.SetMouseStateItemsEnabled(item.name,item.postfixes,true);this.AfterEnabled.FireEvent(this,args);}}},SetMouseStateItemsEnabled:function(name,postfixes,enabled){if(_aspxIsExists(postfixes)&&postfixes.length>0){for(var i=0;i<postfixes.length;i++){this.SetItemsEnabled(this.hoverItems,name+postfixes[i],enabled);this.SetItemsEnabled(this.pressedItems,name+postfixes[i],enabled);}}
else{this.SetItemsEnabled(this.hoverItems,name,enabled);this.SetItemsEnabled(this.pressedItems,name,enabled);}},SetItemsEnabled:function(items,name,enabled){if(_aspxIsExists(items[name]))items[name].enabled=enabled;},OnFocusMove:function(evt){var element=_aspxGetEventSource(evt);aspxGetStateController().SetCurrentFocusedElementBySrcElement(element);},OnMouseMove:function(evt,checkElementChanged){var srcElement=_aspxGetEventSource(evt);if(checkElementChanged&&srcElement==this.savedCurrentMouseMoveSrcElement)return;this.savedCurrentMouseMoveSrcElement=srcElement;if(__aspxIE&&!_aspxGetIsLeftButtonPressed(evt)&&this.savedCurrentPressedElement!=null){this.savedCurrentPressedElement=null;this.SetCurrentPressedElement(null);}
if(this.savedCurrentPressedElement==null)
this.SetCurrentHoverElementBySrcElement(srcElement);else{var element=this.GetPressedElement(srcElement);if(element!=this.currentPressedElement){if(element==this.savedCurrentPressedElement)
this.SetCurrentPressedElement(this.savedCurrentPressedElement);else
this.SetCurrentPressedElement(null);}}},OnMouseDown:function(evt){if(!_aspxGetIsLeftButtonPressed(evt))return;var srcElement=_aspxGetEventSource(evt);this.OnMouseDownOnElement(srcElement);},OnMouseDownOnElement:function(element){if(this.GetPressedElement(element)==null)return;this.SetCurrentHoverElement(null);this.SetCurrentPressedElementBySrcElement(element);this.savedCurrentPressedElement=this.currentPressedElement;},OnMouseUp:function(evt){var srcElement=_aspxGetEventSource(evt);this.OnMouseUpOnElement(srcElement);},OnMouseUpOnElement:function(element){if(this.savedCurrentPressedElement==null)return;this.savedCurrentPressedElement=null;this.SetCurrentPressedElement(null);this.SetCurrentHoverElementBySrcElement(element);},OnMouseOver:function(evt){var element=_aspxGetEventSource(evt);if(_aspxIsExists(element)&&element.tagName=="IFRAME")
this.OnMouseMove(evt,true);},OnKeyDown:function(evt){var element=this.GetFocusedElement(_aspxGetEventSource(evt));if(element!=null&&element==this.currentFocusedElement){var item=element[__aspxFocusedItemKind];if(_aspxIsExists(item)){var args=new ASPxClientStateEventArgs(item,element);args.htmlEvent=evt;this.FocusedItemKeyDown.FireEvent(this,args);}}},OnSelectStart:function(evt){if((this.savedCurrentPressedElement!=null)&&(!_aspxIsExists(this.savedCurrentPressedElement.needClearSelection))){_aspxClearSelection();return false;}}});var __aspxStateController=null;function aspxGetStateController(){if(__aspxStateController==null)
__aspxStateController=new ASPxStateController();return __aspxStateController;}
function aspxAddStateItems(method,namePrefix,classes){for(var i=0;i<classes.length;i++){for(var j=0;j<classes[i][2].length;j++){var name=namePrefix;if(_aspxIsExists(classes[i][2][j])&&classes[i][2][j]!="")
name+="_"+classes[i][2][j];var postfixes=_aspxIsExists(classes[i][3])?classes[i][3]:null;var imageUrls=_aspxIsExists(classes[i][4])&&_aspxIsExists(classes[i][4][j])?classes[i][4][j]:null;var imagePostfixes=_aspxIsExists(classes[i][5])?classes[i][5]:null;method.call(aspxGetStateController(),name,classes[i][0],classes[i][1],postfixes,imageUrls,imagePostfixes);}}}
function aspxAddHoverItems(namePrefix,classes){aspxAddStateItems(aspxGetStateController().AddHoverItem,namePrefix,classes);}
function aspxAddPressedItems(namePrefix,classes){aspxAddStateItems(aspxGetStateController().AddPressedItem,namePrefix,classes);}
function aspxAddSelectedItems(namePrefix,classes){aspxAddStateItems(aspxGetStateController().AddSelectedItem,namePrefix,classes);}
function aspxAddDisabledItems(namePrefix,classes){aspxAddStateItems(aspxGetStateController().AddDisabledItem,namePrefix,classes);}
function aspxAddAfterClearFocusedState(handler){aspxGetStateController().AfterClearFocusedState.AddHandler(handler);}
function aspxAddAfterSetFocusedState(handler){aspxGetStateController().AfterSetFocusedState.AddHandler(handler);}
function aspxAddAfterClearHoverState(handler){aspxGetStateController().AfterClearHoverState.AddHandler(handler);}
function aspxAddAfterSetHoverState(handler){aspxGetStateController().AfterSetHoverState.AddHandler(handler);}
function aspxAddAfterClearPressedState(handler){aspxGetStateController().AfterClearPressedState.AddHandler(handler);}
function aspxAddAfterSetPressedState(handler){aspxGetStateController().AfterSetPressedState.AddHandler(handler);}
function aspxAddAfterDisabled(handler){aspxGetStateController().AfterDisabled.AddHandler(handler);}
function aspxAddAfterEnabled(handler){aspxGetStateController().AfterEnabled.AddHandler(handler);}
function aspxAddBeforeClearFocusedState(handler){aspxGetStateController().BeforeClearFocusedState.AddHandler(handler);}
function aspxAddBeforeSetFocusedState(handler){aspxGetStateController().BeforeSetFocusedState.AddHandler(handler);}
function aspxAddBeforeClearHoverState(handler){aspxGetStateController().BeforeClearHoverState.AddHandler(handler);}
function aspxAddBeforeSetHoverState(handler){aspxGetStateController().BeforeSetHoverState.AddHandler(handler);}
function aspxAddBeforeClearPressedState(handler){aspxGetStateController().BeforeClearPressedState.AddHandler(handler);}
function aspxAddBeforeSetPressedState(handler){aspxGetStateController().BeforeSetPressedState.AddHandler(handler);}
function aspxAddBeforeDisabled(handler){aspxGetStateController().BeforeDisabled.AddHandler(handler);}
function aspxAddBeforeEnabled(handler){aspxGetStateController().BeforeEnabled.AddHandler(handler);}
function aspxAddFocusedItemKeyDown(handler){aspxGetStateController().FocusedItemKeyDown.AddHandler(handler);}
function aspxSetHoverState(element){aspxGetStateController().SetCurrentHoverElementBySrcElement(element);}
function aspxClearHoverState(evt){aspxGetStateController().SetCurrentHoverElementBySrcElement(null);}
function aspxUpdateHoverState(evt){aspxGetStateController().OnMouseMove(evt,false);}
function aspxSetFocusedState(element){aspxGetStateController().SetCurrentFocusedElementBySrcElement(element);}
function aspxClearFocusedState(evt){aspxGetStateController().SetCurrentFocusedElementBySrcElement(null);}
function aspxUpdateFocusedState(evt){aspxGetStateController().OnFocusMove(evt);}
_aspxAttachEventToElement(window,"load",aspxClassesWindowOnLoad);function aspxClassesWindowOnLoad(evt){aspxGetControlCollection().Initialize();__aspxHTMLLoaded=true;_aspxInitializeScripts();_aspxInitializeLinks();}
_aspxAttachEventToDocument("mousemove",aspxClassesDocumentMouseMove);function aspxClassesDocumentMouseMove(evt){if(__aspxHTMLLoaded&&__aspxStateItemsExist)
aspxGetStateController().OnMouseMove(evt,true);}
_aspxAttachEventToDocument("mousedown",aspxClassesDocumentMouseDown);function aspxClassesDocumentMouseDown(evt){if(__aspxHTMLLoaded&&__aspxStateItemsExist)
aspxGetStateController().OnMouseDown(evt);}
_aspxAttachEventToDocument("mouseup",aspxClassesDocumentMouseUp);function aspxClassesDocumentMouseUp(evt){if(__aspxHTMLLoaded&&__aspxStateItemsExist)
aspxGetStateController().OnMouseUp(evt);}
_aspxAttachEventToDocument("mouseover",aspxClassesDocumentMouseOver);function aspxClassesDocumentMouseOver(evt){if(__aspxHTMLLoaded&&__aspxStateItemsExist)
aspxGetStateController().OnMouseOver(evt);}
_aspxAttachEventToDocument("keydown",aspxClassesDocumentKeyDown);function aspxClassesDocumentKeyDown(evt){if(__aspxHTMLLoaded&&__aspxStateItemsExist)
aspxGetStateController().OnKeyDown(evt);}
_aspxAttachEventToDocument("selectstart",aspxClassesDocumentSelectStart);function aspxClassesDocumentSelectStart(evt){if(__aspxHTMLLoaded&&__aspxStateItemsExist)
return aspxGetStateController().OnSelectStart(evt);}
function aspxFireDefaultButton(evt,buttonID){if(evt.keyCode==ASPxKey.Enter){var srcElement=_aspxGetEventSource(evt);if(!_aspxIsExists(srcElement)||(srcElement.tagName!="TEXTAREA")){var defaultButton=_aspxGetElementById(buttonID);if(_aspxIsExists(defaultButton)&&_aspxIsExists(defaultButton.click)){if(_aspxIsFocusable(defaultButton))
defaultButton.focus();defaultButton.click();evt.cancelBubble=true;if(_aspxIsFunction(evt.stopPropagation))
evt.stopPropagation();return false;}}}
return true;}
var __aspxIncludeScriptPrefix="dxis_";var __aspxStartupScriptPrefix="dxss_";var __aspxIncludeScriptsCache={};var __aspxCreatedIncludeScripts;var __aspxAppendedScriptsCount;var __aspxScriptsRestartHandlers={};function _aspxGetScriptCode(script){var text=__aspxSafariFamily?script.firstChild.data:script.text;var comment="<!--";var pos=text.indexOf(comment);if(pos>-1)
text=text.substr(pos+comment.length);return text;}
function _aspxAppendScript(script){var parent=document.getElementsByTagName("head")[0];if(!_aspxIsExists(parent))
parent=document.body;if(_aspxIsExists(parent)){parent.appendChild(script);}}
function _aspxIsAlphaFilterUsed(img){return(__aspxIE&&img.style.filter.indexOf("progid:DXImageTransform.Microsoft.AlphaImageLoader")>-1);}
function _aspxIsKnownIncludeScript(script){return _aspxIsExists(__aspxIncludeScriptsCache[script.src]);}
function _aspxCacheIncludeScript(script){__aspxIncludeScriptsCache[script.src]=1;}
function _aspxGetStartupScripts(){return _aspxGetScriptsCore(__aspxStartupScriptPrefix);}
function _aspxGetIncludeScripts(){return _aspxGetScriptsCore(__aspxIncludeScriptPrefix);}
function _aspxGetScriptsCore(prefix){var result=[];var scripts=document.getElementsByTagName("SCRIPT");for(var i=0;i<scripts.length;i++){if(scripts[i].id.indexOf(prefix)==0)
result.push(scripts[i]);}
return result;}
function _aspxGetLinks(){var result=[];var links=document.getElementsByTagName("LINK");;for(var i=0;i<links.length;i++)
result[i]=links[i];return result;}
function _aspxInitializeLinks(){var links=_aspxGetLinks();for(var i=0;i<links.length;i++)
links[i].loaded=true;}
function _aspxInitializeScripts(){var scripts=_aspxGetIncludeScripts();for(var i=0;i<scripts.length;i++)
_aspxCacheIncludeScript(scripts[i]);var startupScripts=_aspxGetStartupScripts();for(var i=0;i<startupScripts.length;i++)
startupScripts[i].executed=true;}
function _aspxSweepDuplicatedLinks(){if(__aspxIE&&!__aspxIE7)return;var hash={};var links=_aspxGetLinks();for(var i=0;i<links.length;i++){var href=links[i].href;if(!_aspxIsExists(href)||href=="")continue;if(_aspxIsExists(hash[href])){if(!hash[href].loaded&&links[i].loaded){_aspxRemoveElement(hash[href]);hash[href]=links[i];}
else
_aspxRemoveElement(links[i]);}
else
hash[href]=links[i];}}
function _aspxSweepDuplicatedScripts(){var hash={};var scripts=_aspxGetIncludeScripts();for(var i=0;i<scripts.length;i++){var src=scripts[i].src;if(!_aspxIsExists(src)||src=="")continue;if(_aspxIsExists(hash[src]))
_aspxRemoveElement(scripts[i]);else
hash[src]=scripts[i];}}
function _aspxProcessScripts(ownerName){__aspxCreatedIncludeScripts=[];__aspxAppendedScriptsCount=0;var scripts=_aspxGetIncludeScripts();var immediate=false;var waitCount=0;var previousCreatedScript=null;var firstCreatedScript=null;for(var i=0;i<scripts.length;i++){if(!_aspxIsKnownIncludeScript(scripts[i])){waitCount++;var createdScript=document.createElement("script");__aspxCreatedIncludeScripts.push(createdScript);createdScript.type="text/javascript";createdScript.src=scripts[i].src;if(__aspxIE){createdScript.onreadystatechange=new Function("_aspxOnScriptReadyStateChangedCallback(this, \""+ownerName+"\");");}else if(__aspxSafariFamily){createdScript.onload=new Function("_aspxOnScriptLoadCallback(this, \""+ownerName+"\");");if(firstCreatedScript==null)
firstCreatedScript=createdScript;createdScript.nextCreatedScript=null;if(previousCreatedScript!=null)
previousCreatedScript.nextCreatedScript=createdScript;previousCreatedScript=createdScript;}else{createdScript.onload=new Function("_aspxOnScriptLoadCallback(this, \""+ownerName+"\");");_aspxAppendScript(createdScript);_aspxCacheIncludeScript(createdScript);}}}
if(__aspxSafariFamily&&firstCreatedScript!=null){_aspxAppendScript(firstCreatedScript);_aspxCacheIncludeScript(firstCreatedScript);}
if(immediate&&waitCount>0)
_aspxSetTimeout("_aspxFinalizeScriptProcessing(\""+ownerName+"\")",1);else if(waitCount==0)
_aspxFinalizeScriptProcessing(ownerName);}
function _aspxFinalizeScriptProcessing(ownerName){_aspxSweepDuplicatedScripts();_aspxRunStartupScripts();var owner=aspxGetControlCollection().Get(ownerName);if(owner!=null)owner.DoEndCallback();}
function _aspxRunStartupScripts(){var scripts=_aspxGetStartupScripts();var code;for(var i=0;i<scripts.length;i++){if(!scripts[i].executed){code=_aspxGetScriptCode(scripts[i]);eval(code);scripts[i].executed=true;}}
aspxGetControlCollection().InitializeElements();for(var key in __aspxScriptsRestartHandlers)
__aspxScriptsRestartHandlers[key]();}
function _aspxOnScriptReadyStateChangedCallback(scriptElement,ownerName){if(scriptElement.readyState=="loaded"){_aspxCacheIncludeScript(scriptElement);for(var i=0;i<__aspxCreatedIncludeScripts.length;i++){var script=__aspxCreatedIncludeScripts[i];if(_aspxIsKnownIncludeScript(script)){if(!script.executed){script.executed=true;_aspxAppendScript(script);__aspxAppendedScriptsCount++;}}else
break;}
if(__aspxCreatedIncludeScripts.length==__aspxAppendedScriptsCount)
_aspxFinalizeScriptProcessing(ownerName);}}
function _aspxOnScriptLoadCallback(scriptElement,ownerName){__aspxAppendedScriptsCount++;if(_aspxIsExists(scriptElement.nextCreatedScript)){_aspxAppendScript(scriptElement.nextCreatedScript);_aspxCacheIncludeScript(scriptElement.nextCreatedScript);}
if(__aspxCreatedIncludeScripts.length==__aspxAppendedScriptsCount)
_aspxFinalizeScriptProcessing(ownerName);}
function _aspxAddScriptsRestartHandler(objectName,handler){__aspxScriptsRestartHandlers[objectName]=handler;}
function _aspxMoveLinkElements(){if(__aspxIE)
return;var head=_aspxGetElementsByTagName(document,"head")[0];var bodyLinks=_aspxGetElementsByTagName(document.body,"link");for(var i=0;i<bodyLinks.length;i++)
head.appendChild(bodyLinks[i]);}
var __aspxMenuAnimationAccelerator=1/10;var __aspxPCAnimationAccelerator=1/3;var __aspxAnimationDiscardPixels=3;var __aspxNotSetAlignIndicator="NotSet";var __aspxInnerAlignIndicator="Sides";function _aspxIsAlignNotSet(align){return align==__aspxNotSetAlignIndicator;}
function _aspxIsInnerAlign(align){return align.indexOf(__aspxInnerAlignIndicator)!=-1;}
function _aspxIsOuterAlign(align){return(!this.IsInnerAlign(align))&&(!_aspxIsAlignNotSet(align));}
function _aspxPopupPosition(position,isInverted){this.position=position;this.isInverted=isInverted;}
function _aspxSegment(pos,len){this.pos=pos;this.len=len;}
function _aspxRect(left,top,width,height){this.left=left;this.top=top;this.width=width;this.height=height;}
function _aspxFindPopupElementById(id){if(id=="")return null;var popupElement=_aspxGetElementById(id);if(!_aspxIsExistsElement(popupElement)){var idParts=id.split("_");var uniqueId=idParts.join("$");popupElement=_aspxGetElementById(uniqueId);}
return popupElement;}
function _aspxFindParentPopupElementByEvent(evt,testFunc){return _aspxFindParentPopupElement(_aspxGetEventSource(evt),testFunc);}
function _aspxFindParentPopupElement(element,testFunc){if(!_aspxIsExists(testFunc))return null;while(element!=null&&element.tagName!="BODY"){if(testFunc(element))
return element;element=element.parentNode;}
return null;}
function _aspxPreventContextMenu(evt){if(__aspxSafariFamily)
evt.stopPropagation();else if(__aspxNS)
evt.preventDefault();}
function _aspxIsExistsAbsolutePosParent(element){return _aspxIsExistsParentWithSpecPosition(element,["absolute"])}
function _aspxIsExistsAbsoluteOrRelativePosParent(element){return _aspxIsExistsParentWithSpecPosition(element,["absolute","relative"])}
function _aspxIsExistsParentWithSpecPosition(element,positions){var curEl=element.offsetParent;while(curEl!=null){for(var i=0;i<positions.length;i++){if(_aspxGetCurrentStyle(curEl).position==positions[i])
return true;}
curEl=curEl.offsetParent;}
return false;}
function _aspxGetPopupAbsoluteX(element,popupElement,hAlign,hOffset,x,left){var width=element.offsetWidth;var bodyWidth=_aspxGetDocumentClientWidth();var elementX=_aspxGetAbsoluteX(popupElement);var scrollX=_aspxGetDocumentScrollLeft();if(hAlign=="WindowCenter")
return new _aspxPopupPosition(Math.ceil(bodyWidth/2-width/2)+scrollX+hOffset,false);if(_aspxIsExists(popupElement)){var leftX=elementX-width;var rightX=elementX+popupElement.offsetWidth;var innerLeftX=elementX;var innerRightX=elementX+popupElement.offsetWidth-width;var isMoreFreeSpaceLeft=bodyWidth-(rightX+width)<leftX-2*scrollX;}
else
hAlign="";var isInverted=false;if(hAlign=="OutsideLeft"){isInverted=!(leftX-scrollX>0||isMoreFreeSpaceLeft);if(isInverted)
x=rightX-hOffset;else
x=leftX+hOffset;}
else if(hAlign=="LeftSides"){x=innerLeftX+hOffset;}
else if(hAlign=="Center"){x=elementX+Math.round((popupElement.offsetWidth-width)/2)+hOffset;}
else if(hAlign=="RightSides"){x=innerRightX+hOffset;}
else if(hAlign=="OutsideRight"){isInverted=!(rightX+width<bodyWidth+scrollX||!isMoreFreeSpaceLeft);if(isInverted)
x=leftX-hOffset;else
x=rightX+hOffset;}
else{if(!_aspxGetIsValidPosition(x))
x=(_aspxIsExists(popupElement))?_aspxGetAbsoluteX(popupElement):left;isInverted=x-scrollX+width>bodyWidth&&x-scrollX>bodyWidth/2;if(isInverted)
x=x-width-hOffset;else
x=x+hOffset;}
if(__aspxIE55)
x-=_aspxGetIEDocumentClientOffset(true);return new _aspxPopupPosition(x,isInverted);}
function _aspxGetPopupAbsoluteY(element,popupElement,vAlign,vOffset,y,top){var height=element.offsetHeight;var bodyHeight=_aspxGetDocumentClientHeight();var elementY=_aspxGetAbsoluteY(popupElement);var scrollY=_aspxGetDocumentScrollTop();if(vAlign=="WindowCenter")
return new _aspxPopupPosition(Math.ceil(bodyHeight/2-height/2)+scrollY+vOffset,false);if(_aspxIsExists(popupElement)){var bottomY=elementY+popupElement.offsetHeight;var topY=elementY-height;var innerBottomY=elementY+popupElement.offsetHeight-height;var innerTopY=elementY;var isMoreFreeSpaceAbove=bodyHeight-(bottomY+height)<topY-2*scrollY;}
else
vAlign="";var isInverted=false;if(vAlign=="Above"){isInverted=!(topY-scrollY>0||isMoreFreeSpaceAbove);if(isInverted)
y=bottomY-vOffset;else
y=topY+vOffset;}
else if(vAlign=="TopSides"){y=innerTopY+vOffset;}
else if(vAlign=="Middle"){y=elementY+Math.round((popupElement.offsetHeight-height)/2)+vOffset;}
else if(vAlign=="BottomSides"){y=innerBottomY+vOffset;}
else if(vAlign=="Below"){isInverted=!(bottomY+height<bodyHeight+scrollY||!isMoreFreeSpaceAbove);if(isInverted)
y=topY-vOffset;else
y=bottomY+vOffset;}
else{if(!_aspxGetIsValidPosition(y))
y=(_aspxIsExists(popupElement))?_aspxGetAbsoluteY(popupElement):top;isInverted=y-_aspxGetDocumentScrollTop()+height>bodyHeight&&y-_aspxGetDocumentScrollTop()>bodyHeight/2;if(isInverted)
y=y-height-vOffset;else
y=y+vOffset;}
if(__aspxIE55)
y-=_aspxGetIEDocumentClientOffset(false);return new _aspxPopupPosition(y,isInverted);}
function _aspxGetIntersectionRect(left1,top1,left2,top2,width,height){var segment1=_aspxGetIntersectionSegment(left1,left2,width);var segment2=_aspxGetIntersectionSegment(top1,top2,height);if(segment1!=null&&segment2!=null){var left=segment1.pos;var top=segment2.pos;var width=segment1.len;var height=segment2.len;return new _aspxRect(left,top,width,height);}
return null;}
function _aspxGetIntersectionSegment(pos1,pos2,len){var posDifferense=Math.abs(pos1-pos2);if(posDifferense<=len){var pos=pos1>pos2?pos1:pos2;var len=len-posDifferense;return new _aspxSegment(pos,len);}
return null;}
function _aspxInitAnimationDiv(element,x,y,onTimerString,onAnimStopCallString){element.animationStart=new Date();element.absoluteLeft=x;element.absoluteTop=y;element.popuping=true;element.onTimerString=onTimerString;element.onAnimStopCallString=onAnimStopCallString;element.style.overflow="hidden";element.style.position="absolute";_aspxSetStylePosition(element,x,y);_aspxSetStyleSize(element,element.offsetWidth,element.offsetHeight);}
function _aspxOnAnimationTimer(animationDivElement,element,mainCell,iframeElement,animationDelay,animationMaxDelay,animationAccelerator){animationDivElement.timerID=_aspxClearTimer(element.timerID);var timeExpired=new Date()-animationDivElement.animationStart>animationMaxDelay;if(timeExpired)
_aspxAnimationFinished(animationDivElement);var left=animationDivElement.popuping?_aspxGetNextAnimationPosInternal(element.offsetLeft,animationAccelerator):0;var top=animationDivElement.popuping?_aspxGetNextAnimationPosInternal(element.offsetTop,animationAccelerator):0;if(left==0&&top==0)
_aspxAnimationFinished(animationDivElement);element.style.top=top+"px";element.style.left=left+"px";var rect=_aspxGetIntersectionRect(animationDivElement.offsetLeft,animationDivElement.offsetTop,element.offsetLeft+animationDivElement.offsetLeft,element.offsetTop+animationDivElement.offsetTop,mainCell.offsetWidth,mainCell.offsetHeight);if(_aspxIsExists(rect)&&_aspxIsExists(iframeElement)){_aspxSetStylePosition(iframeElement,rect.left,rect.top);_aspxSetStyleSize(iframeElement,rect.width,rect.height);}
if(!timeExpired&&animationDivElement.popuping)
animationDivElement.timerID=window.setTimeout(animationDivElement.onTimerString,animationDelay);}
function _aspxGetNextAnimationPosInternal(pos,animationAccelerator){pos=Math.round(pos*animationAccelerator);if(Math.abs(pos)<__aspxAnimationDiscardPixels)
pos=0;return pos;}
function _aspxAnimationFinished(element){if(_aspxStopAnimation(element)&&_aspxIsExists(element.onAnimStopCallString)&&element.onAnimStopCallString!==""){eval(element.onAnimStopCallString);}}
function _aspxStopAnimation(element){if(element.popuping){element.popuping=false;element.onTimerString="";element.style.overflow="visible";return true;}
return false;}
function _aspxGetAnimationHorizontalDirection(popupPosition,horizontalAlign,verticalAlign){if(_aspxIsInnerAlign(horizontalAlign)&&!_aspxIsInnerAlign(verticalAlign)&&!_aspxIsAlignNotSet(verticalAlign))
return 0;var toTheLeft=(horizontalAlign=="OutsideLeft"||horizontalAlign=="RightSides")^popupPosition.isInverted;return toTheLeft?1:-1;}
function _aspxGetAnimationVerticalDirection(popupPosition,horizontalAlign,verticalAlign){if(_aspxIsInnerAlign(verticalAlign)&&!_aspxIsInnerAlign(horizontalAlign)&&!_aspxIsAlignNotSet(horizontalAlign))
return 0;var toTheTop=(verticalAlign=="Above"||verticalAlign=="BottomSides")^popupPosition.isInverted;return toTheTop?1:-1;}
function _aspxHideBodyScroll(){if(__aspxIE){_aspxChangeAttribute(document.body,"scroll","no");_aspxChangeStyleAttribute(document.documentElement,"overflow","hidden");}else if(__aspxFirefox&&!__aspxFirefox3){var scrollTop=document.documentElement.scrollTop;_aspxChangeStyleAttribute(document.body,"overflow","hidden");document.documentElement.scrollTop=scrollTop;}else
_aspxChangeStyleAttribute(document.body,"overflow","hidden");_aspxChangeStyleAttribute(document.body,"marginRight","16px");}
function _aspxRestoreBodyScroll(){if(__aspxIE){_aspxRestoreAttribute(document.body,"scroll");_aspxRestoreStyleAttribute(document.documentElement,"overflow");}
else
_aspxRestoreStyleAttribute(document.body,"overflow");_aspxRestoreStyleAttribute(document.body,"marginRight");if(__aspxSafariFamily){var scrollTop=document.body.scrollTop;document.body.scrollTop++;document.body.scrollTop--;document.body.scrollTop=scrollTop;}}
var __aspxDragHelper=null;ASPxClientDragHelper=_aspxCreateClass(null,{constructor:function(e,root,clone){if(__aspxDragHelper!=null)__aspxDragHelper.cancelDrag();this.dragArea=5;this.lastX=e.clientX+_aspxGetDocumentScrollLeft();this.lastY=e.clientY+_aspxGetDocumentScrollTop();this.canDrag=true;if(typeof(root)=="string")
root=_aspxGetParentByTagName(_aspxGetEventSource(e),root);this.obj=root&&root!=null?root:_aspxGetEventSource(e);this.clone=clone;this.dragObj=null;this.additionalObj=null;this.onDoClick=new Function();this.onEndDrag=new Function();this.onCancelDrag=new Function();this.onDragDivCreating=new Function();this.onCloneCreating=null;this.onCloneCreated=new Function();this.dragDiv=null;__aspxDragHelper=this;},drag:function(e){if(!this.canDrag)return;if(!this.isDragging()){if(!this.isOutOfDragArea(e.clientX,e.clientY))
return;this.startDragCore(e);}
if(__aspxIE&&!_aspxGetIsLeftButtonPressed(e)){this.cancelDrag(e);return;}
this.clearSelection();this.dragCore(e);},clearSelection:function(){if(!window.getSelection)return;var sel=window.getSelection();if(sel&&sel.removeAllRanges){sel.removeAllRanges();}},startDragCore:function(e){this.dragObj=this.clone!=true?this.obj:this.createClone();},dragCore:function(e){var x=e.clientX+_aspxGetDocumentScrollLeft();var y=e.clientY+_aspxGetDocumentScrollTop();var nx=this.dragObj.offsetLeft+x-this.lastX;var ny=this.dragObj.offsetTop+y-this.lastY;this.dragObj.style.left=nx+"px";this.dragObj.style.top=ny+"px";this.lastX=x;this.lastY=y;},endDrag:function(e){if(!this.isDragging()&&!this.isOutOfDragArea(e.clientX,e.clientY))
this.onDoClick(this);else this.onEndDrag(this);this.cancelDrag();},cancelDrag:function(){if(this.dragDiv!=null){document.body.removeChild(this.dragDiv);this.dragDiv=null;}
this.onCancelDrag(this);__aspxDragHelper=null;},isDragging:function(){return this.dragObj!=null;},createClone:function(){this.dragDiv=document.createElement("div");this.onDragDivCreating(this,this.dragDiv);this.dragDiv.style.position="absolute";this.dragDiv.style.cursor="move";this.dragDiv.style.left=_aspxGetAbsoluteX(this.obj)+"px";this.dragDiv.style.top=_aspxGetAbsoluteY(this.obj)+"px";this.dragDiv.style.width=this.obj.offsetWidth+"px";this.dragDiv.style.height=this.obj.offsetHeight+"px";this.dragDiv.select=DragHelper_onselectstart;this.dragDiv.style.zIndex=20000;this.dragDiv.style.padding="0px";this.dragDiv.style.margin="0px";this.dragDiv.style.borderStyle="none";this.dragDiv.style.borderWidth="0px";this.dragDiv.style.backgroundColor="transparent";var clone=this.creatingClone();this.onCloneCreated(clone);this.dragDiv.appendChild(clone);document.body.appendChild(this.dragDiv);return this.dragDiv;},creatingClone:function(){var clone=this.obj.cloneNode(true);if(!_aspxIsExists(this.onCloneCreating))return clone;return this.onCloneCreating(clone);},addElementToDragDiv:function(element){if(this.dragDiv==null)return;this.additionalObj=element.cloneNode(true);this.additionalObj.style.visibility="visible";this.dragDiv.appendChild(this.additionalObj);},removeElementFromDragDiv:function(){if(this.additionalObj==null||this.dragDiv==null)return;this.dragDiv.removeChild(this.additionalObj);this.additionalObj=null;},isOutOfDragArea:function(newX,newY){return Math.max(Math.abs(newX+_aspxGetDocumentScrollLeft()-this.lastX),Math.abs(newY+_aspxGetDocumentScrollTop()-this.lastY))>=this.dragArea;}});function DragHelper_onmouseup(e){if(__aspxDragHelper!=null){__aspxDragHelper.endDrag(e);return true;}}
function DragHelper_onmousemove(e){if(__aspxDragHelper!=null){__aspxDragHelper.drag(e);return true;}}
function DragHelper_onkeydown(e){if(__aspxDragHelper==null)return;if(e.keyCode==ASPxKey.Esc){if(_aspxIsExists(__aspxDragHelper.onEscKeyDown))
__aspxDragHelper.onEscKeyDown();else
__aspxDragHelper.cancelDrag();}
return true;}
function DragHelper_onselectstart(e){if(__aspxDragHelper!=null){if(!__aspxDragHelper.canDrag)
return true;document.selection.empty();return false;}}
_aspxAttachEventToDocument("mouseup",DragHelper_onmouseup);_aspxAttachEventToDocument("mousemove",DragHelper_onmousemove);_aspxAttachEventToDocument("keydown",DragHelper_onkeydown);_aspxAttachEventToDocument("selectstart",DragHelper_onselectstart);var __aspxCursorTargets=null;ASPxClientCursorTargets=_aspxCreateClass(null,{constructor:function(){this.list=new Array();this.starttargetElement=null;this.starttargetTag=0;this.oldtargetElement=null;this.oldtargetTag=0;this.targetElement=null;this.targetTag=0;this.x=0;this.y=0;this.removedX=0;this.removedY=0;this.removedWidth=0;this.removedHeight=0;this.onTargetChanging=new Function();this.onTargetChanged=new Function();this.onTargetAdding=null;__aspxCursorTargets=this;},addElement:function(element){if(!this.canAddElement(element))return null;var target=new ASPxClientCursorTarget(element);this.list.push(target);return target;},removeElement:function(element){for(var i=0;i<this.list.length;i++)
if(this.list[i].element==element){this.list.splice(i,1);return;}},addParentElement:function(parent,child){var target=this.addElement(parent);if(target!=null){target.targetElement=child;}
return target;},RegisterTargets:function(element,idPrefixArray){this.addFunc=this.addElement;this.RegisterTargetsCore(element,idPrefixArray);},UnregisterTargets:function(element,idPrefixArray){this.addFunc=this.removeElement;this.RegisterTargetsCore(element,idPrefixArray);},RegisterTargetsCore:function(element,idPrefixArray){if(element==null)return;for(var i=0;i<idPrefixArray.length;i++)
this.RegisterTargetCore(element,idPrefixArray[i]);},RegisterTargetCore:function(element,idPrefix){if(!_aspxIsExists(element.id))return;if(element.id.indexOf(idPrefix)>-1)
this.addFunc(element);for(var i=0;i<element.childNodes.length;i++)
this.RegisterTargetCore(element.childNodes[i],idPrefix);},canAddElement:function(element){if(element==null)return false;for(var i=0;i<this.list.length;i++){if(this.list[i].targetElement==element)return false;}
if(this.onTargetAdding!=null&&!this.onTargetAdding(this,element))return false;return element.style.visibility!="hidden";},removeInitialTarget:function(x,y){var el=this.getTarget(x+_aspxGetDocumentScrollLeft(),y+_aspxGetDocumentScrollTop());if(el==null)return;this.removedX=_aspxGetAbsoluteX(el);this.removedY=_aspxGetAbsoluteY(el);this.removedWidth=el.offsetWidth;this.removedHeight=el.offsetHeight;},getTarget:function(x,y){for(var i=0;i<this.list.length;i++){if(this.list[i].contains(x,y))
return this.list[i].targetElement;}
return null;},targetChanged:function(element,tag){this.targetElement=element;this.targetTag=tag;this.onTargetChanging(this);if(this.oldtargetElement!=this.targetElement||this.oldtargetTag!=this.targetTag){this.onTargetChanged(this);this.oldtargetElement=this.targetElement;this.oldtargetTag=this.targetTag;}},cancelChanging:function(){this.targetElement=this.oldtargetElement;this.targetTag=this.oldtargetTag;},isLeftPartOfElement:function(){if(this.targetElement==null)return true;var left=this.x-this.targetElementX();return left<this.targetElement.offsetWidth/2;},isTopPartOfElement:function(){if(this.targetElement==null)return true;var top=this.y-this.targetElementY();return top<this.targetElement.offsetHeight/2;},targetElementX:function(){return this.targetElement!=null?_aspxGetAbsoluteX(this.targetElement):0;},targetElementY:function(){return this.targetElement!=null?_aspxGetAbsoluteY(this.targetElement):0;},onmousemove:function(e){this.doTargetChanged(e);},onmouseup:function(e){this.doTargetChanged(e);__aspxCursorTargets=null;},doTargetChanged:function(e){this.x=e.clientX+_aspxGetDocumentScrollLeft();this.y=e.clientY+_aspxGetDocumentScrollTop();if(this.inRemovedBounds(this.x,this.y))return;this.targetChanged(this.getTarget(this.x,this.y),0);},inRemovedBounds:function(x,y){if(this.removedWidth==0)return false;return x>this.removedX&&x<(this.removedX+this.removedWidth)&&y>this.removedY&&y<(this.removedY+this.removedHeight);}});ASPxClientCursorTarget=_aspxCreateClass(null,{constructor:function(element){this.element=element;this.targetElement=element;this.absoluteX=_aspxGetAbsoluteX(element);this.absoluteY=_aspxGetAbsoluteY(element);},contains:function(x,y){return x>=this.absoluteX&&x<=this.absoluteX+this.element.offsetWidth&&y>=this.absoluteY&&y<=this.absoluteY+this.element.offsetHeight;}});function CursorTarget_onmouseup(e){if(__aspxCursorTargets!=null){__aspxCursorTargets.onmouseup(e);return true;}}
function CursorTarget_onmousemove(e){if(__aspxCursorTargets!=null){__aspxCursorTargets.onmousemove(e);return true;}}
_aspxAttachEventToDocument("mouseup",CursorTarget_onmouseup);_aspxAttachEventToDocument("mousemove",CursorTarget_onmousemove);var __aspxDialogFormCallbackStatus="DialogForm";var __aspxCurrentControlNameInDialog="";var __aspxAreKeyboardEventsInitialized=false;function aspxAdjustControlsSizeInDialogWindow(){var control=aspxGetControlCollection().Get(__aspxCurrentControlNameInDialog);var curDialog=control!=null?ASPxDialog.GetLastDialog(control):null;if(curDialog!=null)
ASPxClientControl.GetControlCollection().AdjustControls(curDialog.GetDialogPopup().GetMainElement());}
ASPxDialog=_aspxCreateClass(null,{constructor:function(name){this.name=name;this.initInfo=null;this.editorKeyDownProccesed=false;this.keyDownHandlers={};this.InitializeKeyHandlers();},InitializeKeyHandlers:function(){this.AddKeyDownHandler("ESC","HideDialog");},AddKeyDownHandler:function(shortcutString,handler){this.keyDownHandlers[_aspxParseShortcutString(shortcutString)]=handler;},DoCustomAction:function(result,params){},GetDialogCaptionText:function(){return"";},GetInitInfoObject:function(){return null;},InitializeDialogFields:function(initInfo){},SetFocusInField:function(){},Execute:function(ownerControl,popupElementID){this.ownerControl=ownerControl;__aspxCurrentControlNameInDialog=this.ownerControl.name;ASPxDialog.PushDialogToCollection(this.ownerControl,this);this.InitializePopupEvents();this.GetDialogPopup().SetHeaderText(this.GetDialogCaptionText());if(_aspxIsExists(popupElementID))
this.GetDialogPopup().ShowAtElementByID(popupElementID);else
this.GetDialogPopup().Show();if(this.GetDialogContent(this.name)==null){this.SendCallbackForDialogContent();this.ShowLoadingPanelInDialogPopup();}
else{this.ExecuteInternal(this.GetDialogContent(this.name));_aspxRunStartupScripts();this.OnInitComplete();}},ExecuteInternal:function(result){this.initInfo=this.GetInitInfoObject();this.GetDialogPopup().SetContentHtml(result);if(this.GetDialogPopup().IsVisible())
this.GetDialogPopup().UpdatePosition();},GetDialogPopup:function(){if(_aspxIsExists(this.ownerControl.GetDialogPopupControl))
return this.ownerControl.GetDialogPopupControl();return null;},AddDialogContentToHash:function(name,content){this.GetDialogContentHashTable()[this.name]=content;},GetDialogContent:function(name){return _aspxIsExists(this.GetDialogContentHashTable()[this.name])?this.GetDialogContentHashTable()[this.name]:null;},GetDialogContentHashTable:function(){if(_aspxIsExists(this.ownerControl.dialogContentHashTable))
return this.ownerControl.dialogContentHashTable;return null;},InitializePopupEvents:function(){if(this.GetDialogPopup().CloseButtonClick.IsEmpty()){var func=_aspxCreateEventHandlerFunction("aspxOnDialogCloseButtonClick",this.ownerControl.name,false);this.GetDialogPopup().CloseButtonClick.AddHandler(func);func=_aspxCreateEventHandlerFunction("aspxOnDialogClose",this.ownerControl.name,false);this.GetDialogPopup().CloseUp.AddHandler(func);}},InitCustomKeyboardHandling:function(){if(!__aspxAreKeyboardEventsInitialized){__aspxAreKeyboardEventsInitialized=true;_aspxAttachEventToDocument("keypress",aspxDialogDocumentKeypress);if(__aspxNS)
this.ReplaceKBSIKeyDown();}},ReplaceKBSIKeyDown:function(){var original=aspxKBSIKeyDown;aspxKBSIKeyDown=function(name,evt){var isProcessed=original(name,evt);var ownerControl=aspxGetControlCollection().Get(__aspxCurrentControlNameInDialog);var curDialog=ownerControl!=null?ASPxDialog.GetLastDialog(ownerControl):null;if(curDialog!=null)curDialog.OnInnerEditorKeyDown(evt,isProcessed);return isProcessed;};},SendCallbackForDialogContent:function(){this.ownerControl.callbackOwner=this;this.ownerControl.SendCallback(__aspxDialogFormCallbackStatus,this.name,false);},ShowLoadingPanelInDialogPopup:function(){this.GetDialogPopup().SetContentHtml("");var contentElement=this.GetDialogPopup().GetWindowContentElement(-1);this.ownerControl.CreateLoadingDiv(contentElement);this.ownerControl.CreateLoadingPanelInsideContainer(contentElement);},ShowLoadingPanelOverDialogPopup:function(){var offsetElement=__aspxNS?this.GetDialogPopup().GetWindowElement(-1):_aspxGetParentByTagName(this.GetDialogPopup().GetWindowContentElement(-1),"table");this.ownerControl.CreateLoadingDiv(document.body,offsetElement);this.ownerControl.CreateLoadingPanelWithAbsolutePosition(document.body,offsetElement);},HideLoadingPanelOverDialogPopup:function(){this.ownerControl.HideLoadingDiv();this.ownerControl.HideLoadingPanel();},HideDialog:function(){this.GetDialogPopup().Hide();this.OnCloseButtonClick();this.OnClose();},OnCallback:function(result){this.ExecuteInternal(result);this.AddDialogContentToHash(this.name,result);},OnCallbackError:function(result,data){this.ownerControl.callbackOwner=null;},OnEndCallback:function(){this.ownerControl.callbackOwner=null;this.OnInitComplete();},OnClose:function(){ASPxDialog.RemoveLastDialog(this.ownerControl);},OnCloseButtonClick:function(){},OnComplete:function(result,params){this.GetDialogPopup().Hide();this.DoCustomAction(result,params);},OnDocumentKeyPress:function(evt){if(!this.editorKeyDownProccesed){var handler=this.keyDownHandlers[_aspxGetShortcutCode(evt.keyCode,evt.ctrlKey,evt.shiftKey,evt.altKey)];if(_aspxIsExists(handler))
this[handler](evt);}
this.editorKeyDownProccesed=false;},OnInnerEditorKeyDown:function(evt,isProcessed){this.editorKeyDownProccesed=_aspxIsExists(isProcessed)?!isProcessed:false;},OnInitComplete:function(){this.InitCustomKeyboardHandling();this.InitializeDialogFields(this.initInfo);this.SetFocusInField();}});ASPxDialog.PushDialogToCollection=function(ownerControl,dialog){if(!_aspxIsExists(ownerControl.dialogArray))
ownerControl.dialogArray=new Array();_aspxArrayPush(ownerControl.dialogArray,dialog);}
ASPxDialog.GetLastDialog=function(ownerControl){if(_aspxIsExists(ownerControl.dialogArray)){var length=ownerControl.dialogArray.length;return length>0?ownerControl.dialogArray[length-1]:null;}
return null;}
ASPxDialog.RemoveLastDialog=function(ownerControl){var array=ownerControl.dialogArray;if(_aspxIsExists(array)&&array.length>0)
_aspxArrayRemoveAt(array,array.length-1);}
function aspxOnDialogCloseButtonClick(name){var ownerControl=aspxGetControlCollection().Get(name);var curDialog=ownerControl!=null?ASPxDialog.GetLastDialog(ownerControl):null;if(curDialog!=null)
return curDialog.OnCloseButtonClick();}
function aspxOnDialogClose(name){var ownerControl=aspxGetControlCollection().Get(name);var curDialog=ownerControl!=null?ASPxDialog.GetLastDialog(ownerControl):null;if(curDialog!=null)
return curDialog.OnClose();}
function aspxDialogComplete(result,params){var ownerControl=aspxGetControlCollection().Get(__aspxCurrentControlNameInDialog);var curDialog=ownerControl!=null?ASPxDialog.GetLastDialog(ownerControl):null;if(curDialog!=null)
return curDialog.OnComplete(result,params);}
function aspxDialogDocumentKeypress(evt){var ownerControl=aspxGetControlCollection().Get(__aspxCurrentControlNameInDialog);var curDialog=ownerControl!=null?ASPxDialog.GetLastDialog(ownerControl):null;if(curDialog!=null)
ASPxDialog.GetLastDialog(ownerControl).OnDocumentKeyPress(evt);}
var __aspxWindowResizer=null;var __aspxClientPopupFilterWindow=null;ASPxClientWindowResizer=_aspxCreateClass(null,{constructor:function(e,resizedEl){__aspxWindowResizer=this;this.resizedEl=resizedEl;this.minWidth=50;this.minHeight=50;this.lastX=e.clientX;this.lastY=e.clientY;this.newWidth=resizedEl.offsetWidth;this.newHeight=resizedEl.offsetHeight;this.startWidth=this.newWidth;this.startHeight=this.newHeight;this.virtWidth=this.newWidth;this.virtHeight=this.newHeight;this.onSetSize=null;this.onEndResizing=new Function();},doResizing:function(e){this.virtWidth=this.virtWidth+e.clientX-this.lastX;this.virtHeight=this.virtHeight+e.clientY-this.lastY;this.lastX=e.clientX;this.lastY=e.clientY;this.newWidth=this.virtWidth;this.newHeight=this.virtHeight;if(this.newWidth<this.minWidth)
this.newWidth=this.minWidth;if(this.newHeight<this.minHeight)
this.newHeight=this.minHeight;this.doSetSize();},cancel:function(){this.newWidth=this.startWidth;this.newHeight=this.startHeight;this.stop();},endResizing:function(e){this.onEndResizing(e);this.stop();},stop:function(){this.doSetSize();__aspxWindowResizer=null;},doSetSize:function(){if(this.onSetSize==null||this.onSetSize(this)){this.setSize();}},setSize:function(){this.resizedEl.style.width=this.newWidth+"px";this.resizedEl.style.height=this.newHeight+"px";}});ASPxClientPopupFilterWindow=_aspxCreateClass(null,{constructor:function(name){this.name=name;_aspxAttachEventToElement(this.GetWindowResizer(),"dragstart",_aspxPreventDragStart);},GetWindow:function(){return _aspxGetElementById(this.name+"_FPW");},GetElement:function(){return _aspxGetElementById(this.name+"_FPC");},GetWindowResizer:function(){return _aspxGetElementById(this.name+"_FPWR");},IsShowing:function(){if(!_aspxIsExists(this.window))return false;return _aspxGetElementDisplay(this.window);},Hide:function(){if(!_aspxIsExists(this.window))return;__aspxClientPopupFilterWindow=null;_aspxSetElementDisplay(this.window,false);this.header=null;},Show:function(element,mainElement){__aspxClientPopupFilterWindow=this;this.window=this.GetWindow();if(!_aspxIsExists(this.window))return;_aspxSetElementDisplay(this.window,true);var left=_aspxGetAbsoluteX(element,mainElement);var top=_aspxGetAbsoluteY(element,mainElement)+element.offsetHeight;left=_aspxPrepareClientPosForElement(left,this.window,true);top=_aspxPrepareClientPosForElement(top,this.window,false);this.window.style.left=left+"px";this.window.style.top=top+"px";this.header=element;},SetDefaultWidth:function(){this.GetWindow().style.width="";this.GetElement().style.width="";},onMouseDown:function(e){var e=_aspxGetEvent(e);var element=_aspxGetEventSource(e);if(element.DXFilterPopupButton)return true;if(this.IsShowing()&&!_aspxGetIsParent(this.window,_aspxGetEventSource(e))){this.Hide();}
return true;},onResizerMouseDown:function(e){var resizer=new ASPxClientWindowResizer(e,this.GetElement());resizer.onSetSize=this.ResizerSetSize;resizer.resizedWindow=this.window;return _aspxCancelBubble(e);},ResizerSetSize:function(resizer){var oldElWidth=resizer.resizedEl.style.width;var oldWindowWidth=resizer.resizedWindow.style.width;var difEl=resizer.resizedEl.offsetWidth;var difWindow=resizer.resizedWindow.offsetWidth;resizer.resizedWindow.style.width=resizer.newWidth+"px";resizer.resizedEl.style.width=resizer.newWidth+"px";difEl=resizer.resizedEl.offsetWidth-difEl;difWindow=resizer.resizedWindow.offsetWidth-difWindow;if(difEl!=difWindow){resizer.resizedEl.style.width=oldElWidth;resizer.resizedWindow.style.width=oldWindowWidth;}
if(__aspxNS){resizer.resizedWindow.style.width=resizer.resizedEl.style.width;if(resizer.resizedWindow.offsetWidth<resizer.resizedEl.offsetWidth){resizer.resizedWindow.style.width="";}}
resizer.resizedWindow.style.height=resizer.newHeight+"px";resizer.resizedEl.style.height=resizer.newHeight+"px";return false;}});function WindowResizer_onmouseup(e){if(__aspxWindowResizer!=null)
__aspxWindowResizer.endResizing(e);return true;}
function WindowResizer_onmousemove(e){if(__aspxWindowResizer!=null){__aspxWindowResizer.doResizing(e);}
return true;}
function WindowResizer_onkeydown(e){if(__aspxWindowResizer==null)return;if(e.keyCode==ASPxKey.Esc)
__aspxWindowResizer.cancel();return true;}
function WindowResizer_onselectstart(e){if(__aspxWindowResizer==null)return;document.selection.empty();return false;}
var __aspxClientPopupFilterWindowShowAgain=false;function PopupFilterWindow_DocumentOnMouseDown(e){if(__aspxClientPopupFilterWindow==null)return;var src=_aspxGetEventSource(e),header=__aspxClientPopupFilterWindow.header;var onclickText=_aspxIsExists(src.onclick)?src.onclick.toString():"";if(onclickText.indexOf("_ShowFilterPopup")>=0&&__aspxClientPopupFilterWindow.IsShowing()&&_aspxGetIsParent(header,src)){__aspxClientPopupFilterWindowShowAgain=true;}
return __aspxClientPopupFilterWindow.onMouseDown(e);}
function PopupFilterWindow_WindowOnResize(e){if(__aspxClientPopupFilterWindow==null)return;__aspxClientPopupFilterWindow.Hide();}
function PopupFilterWindow_WindowOnLoad(e){_aspxAttachEventToDocument("mousedown",PopupFilterWindow_DocumentOnMouseDown);_aspxAttachEventToElement(window,"resize",PopupFilterWindow_WindowOnResize);}
_aspxAttachEventToDocument("mouseup",WindowResizer_onmouseup);_aspxAttachEventToDocument("mousemove",WindowResizer_onmousemove);_aspxAttachEventToDocument("keydown",WindowResizer_onkeydown);_aspxAttachEventToDocument("selectstart",WindowResizer_onselectstart);_aspxAttachEventToElement(window,"load",PopupFilterWindow_WindowOnLoad);ASPxDateFormatter=_aspxCreateClass(null,{constructor:function(){this.date=new Date(2000,0,1);this.mask;this.specifiers={};this.spPositions=[];this.knownSpecifiers=["d","M","y","H","h","m","s","f","F","g","t"];this.savedYear=-1;this.isYearParsed=false;this.parsedMonth=-1;this.replacers={"d":this.ReplaceDay,"M":this.ReplaceMonth,"y":this.ReplaceYear,"H":this.ReplaceHours23,"h":this.ReplaceHours12,"m":this.ReplaceMinutes,"s":this.ReplaceSeconds,"F":this.ReplaceMsTrimmed,"f":this.ReplaceMs,"g":this.ReplaceEra,"t":this.ReplaceAmPm};this.parsers={"d":this.ParseDay,"M":this.ParseMonth,"y":this.ParseYear,"H":this.ParseHours,"h":this.ParseHours,"m":this.ParseMinutes,"s":this.ParseSeconds,"F":this.ParseMs,"f":this.ParseMs,"g":this.ParseEra,"t":this.ParseAmPm};},Format:function(date){this.date=date;var sp;var pos;var replacerKey;var result=this.mask;for(var i=0;i<this.spPositions.length;i++){pos=this.spPositions[i];sp=this.specifiers[pos];replacerKey=sp.substr(0,1);if(this.replacers[replacerKey]){result=result.substr(0,pos)+this.replacers[replacerKey].call(this,sp.length)+result.substr(pos+sp.length);}}
return result;},Parse:function(str){var now=new Date();this.savedYear=now.getYear();this.isYearParsed=false;this.parsedMonth=-1;this.date=new Date(2000,0,now.getDate());this.strToParse=str;this.catchNumbers(str);var parserKey;var sp;var pos;var parseResult;var error=false;this.hasAmPm=false;for(var i=0;i<this.spPositions.length;i++){pos=this.spPositions[i];sp=this.specifiers[pos];parserKey=sp.substr(0,1);if(this.parsers[parserKey]){parseResult=this.parsers[parserKey].call(this,sp.length);if(!parseResult){error=true;break;}}}
if(error)
return false;if(this.hasAmPm){if(!this.fixHours())
return false;}
if(!this.isYearParsed)
this.date.setYear(this.savedYear);if(this.parsedMonth>-1)
this.date.setMonth(this.parsedMonth);else
this.date.setMonth(now.getMonth());return this.date;},SetFormatString:function(mask){if(mask.length==2&&mask.charAt(0)=="%")
mask=mask.charAt(1);this.specifiers={};this.spPositions=[];this.mask="";var subt=0;var pos=0;var startPos=0;var ch;var prevCh="";var skip=false;var backslash=false;var sp="";while(true){ch=mask.charAt(pos);if(ch==""){if(sp.length>0)
this.RegisterSpecifier(startPos,sp);break;}
if(ch=="\\"&&!backslash){backslash=true;subt++;}else{if(!backslash&&(ch=="'"||ch=='"')){skip=!skip;subt++;}else{if(!skip){if(ch=="/")
ch=__aspxDateFormatInfo.ds;else if(ch==":")
ch=__aspxDateFormatInfo.ts;else if(this.IsKnownSpecifier(ch)){if(prevCh.length==0)
prevCh=ch;if(ch==prevCh)
sp+=ch;else{if(sp.length>0)
this.RegisterSpecifier(startPos,sp);sp=ch;startPos=pos-subt;}}}
this.mask+=ch;}
backslash=false;}
prevCh=ch;pos++;}
this.spPositions.reverse();},RegisterSpecifier:function(pos,sp){this.spPositions.push(pos);this.specifiers[pos]=sp;},ReplaceDay:function(length){if(length<3){var value=this.date.getDate().toString();return length==2?this.padLeft(value,2):value;}else if(length==3){return __aspxDateFormatInfo.abbrDayNames[this.date.getDay()];}else{return __aspxDateFormatInfo.dayNames[this.date.getDay()];}},ReplaceMonth:function(length){var value=1+this.date.getMonth();switch(length){case 1:return value.toString();case 2:return this.padLeft(value.toString(),2);case 3:return __aspxDateFormatInfo.abbrGenMonthNames[value-1];default:return __aspxDateFormatInfo.genMonthNames[value-1];}},ReplaceYear:function(length){var value=this.date.getFullYear();if(length<=2)
value=value%100;return this.padLeft(value.toString(),length);},ReplaceHours23:function(length){var value=this.date.getHours().toString();return length>1?this.padLeft(value,2):value;},ReplaceHours12:function(length){var value=this.date.getHours()%12;if(value==0)
value=12;value=value.toString();return length>1?this.padLeft(value,2):value;},ReplaceMinutes:function(length){var value=this.date.getMinutes().toString();return length>1?this.padLeft(value,2):value;},ReplaceSeconds:function(length){var value=this.date.getSeconds().toString();return length>1?this.padLeft(value,2):value;},ReplaceMsTrimmed:function(length){return this.formatMs(length,true);},ReplaceMs:function(length){return this.formatMs(length,false);},ReplaceEra:function(length){return"A.D.";},ReplaceAmPm:function(length){var value=this.date.getHours()<12?__aspxDateFormatInfo.am:__aspxDateFormatInfo.pm;return length<2?value.charAt(0):value;},catchNumbers:function(str){this.parseNumbers=[];var regex=/\d+/g;var match;for(;;){match=regex.exec(str);if(!match)
break;this.parseNumbers.push(this.parseDecInt(match[0]));}
var spCount=0;var now=new Date();for(var i in this.specifiers){var sp=this.specifiers[i];if(sp.constructor!=String||!this.IsNumericSpecifier(sp))continue;spCount++;if(this.parseNumbers.length<spCount){var defaultValue=0;if(sp.charAt(0)=="y")defaultValue=now.getFullYear();this.parseNumbers.push(defaultValue);}}
var excess=this.parseNumbers.length-spCount;if(excess>0)
this.parseNumbers.splice(spCount,excess);this.currentParseNumber=this.parseNumbers.length-1;},popParseNumber:function(){return this.parseNumbers[this.currentParseNumber--];},findAbbrMonth:function(){return this.findMonthCore(__aspxDateFormatInfo.abbrGenMonthNames);},findFullMonth:function(){return this.findMonthCore(__aspxDateFormatInfo.genMonthNames);},findMonthCore:function(monthNames){var inputLower=this.strToParse.toLowerCase();for(var i=0;i<monthNames.length;i++){var monthName=monthNames[i].toLowerCase();if(monthName.length>0&&inputLower.indexOf(monthName)>-1){var empty="";for(var j=0;j<monthName.length;j++)empty+=" ";this.strToParse=this.strToParse.replace(new RegExp(monthName,"g"),empty);return 1+parseInt(i);}}
return false;},ParseDay:function(length){if(length<3){var value=this.popParseNumber();if(value<1||value>31)
return false;this.date.setDate(value);}
return true;},ParseMonth:function(length){var value;switch(length){case 1:case 2:value=this.popParseNumber();break;case 3:value=this.findAbbrMonth();break;default:value=this.findFullMonth();break;}
if(value<1||value>12)
return false;this.parsedMonth=value-1;return true;},ParseYear:function(length){var value=this.popParseNumber();if(value>9999)
return false;if(value<100)
value=this.ExpandTwoDigitYear(value);this.date.setFullYear(value);this.isYearParsed=true;return true;},ParseHours:function(length){var value=this.popParseNumber();if(value>23)
return false;this.date.setHours(value);return true;},ParseMinutes:function(length){var value=this.parseMinSecCore();if(value==-1)
return false;this.date.setMinutes(value);return true;},ParseSeconds:function(length){var value=this.parseMinSecCore();if(value==-1)
return false;this.date.setSeconds(value);return true;},ParseMs:function(length){if(length>3)
length=3;var thr=1;for(var i=0;i<length;i++)
thr*=10;thr-=1;var value=this.popParseNumber();while(value>thr)
value/=10;this.date.setMilliseconds(Math.round(value));return true;},ParseEra:function(length){return true;},ParseAmPm:function(length){this.hasAmPm=__aspxDateFormatInfo.am.length>0&&__aspxDateFormatInfo.pm.length>0;return true;},parseDecInt:function(str){return parseInt(str,10);},padLeft:function(str,length){while(str.length<length)
str="0"+str;return str;},formatMs:function(length,trim){var value=Math.floor(this.date.getMilliseconds()*Math.pow(10,length-3));value=this.padLeft(value.toString(),length);if(trim){var pos=value.length-1;var req=false;while(value.charAt(pos)=="0"){req=true;pos--;}
if(req)
value=value.substring(0,pos+1);}
return value;},parseMinSecCore:function(){var value=this.popParseNumber();return value>59?-1:value;},fixHours:function(){var am=__aspxDateFormatInfo.am.charAt(0).toLowerCase();var pm=__aspxDateFormatInfo.pm.charAt(0).toLowerCase();var str=this.strToParse.toLowerCase();var state=null;if(str.indexOf(am)>-1)
state="A";else if(str.indexOf(pm)>-1)
state="P";if(!state)return true;var h=this.date.getHours();switch(state){case"P":if(h>12)return false;if(h<12)
this.date.setHours(12+h);break;case"A":if(h==12)
this.date.setHours(0);}
return true;},IsNumericSpecifier:function(sp){var ch=sp.charAt(0);if(ch=="g"||ch=="t"||((ch=="M"||ch=="d")&&sp.length>2))
return false;return true;},IsKnownSpecifier:function(sp){if(sp.length>1)
sp=sp.charAt(0);for(var i=0;i<this.knownSpecifiers.length;i++){if(this.knownSpecifiers[i]==sp)
return true;}
return false;},ExpandTwoDigitYear:function(value){value+=1900;if(value+99<__aspxDateFormatInfo.twoDigitYearMax)
value+=100;return value;}});ASPxClientUtils={};ASPxClientUtils.agent=__aspxAgent;ASPxClientUtils.opera=__aspxOpera;ASPxClientUtils.opera9=__aspxOpera9;ASPxClientUtils.safari=__aspxSafari;ASPxClientUtils.safari3=__aspxSafari3;ASPxClientUtils.safariMacOS=__aspxSafariMacOS;ASPxClientUtils.chrome=__aspxChrome;ASPxClientUtils.ie=__aspxIE;ASPxClientUtils.ie55=__aspxIE55;ASPxClientUtils.ie7=__aspxIE7;ASPxClientUtils.firefox=__aspxFirefox;ASPxClientUtils.firefox3=__aspxFirefox3;ASPxClientUtils.mozilla=__aspxMozilla;ASPxClientUtils.netscape=__aspxNetscape;ASPxClientUtils.ArrayInsert=_aspxArrayInsert;ASPxClientUtils.ArrayRemove=_aspxArrayRemove;ASPxClientUtils.ArrayRemoveAt=_aspxArrayRemoveAt;ASPxClientUtils.ArrayClear=_aspxArrayClear;ASPxClientUtils.ArrayIndexOf=_aspxArrayIndexOf;ASPxClientUtils.AttachEventToElement=_aspxAttachEventToElement;ASPxClientUtils.DetachEventFromElement=_aspxDetachEventFromElement;ASPxClientUtils.GetEventSource=_aspxGetEventSource;ASPxClientUtils.GetEventX=_aspxGetEventX;ASPxClientUtils.GetEventY=_aspxGetEventY;ASPxClientUtils.GetKeyCode=_aspxGetKeyCode;ASPxClientUtils.PreventEvent=_aspxPreventEvent;ASPxClientUtils.PreventEventAndBubble=_aspxPreventEventAndBubble;ASPxClientUtils.PreventDragStart=_aspxPreventDragStart;ASPxClientUtils.ClearSelection=_aspxClearSelection;ASPxClientUtils.IsExists=_aspxIsExists;ASPxClientUtils.IsFunction=_aspxIsFunction;ASPxClientUtils.GetAbsoluteX=_aspxGetAbsoluteX;ASPxClientUtils.GetAbsoluteY=_aspxGetAbsoluteY;ASPxClientUtils.SetAbsoluteX=_aspxSetAbsoluteX;ASPxClientUtils.SetAbsoluteY=_aspxSetAbsoluteY;ASPxClientUtils.GetDocumentScrollTop=_aspxGetDocumentScrollTop;ASPxClientUtils.GetDocumentScrollLeft=_aspxGetDocumentScrollLeft;ASPxClientUtils.GetDocumentClientWidth=_aspxGetDocumentClientWidth;ASPxClientUtils.GetDocumentClientHeight=_aspxGetDocumentClientHeight;ASPxClientUtils.GetIsParent=_aspxGetIsParent;ASPxClientUtils.GetParentById=_aspxGetParentById;ASPxClientUtils.GetParentByTagName=_aspxGetParentByTagName;ASPxClientUtils.GetParentByClassName=_aspxGetParentByClassName;ASPxClientUtils.GetChildById=_aspxGetChildById;ASPxClientUtils.GetChildByTagName=_aspxGetChildByTagName;function _aspxInsp(obj){alert(_aspxGetObjInfo(obj));}
function _aspxGetObjInfo(obj){var array=new Array();for(var key in obj){if(key.indexOf("on")!=0&&key.indexOf("outer")!=0&&key.indexOf("inner")!=0){try{var value=""+eval("obj."+key);if(value.indexOf("function")<0)
array.push(" "+key+" = "+value);}
catch(e){}}}
array.sort();return array.join("\t");}
var ASPxJSProfilerCallInfo=function(procName,args){this.procName=procName;this.argumentsList=(typeof(args)!="undefined"&&args!=null&&args.length>0)?args:[];this.callDate=new Date();this.exitDate=null;this.Exit=function(){this.exitDate=new Date();}
this.GetEnterInfo=function(){return this.GetInfo(">>");}
this.GetExitInfo=function(){if(this.exitDate==null)
throw'JSProfilerCallInfo Exit() method was not called.';return this.GetInfo("<<",true);}
this.GetInfo=function(prefix,writeExecutionTime){var info="";info+=prefix;info+="&nbsp;";info+="<span style=\"color: blue;\">";info+=this.procName;info+="(";info+="<span style=\"color: #F757FA;\">";for(var i=0;i<this.argumentsList.length;i++){info+=this.argumentsList[i];if(i<this.argumentsList.length-1)
info+=", ";}
info+="</span>";info+=")";info+="</span>";if(writeExecutionTime)
info+="&nbsp; (execution time: <span style=\"color: blue\">"+this.GetExecutionSeconds(this.callDate,this.exitDate)+" sec</span>)";return info;}
this.GetExecutionSeconds=function(callDate,exitDate){return(exitDate.getTime()-callDate.getTime())/1000.0;}}
var ASPxJSProfiler={callStack:[],Enter:function(procName,args){var callInfo=new ASPxJSProfilerCallInfo(procName,args);ASPxJSProfiler.WriteMessage(callInfo.GetEnterInfo());ASPxJSProfiler.callStack.push(callInfo);},Exit:function(){if(ASPxJSProfiler.callStack.length==0)
throw"CallStack is empty.";var callInfo=ASPxJSProfiler.callStack[ASPxJSProfiler.callStack.length-1];callInfo.Exit();ASPxJSProfiler.callStack.pop();ASPxJSProfiler.WriteMessage(callInfo.GetExitInfo());},CreateIndentString:function(){var indent="";for(var i=0;i<ASPxJSProfiler.callStack.length;i++)
indent+="&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";return indent;},WriteError:function(message){ASPxJSProfiler.WriteMessageCore(message,"red");},WriteWarning:function(message){ASPxJSProfiler.WriteMessageCore(message,"#E8DD44");},Write:function(message){ASPxJSProfiler.WriteMessage(message);},WriteMessage:function(message){ASPxJSProfiler.WriteMessageCore(message,"green");},WriteMessageCore:function(message,colorStr){var para=document.createElement("P");para.style.fontSize="12px";para.style.margin="1px 0";para.style.color=colorStr;para.style.whiteSpace="nowrap";para.style.fontFamily="Consolas, Arial, Tahoma";para.innerHTML=ASPxJSProfiler.CreateIndentString()+message;document.body.appendChild(para);}};var __aspxMIIdSuffix="_DXI";var __aspxMMIdSuffix="_DXM";ASPxClientMenuItemInfo=_aspxCreateClass(null,{constructor:function(menu,indexPath){this.clientHeight=0;this.clientWidth=0;this.clientTop=0;this.clientLeft=0;this.offsetHeight=0;this.offsetWidth=0;this.offsetTop=0;this.offsetLeft=__aspxAbsoluteRightPosition;var imageElement=(indexPath!="")?menu.GetItemImageCell(indexPath):null;if(imageElement!=null){this.clientWidth+=imageElement.clientWidth;this.offsetWidth+=imageElement.offsetWidth;if(this.clientLeft==0)
this.clientLeft=_aspxGetClientLeft(imageElement);if(this.offsetLeft>imageElement.offsetLeft)
this.offsetLeft=imageElement.offsetLeft;}
var indentElement=(indexPath!="")?menu.GetItemIndentCell(indexPath):null;if(indentElement!=null){this.clientWidth+=indentElement.clientWidth;this.offsetWidth+=indentElement.offsetWidth;}
var textElement=(indexPath!="")?menu.GetItemTextCell(indexPath):null;if(textElement!=null){this.clientWidth+=textElement.clientWidth;this.offsetWidth+=textElement.offsetWidth;if(this.clientLeft==0)
this.clientLeft=_aspxGetClientLeft(textElement);if(this.offsetLeft>textElement.offsetLeft)
this.offsetLeft=textElement.offsetLeft;this.clientTop=_aspxGetClientTop(textElement);this.offsetHeight+=textElement.offsetHeight;this.offsetTop=textElement.offsetTop;this.clientHeight=textElement.clientHeight;if(__aspxSafari3||__aspxChrome){if(!menu.IsVertical(indexPath))
this.clientHeight=_aspxWebKit3TDRealInfo.GetClientHeight(textElement);if(imageElement!=null&&this.clientHeight<imageElement.clientHeight)
this.clientHeight=imageElement.clientHeight;}}
var popOutImageElement=(indexPath!="")?menu.GetItemPopOutImageCell(indexPath):null;if(popOutImageElement!=null){this.clientWidth+=popOutImageElement.clientWidth;this.offsetWidth+=popOutImageElement.offsetWidth;if(this.clientLeft==0)
this.clientLeft=_aspxGetClientLeft(popOutImageElement);if(this.offsetLeft>popOutImageElement.offsetLeft)
this.offsetLeft=popOutImageElement.offsetLeft;}}});ASPxClientMenuBase=_aspxCreateClass(ASPxClientControl,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.allowSelectItem=false;this.allowCheckItems=false;this.appearAfter=300;this.animationDelay=30;this.animationMaxDelay=400;this.disappearAfter=500;this.enableAnimation=true;this.checkedItems=new Array();this.itemCheckedGroups=new Array();this.lockHoverEvents=false;this.popupToLeft=false;this.popupCount=0;this.rootItem=null;this.showLoadingPanel=true;this.showSubMenus=false;this.rootSubMenuFIXOffset=0;this.rootSubMenuFIYOffset=0;this.rootSubMenuLIXOffset=0;this.rootSubMenuLIYOffset=0;this.rootSubMenuXOffset=0;this.rootSubMenuYOffset=0;this.subMenuFIXOffset=0;this.subMenuFIYOffset=0;this.subMenuLIXOffset=0;this.subMenuLIYOffset=0;this.subMenuXOffset=0;this.subMenuYOffset=0;this.ItemClick=new ASPxClientEvent();this.ItemMouseOver=new ASPxClientEvent();this.ItemMouseOut=new ASPxClientEvent();this.PopUp=new ASPxClientEvent();this.CloseUp=new ASPxClientEvent();aspxGetMenuCollection().Add(this);},InlineInitialize:function(){this.InitializeInternal(true);this.showSubMenus=!this.IsCallbacksEnabled()||this.showLoadingPanel;},Initialize:function(){if(this.IsCallbacksEnabled())
this.CreateCallback();},InitializeInternal:function(inline){this.InitializeEnabledAndVisible(!inline||!this.IsCallbacksEnabled());this.InitializeCheckedItems();this.InitializeSelectedItem();},InitializeEnabledAndVisible:function(recursive){if(this.rootItem==null)return;for(var i=0;i<this.rootItem.items.length;i++)
this.rootItem.items[i].InitializeEnabledAndVisible(recursive);},IsCallbacksEnabled:function(){return _aspxIsFunction(this.callBack);},GetMenuElement:function(indexPath){return _aspxGetElementById(this.name+__aspxMMIdSuffix+indexPath+"_");},GetMenuIFrameElement:function(indexPath){var level=this.GetMenuLevel(indexPath);return _aspxGetElementById(this.name+"_DXMIF"+level);},GetMenuBorderCorrectorElement:function(indexPath){return _aspxGetElementById(this.name+"_DXMBC"+indexPath+"_");},GetMenuMainCell:function(element){return this.GetMenuMainTable(element).rows[0].cells[0];},GetMenuMainTable:function(element){var indexPath=this.GetIndexPathById(element.id,true);var shadowTable=_aspxGetElementById(this.name+"_DXMST"+indexPath+"_");return shadowTable!=null?shadowTable:element;},GetItemElement:function(indexPath){return _aspxGetElementById(this.name+__aspxMIIdSuffix+indexPath+"_");},GetItemTemplateCell:function(indexPath){return _aspxGetElementById(this.name+__aspxMIIdSuffix+indexPath+"_ITC");},GetItemImageCell:function(indexPath){return _aspxGetElementById(this.name+__aspxMIIdSuffix+indexPath+"_I");},GetItemIndentCell:function(indexPath){return _aspxGetElementById(this.name+__aspxMIIdSuffix+indexPath+"_N");},GetItemTextCell:function(indexPath){return _aspxGetElementById(this.name+__aspxMIIdSuffix+indexPath+"_T");},GetItemPopOutImageCell:function(indexPath){return _aspxGetElementById(this.name+__aspxMIIdSuffix+indexPath+"_P");},GetItemTextOrImageCell:function(indexPath){var element=this.GetItemTextCell(indexPath);if(element==null)
element=this.GetItemImageCell(indexPath);return element;},GetSelectedItemInputElement:function(){return _aspxGetElementById(this.name+"SI");},GetCheckedItemsInputElement:function(){return _aspxGetElementById(this.name+"CI");},GetSubMenuXPosition:function(indexPath,menuElement){var position=0;var element=null;var imageElement=this.GetItemImageCell(indexPath);var textElement=this.GetItemTextCell(indexPath);var popOutImageElement=this.GetItemPopOutImageCell(indexPath);var imagePos=_aspxGetAbsoluteX(imageElement);var textPos=_aspxGetAbsoluteX(textElement);var popOutImagePos=_aspxGetAbsoluteX(popOutImageElement);if(imageElement!=null||textElement!=null||popOutImageElement!=null){if(this.IsVertical(indexPath)){position=__aspxAbsoluteLeftPosition;if(imageElement!=null&&position<imagePos){position=imagePos;element=imageElement;}
if(textElement!=null&&position<textPos){position=textPos;element=textElement;}
if(popOutImageElement!=null&&position<popOutImagePos){position=popOutImagePos;element=popOutImageElement;}
position=_aspxGetAbsoluteX(element)+element.clientWidth;}
else{position=__aspxAbsoluteRightPosition;if(imageElement!=null&&position>imagePos){position=imagePos;element=imageElement;}
if(textElement!=null&&position>textPos){position=textPos;element=textElement;}
if(popOutImageElement!=null&&position>popOutImagePos){position=popOutImagePos;element=popOutImageElement;}}
if(element!=null&&_aspxIsExistsAbsolutePosParent(element))
position-=_aspxGetIEDocumentClientOffset(true);}
return position;},GetSubMenuYPosition:function(indexPath,menuElement){var position=0;var element=this.GetItemTextOrImageCell(indexPath);if(element!=null){if(this.IsVertical(indexPath)){position=_aspxGetAbsoluteY(element);}
else{if(__aspxNS||__aspxOpera9||__aspxSafari3||__aspxChrome)
position=_aspxGetAbsoluteY(element)+element.offsetHeight-_aspxGetClientTop(element);else if(__aspxSafariFamily)
position=_aspxGetAbsoluteY(element)+element.offsetHeight+element.offsetTop-_aspxGetClientTop(element);else
position=_aspxGetAbsoluteY(element)+element.clientHeight+_aspxGetClientTop(element);}
if(_aspxIsExistsAbsolutePosParent(element))
position-=_aspxGetIEDocumentClientOffset(false);}
return position;},GetClientSubMenuXPosition:function(element,x,indexPath){var itemInfo=new ASPxClientMenuItemInfo(this,indexPath);var itemWidth=itemInfo.clientWidth;var itemOffsetWidth=itemInfo.offsetWidth;var menuWidth=this.GetMenuMainCell(element).offsetWidth;var bodyWidth=_aspxGetDocumentClientWidth();if(this.IsVertical(indexPath)){var left=x-_aspxGetDocumentScrollLeft();var right=left+menuWidth;var toLeftX=x-menuWidth-itemWidth;var toLeftLeft=left-menuWidth-itemWidth;var toLeftRight=right-menuWidth-itemWidth;if(this.popupToLeft){if(toLeftLeft<0&&toLeftLeft<bodyWidth-right){this.popupToLeft=false;return x;}
else
return toLeftX;}
else{if(bodyWidth-right<0&&bodyWidth-right<toLeftLeft){this.popupToLeft=true;return toLeftX;}
else
return x;}}
else{var left=x-_aspxGetDocumentScrollLeft();var right=left+menuWidth;var toLeftX=x-menuWidth+itemOffsetWidth;var toLeftLeft=left-menuWidth+itemOffsetWidth;var toLeftRight=right-menuWidth+itemOffsetWidth;if(this.popupToLeft){if(toLeftLeft<0&&toLeftLeft<bodyWidth-right){this.popupToLeft=false;return x;}
else
return toLeftX;}
else{if(bodyWidth-right<0&&bodyWidth-right<toLeftLeft){this.popupToLeft=true;return toLeftX;}
else
return x;}}},GetClientSubMenuYPosition:function(element,y,indexPath){var itemInfo=new ASPxClientMenuItemInfo(this,indexPath);var itemHeight=itemInfo.clientHeight;var itemOffsetHeight=itemInfo.offsetHeight;var menuHeight=this.GetMenuMainCell(element).offsetHeight;var top=y-_aspxGetDocumentScrollTop();var bottom=top+menuHeight;var bodyHeight=_aspxGetDocumentClientHeight();if(this.IsVertical(indexPath)){menuHeight-=itemOffsetHeight-itemHeight;if(bottom>bodyHeight&&top-menuHeight+itemHeight>bodyHeight-bottom)
return y-menuHeight+itemHeight;}
else{if(bottom>bodyHeight&&top-menuHeight-itemHeight>bodyHeight-bottom)
return y-menuHeight-itemHeight;}
return y;},HasChildren:function(indexPath){return(this.GetMenuElement(indexPath)!=null);},IsVertical:function(indexPath){return true;},IsRootItem:function(indexPath){return this.GetMenuLevel(indexPath)<=1;},IsParentElementPositionStatic:function(indexPath){return this.IsRootItem(indexPath);},GetItemIndexPath:function(indexes){return aspxGetMenuCollection().GetItemIndexPath(indexes);},GetItemIndexes:function(indexPath){return aspxGetMenuCollection().GetItemIndexes(indexPath);},GetItemIndexPathById:function(id){return aspxGetMenuCollection().GetIndexPathById(id,false);},GetMenuIndexPathById:function(id){return aspxGetMenuCollection().GetIndexPathById(id,true);},GetIndexPathById:function(id,checkMenu){var indexPath=this.GetItemIndexPathById(id);if(indexPath==""&&checkMenu)
indexPath=this.GetMenuIndexPathById(id);return indexPath;},GetMenuLevel:function(indexPath){return aspxGetMenuCollection().GetMenuLevel(indexPath);},GetParentIndexPath:function(indexPath){var indexes=this.GetItemIndexes(indexPath);indexes.length--;return(indexes.length>0)?this.GetItemIndexPath(indexes):"";},GetFirstChildIndexPath:function(indexPath){var indexes=this.GetItemIndexes(indexPath);indexes[indexes.length]=0;var newIndexPath=this.GetItemIndexPath(indexes);return this.GetFirstSiblingIndexPath(newIndexPath);},GetFirstSiblingIndexPath:function(indexPath){var indexes=this.GetItemIndexes(indexPath);var i=0;while(true){indexes[indexes.length-1]=i;var newIndexPath=this.GetItemIndexPath(indexes);if(!this.IsItemExist(newIndexPath))
return null;if(this.IsItemExistAndEnabled(newIndexPath))
return newIndexPath;i++;}
return null;},GetLastSiblingIndexPath:function(indexPath){var indexes=this.GetItemIndexes(indexPath);var newIndexPath=null;var i=indexes[indexes.length-1]+1;while(true){indexes[indexes.length-1]=i;var nextIndexPath=this.GetItemIndexPath(indexes);if(!this.IsItemExist(nextIndexPath))
return newIndexPath;if(this.IsItemExistAndEnabled(nextIndexPath))
newIndexPath=nextIndexPath;i++;}
return null;},GetNextSiblingIndexPath:function(indexPath){if(this.IsLastItem(indexPath))return null;var indexes=this.GetItemIndexes(indexPath);var i=indexes[indexes.length-1]+1;while(true){indexes[indexes.length-1]=i;var newIndexPath=this.GetItemIndexPath(indexes);if(!this.IsItemExist(newIndexPath))
return null;if(this.IsItemExistAndEnabled(newIndexPath))
return newIndexPath;i++;}
return null;},GetPrevSiblingIndexPath:function(indexPath){if(this.IsFirstItem(indexPath))return null;var indexes=this.GetItemIndexes(indexPath);var i=indexes[indexes.length-1]-1;while(true){indexes[indexes.length-1]=i;var newIndexPath=this.GetItemIndexPath(indexes);if(!this.IsItemExist(newIndexPath))
return null;if(this.IsItemExistAndEnabled(newIndexPath))
return newIndexPath;i--;}
return null;},IsLastElement:function(element){return _aspxIsExists(element)&&(!_aspxIsExists(element.nextSibling)||!_aspxIsExists(element.nextSibling.tagName));},IsLastItem:function(indexPath){if(this.IsVertical(indexPath)){var itemElement=this.GetItemElement(indexPath);return this.IsLastElement(itemElement);}
else{var imageCell=this.GetItemImageCell(indexPath);if(this.IsLastElement(imageCell))
return true;var textCell=this.GetItemTextCell(indexPath);if(this.IsLastElement(textCell))
return true;var popOutImageCell=this.GetItemPopOutImageCell(indexPath);if(this.IsLastElement(popOutImageCell))
return true;return false;}},IsFirstElement:function(element){return _aspxIsExists(element)&&(!_aspxIsExists(element.previousSibling)||!_aspxIsExists(element.previousSibling.tagName));},IsFirstItem:function(indexPath){if(this.IsVertical(indexPath)){var itemElement=this.GetItemElement(indexPath);return this.IsFirstElement(itemElement);}
else{var imageCell=this.GetItemImageCell(indexPath);if(this.IsFirstElement(imageCell))
return true;var textCell=this.GetItemTextCell(indexPath);if(this.IsFirstElement(textCell))
return true;var popOutImageCell=this.GetItemPopOutImageCell(indexPath);if(this.IsFirstElement(popOutImageCell))
return true;return false;}},IsItemExist:function(indexPath){return _aspxIsExists(this.GetItemTextOrImageCell(indexPath));},IsItemExistAndEnabled:function(indexPath){var cell=this.GetItemTextOrImageCell(indexPath);if(_aspxIsExists(cell)){var link=_aspxGetChildByTagName(cell,"A",0);if(link!=null)
return!_aspxIsExists(cell.enabled)||cell.enabled;}
return false;},GetClientSubMenuPos:function(element,indexPath,pos,isXPos){if(!_aspxGetIsValidPosition(pos)){pos=isXPos?this.GetSubMenuXPosition(indexPath,element):this.GetSubMenuYPosition(indexPath,element);if(__aspxSafariFamily){if(!this.IsParentElementPositionStatic(indexPath))
pos-=isXPos?document.body.offsetLeft:document.body.offsetTop;}}
var clientPos=isXPos?this.GetClientSubMenuXPosition(element,pos,indexPath):this.GetClientSubMenuYPosition(element,pos,indexPath);var isInverted=pos!=clientPos;var offset=isXPos?this.GetSubMenuXOffset(indexPath):this.GetSubMenuYOffset(indexPath);clientPos+=isInverted?-offset:offset;clientPos-=_aspxGetPositionElementOffset(this.GetMainElement(),isXPos);return new _aspxPopupPosition(clientPos,isInverted);},GetSubMenuXOffset:function(indexPath){if(indexPath=="")
return 0;else if(this.IsRootItem(indexPath)){if(this.IsFirstItem(indexPath))
return this.rootSubMenuFIXOffset;else if(this.IsLastItem(indexPath))
return this.rootSubMenuLIXOffset;else
return this.rootSubMenuXOffset;}
else{if(this.IsFirstItem(indexPath))
return this.subMenuFIXOffset;else if(this.IsLastItem(indexPath))
return this.subMenuLIXOffset;else
return this.subMenuXOffset;}},GetSubMenuYOffset:function(indexPath){if(indexPath=="")
return 0;else if(this.IsRootItem(indexPath)){if(this.IsFirstItem(indexPath))
return this.rootSubMenuFIYOffset;else if(this.IsLastItem(indexPath))
return this.rootSubMenuLIYOffset;else
return this.rootSubMenuYOffset;}
else{if(this.IsFirstItem(indexPath))
return this.subMenuFIYOffset;else if(this.IsLastItem(indexPath))
return this.subMenuLIYOffset;else
return this.subMenuYOffset;}},ClearAppearTimer:function(){aspxGetMenuCollection().ClearAppearTimer();},ClearDisappearTimer:function(){aspxGetMenuCollection().ClearDisappearTimer();},IsAppearTimerActive:function(){return aspxGetMenuCollection().IsAppearTimerActive();},IsDisappearTimerActive:function(){return aspxGetMenuCollection().IsDisappearTimerActive();},SetAppearTimer:function(indexPath){aspxGetMenuCollection().SetAppearTimer(this.name,indexPath,this.appearAfter);},SetDisappearTimer:function(){aspxGetMenuCollection().SetDisappearTimer(this.name,this.disappearAfter);},DoItemClick:function(indexPath,hasItemLink,htmlEvent){var processOnServer=this.RaiseItemClick(indexPath,htmlEvent);if(processOnServer&&!hasItemLink)
this.SendPostBack("CLICK:"+indexPath);else{this.ClearDisappearTimer();this.ClearAppearTimer();if(!this.HasChildren(indexPath))
aspxGetMenuCollection().DoHidePopupMenus(null,-1,this.name,false,"");else if(this.IsItemEnabled(indexPath))
this.ShowSubMenu(indexPath);}},DoShowPopupMenu:function(element,x,y,indexPath){if(__aspxNS)
_aspxSetStylePosition(element,-1000,-1000);_aspxSetElementDisplay(element,true);if(this.popupCount==0)this.popupToLeft=false;var horizontalPopupPosition=this.GetClientSubMenuPos(element,indexPath,x,true);var verticalPopupPosition=this.GetClientSubMenuPos(element,indexPath,y,false);var clientX=horizontalPopupPosition.position;var clientY=verticalPopupPosition.position;var toTheLeft=horizontalPopupPosition.isInverted;var toTheTop=verticalPopupPosition.isInverted;if(this.enableAnimation){this.StartAnimation(element,indexPath,horizontalPopupPosition,verticalPopupPosition);}
else{_aspxSetStylePosition(element,clientX,clientY);_aspxSetElementVisibility(element,true);this.DoShowPopupMenuIFrame(element,clientX,clientY,__aspxInvalidDimension,__aspxInvalidDimension,indexPath);this.DoShowPopupMenuBorderCorrector(element,clientX,clientY,indexPath,toTheLeft,toTheTop);}
aspxGetMenuCollection().RegisterVisiblePopupMenu(this.name,element.id);this.popupCount++;this.RaisePopUp(indexPath);},DoShowPopupMenuIFrame:function(element,x,y,width,height,indexPath){if(!this.renderIFrameForPopupElements)return;var iFrame=element.overflowElement;if(!_aspxIsExists(iFrame)){iFrame=this.GetMenuIFrameElement(indexPath);element.overflowElement=iFrame;}
if(_aspxIsExists(iFrame)){var cell=this.GetMenuMainCell(element);if(width<0)
width=cell.offsetWidth;if(height<0)
height=cell.offsetHeight;_aspxSetStyleSize(iFrame,width,height);_aspxSetStylePosition(iFrame,x,y);_aspxSetElementDisplay(iFrame,true);}},DoShowPopupMenuBorderCorrector:function(element,x,y,indexPath,toTheLeft,toTheTop){var borderCorrectorElement=this.GetMenuBorderCorrectorElement(indexPath);if(_aspxIsExists(borderCorrectorElement)){var itemInfo=new ASPxClientMenuItemInfo(this,indexPath);var menuXOffset=_aspxGetClientLeft(this.GetMenuMainCell(element));var menuYOffset=_aspxGetClientTop(this.GetMenuMainCell(element));var menuClientWidth=this.GetMenuMainCell(element).clientWidth;var menuClientHeight=this.GetMenuMainCell(element).clientHeight;var width=0,height=0,left=0,top=0;if(this.IsVertical(indexPath)){var commonClientHeight=itemInfo.clientHeight<menuClientHeight?itemInfo.clientHeight:menuClientHeight;width=menuXOffset;height=commonClientHeight+itemInfo.clientTop-menuYOffset;left=toTheLeft?x+menuClientWidth+menuXOffset:x;top=toTheTop?y+menuClientHeight-height+menuYOffset:y+menuYOffset;}
else{var commonClientWidth=itemInfo.clientWidth<menuClientWidth?itemInfo.clientWidth:menuClientWidth;width=commonClientWidth+itemInfo.clientLeft-menuXOffset;height=menuYOffset;left=toTheLeft?x+menuClientWidth-width+menuXOffset:x+menuXOffset;top=toTheTop?y+menuClientHeight+menuYOffset:y;if(__aspxSafariFamily&&itemInfo.offsetLeft>0)
width+=itemInfo.clientLeft;}
_aspxSetStyleSize(borderCorrectorElement,width,height);_aspxSetStylePosition(borderCorrectorElement,left,top);_aspxSetElementVisibility(borderCorrectorElement,true);_aspxSetElementDisplay(borderCorrectorElement,true);element.borderCorrectorElement=borderCorrectorElement;}},DoHidePopupMenu:function(evt,element){this.DoHidePopupMenuBorderCorrector(element);this.DoHidePopupMenuIFrame(element);_aspxStopAnimation(element);_aspxSetElementVisibility(element,false);_aspxSetElementDisplay(element,false);this.CancelSubMenuItemHoverItem(element);aspxGetMenuCollection().UnregisterVisiblePopupMenu(this.name,element.id);this.popupCount--;var indexPath=this.GetIndexPathById(element.id,true);this.RaiseCloseUp(indexPath);},DoHidePopupMenuIFrame:function(element){if(!this.renderIFrameForPopupElements)return;var iFrame=element.overflowElement;if(_aspxIsExists(iFrame))
_aspxSetElementDisplay(iFrame,false);},DoHidePopupMenuBorderCorrector:function(element){var borderCorrectorElement=element.borderCorrectorElement;if(_aspxIsExists(borderCorrectorElement)){_aspxSetElementVisibility(borderCorrectorElement,false);_aspxSetElementDisplay(borderCorrectorElement,false);element.borderCorrectorElement=null;}},SetHoverElement:function(element){this.lockHoverEvents=true;aspxGetStateController().SetCurrentHoverElementBySrcElement(element);this.lockHoverEvents=false;},ApplySubMenuItemHoverItem:function(element,hoverItem,hoverElement){if(_aspxGetElementDisplay(element)&&!_aspxIsExists(element.hoverItem)){var newHoverItem=hoverItem.Clone();element.hoverItem=newHoverItem;element.hoverElement=hoverElement;newHoverItem.Apply(hoverElement);}},CancelSubMenuItemHoverItem:function(element){if(_aspxIsExists(element.hoverItem)){element.hoverItem.Cancel(element.hoverElement);element.hoverItem=null;element.hoverElement=null;}},ShowSubMenu:function(indexPath){var element=this.GetMenuElement(indexPath);if(element!=null){var level=this.GetMenuLevel(indexPath);aspxGetMenuCollection().DoHidePopupMenus(null,level-1,this.name,false,element.id);if(!_aspxGetElementDisplay(element))
this.DoShowPopupMenu(element,__aspxInvalidPosition,__aspxInvalidPosition,indexPath);}
this.ClearAppearTimer();},SelectItem:function(indexPath){var element=this.GetItemTextOrImageCell(indexPath);if(element!=null)
aspxGetStateController().SelectElementBySrcElement(element);},DeselectItem:function(indexPath){var element=this.GetItemTextOrImageCell(indexPath);if(element!=null){var hoverItem=null;var hoverElement=null;var menuElement=this.GetMenuElement(indexPath);if(menuElement!=null&&_aspxIsExists(menuElement.hoverItem)){hoverItem=menuElement.hoverItem;hoverElement=menuElement.hoverElement;this.CancelSubMenuItemHoverItem(menuElement);}
aspxGetStateController().DeselectElementBySrcElement(element);if(menuElement!=null&&hoverItem!=null)
this.ApplySubMenuItemHoverItem(menuElement,hoverItem,hoverElement);}},InitializeSelectedItem:function(){if(!this.allowSelectItem)return;var inputElement=this.GetSelectedItemInputElement();if(inputElement!=null)
this.SelectItem(inputElement.value);},SetSelectedItemInternal:function(indexPath,modifyHotTrackSelection){if(modifyHotTrackSelection)
this.SetHoverElement(null);var inputElement=this.GetSelectedItemInputElement();if(inputElement!=null){this.DeselectItem(inputElement.value);inputElement.value=indexPath;this.SelectItem(inputElement.value);}
if(modifyHotTrackSelection){var element=this.GetItemTextOrImageCell(indexPath);if(element!=null)
this.SetHoverElement(element);}},InitializeCheckedItems:function(){if(!this.allowCheckItems)return;var inputElement=this.GetCheckedItemsInputElement();if(inputElement!=null){var indexPathes=inputElement.value.split(";");for(var i=0;i<indexPathes.length;i++){if(indexPathes[i]!=""){_aspxArrayPush(this.checkedItems,indexPathes[i]);this.SelectItem(indexPathes[i]);}}}},ChangeCheckedItem:function(indexPath){this.SetHoverElement(null);var inputElement=this.GetCheckedItemsInputElement();if(inputElement!=null){var itemsGroup=this.GetItemsGroup(indexPath);if(itemsGroup!=null){if(itemsGroup.length>1){if(!this.IsCheckedItem(indexPath)){for(var i=0;i<itemsGroup.length;i++){if(itemsGroup[i]==indexPath)continue;if(this.IsCheckedItem(itemsGroup[i])){_aspxArrayRemove(this.checkedItems,itemsGroup[i]);this.DeselectItem(itemsGroup[i]);}}
this.SelectItem(indexPath);_aspxArrayPush(this.checkedItems,indexPath);}}
else{if(this.IsCheckedItem(indexPath)){_aspxArrayRemove(this.checkedItems,indexPath);this.DeselectItem(indexPath);}
else{this.SelectItem(indexPath);_aspxArrayPush(this.checkedItems,indexPath);}}
this.UpdateCheckedInputElement(inputElement);}}
var element=this.GetItemTextOrImageCell(indexPath);if(element!=null)
this.SetHoverElement(element);},GetItemsGroup:function(indexPath){for(var i=0;i<this.itemCheckedGroups.length;i++){if(_aspxArrayIndexOf(this.itemCheckedGroups[i],indexPath)>-1)
return this.itemCheckedGroups[i];}
return null;},IsCheckedItem:function(indexPath){return _aspxArrayIndexOf(this.checkedItems,indexPath)>-1;},UpdateCheckedInputElement:function(inputElement){var state="";for(var i=0;i<this.checkedItems.length;i++){state+=this.checkedItems[i];if(i<this.checkedItems.length-1)
state+=";";}
inputElement.value=state;},GetAnimationVerticalDirection:function(indexPath,popupPosition){var verticalDirection=(this.IsRootItem(indexPath)&&!this.IsVertical(indexPath))?-1:0;if(popupPosition.isInverted)verticalDirection*=-1;return verticalDirection;},GetAnimationHorizontalDirection:function(indexPath,popupPosition){var horizontalDirection=(this.IsRootItem(indexPath)&&!this.IsVertical(indexPath))?0:-1;if(popupPosition.isInverted)horizontalDirection*=-1;return horizontalDirection;},StartAnimation:function(animationDivElement,indexPath,horizontalPopupPosition,verticalPopupPosition){var element=this.GetMenuMainTable(animationDivElement);var clientX=horizontalPopupPosition.position;var clientY=verticalPopupPosition.position;_aspxInitAnimationDiv(animationDivElement,clientX,clientY,"aspxMATimer(\""+this.name+"\", "+"\""+indexPath+"\")","");var verticalDirection=this.GetAnimationVerticalDirection(indexPath,verticalPopupPosition);var horizontalDirection=this.GetAnimationHorizontalDirection(indexPath,horizontalPopupPosition);var yPos=verticalDirection*element.offsetWidth;var xPos=horizontalDirection*element.offsetHeight;_aspxSetStylePosition(element,xPos,yPos);_aspxSetElementVisibility(animationDivElement,true);this.DoShowPopupMenuIFrame(animationDivElement,clientX,clientY,0,0,indexPath);this.DoShowPopupMenuBorderCorrector(animationDivElement,clientX,clientY,indexPath,horizontalPopupPosition.isInverted,verticalPopupPosition.isInverted);animationDivElement.timerID=window.setTimeout(animationDivElement.onTimerString,this.animationDelay);},OnAnimationTimer:function(indexPath){var animationDivElement=this.GetMenuElement(indexPath);if(_aspxIsExists(animationDivElement)){var element=this.GetMenuMainTable(animationDivElement);var mainCell=this.GetMenuMainCell(element);var iframeElement=this.GetMenuIFrameElement(indexPath);_aspxOnAnimationTimer(animationDivElement,element,mainCell,iframeElement,this.animationDelay,this.animationMaxDelay,__aspxMenuAnimationAccelerator);}},OnItemClick:function(indexPath,evt){var isLinkClicked=(_aspxGetParentByTagName(_aspxGetEventSource(evt),"A")!=null);var element=this.GetItemTextOrImageCell(indexPath);var linkElement=(element!=null)?_aspxGetChildByTagName(element,"A",0):null;if(this.allowSelectItem)
this.SetSelectedItemInternal(indexPath,true);if(this.allowCheckItems)
this.ChangeCheckedItem(indexPath);this.DoItemClick(indexPath,isLinkClicked||(linkElement!=null),evt);if(!isLinkClicked&&linkElement!=null)
_aspxNavigateUrl(linkElement.href,linkElement.target);},OnAfterItemOver:function(hoverItem,hoverElement){if(hoverItem.name==""||this.lockHoverEvents||!this.showSubMenus)return;this.ClearDisappearTimer();this.ClearAppearTimer();var indexPath=this.GetMenuIndexPathById(hoverItem.name,false);if(indexPath==""){indexPath=this.GetIndexPathById(hoverItem.name,true);var level=this.GetMenuLevel(indexPath);var menuElement=this.GetMenuElement(indexPath);var id=(menuElement!=null)?menuElement.id:"";aspxGetMenuCollection().DoHidePopupMenus(null,level-1,this.name,false,id);if(hoverItem.enabled&&hoverItem.kind==__aspxHoverItemKind){this.SetAppearTimer(indexPath);this.RaiseItemMouseOver(indexPath);}}},OnBeforeItemOver:function(hoverItem,hoverElement){if(__aspxNS&&_aspxIsExists(hoverElement.offsetParent)&&hoverElement.offsetParent.style.borderCollapse=="collapse"){hoverElement.offsetParent.style.borderCollapse="separate";hoverElement.offsetParent.style.borderCollapse="collapse";}
var indexPath=this.GetItemIndexPathById(hoverItem.name);var element=this.GetMenuElement(indexPath);if(_aspxIsExists(element))this.CancelSubMenuItemHoverItem(element);},OnItemOverTimer:function(indexPath){if(this.IsAppearTimerActive()){this.ClearAppearTimer();if(this.GetItemImageCell(indexPath)!=null||this.GetItemIndentCell(indexPath)!=null||this.GetItemTextCell(indexPath)!=null||this.GetItemPopOutImageCell(indexPath)!=null){this.ShowSubMenu(indexPath);}}},OnBeforeItemDisabled:function(disabledItem,disabledElement){this.ClearAppearTimer();var indexPath=this.GetIndexPathById(disabledElement.id,false);if(indexPath!=""){var element=this.GetMenuElement(indexPath);if(element!=null)this.DoHidePopupMenu(null,element);}},OnAfterItemOut:function(hoverItem,hoverElement,newHoverElement){if(hoverItem.name==""||this.lockHoverEvents)return;if(hoverItem.IsChildElement(newHoverElement))return;var indexPath=this.GetItemIndexPathById(hoverItem.name);var element=this.GetMenuElement(indexPath);this.ClearDisappearTimer();this.ClearAppearTimer();if(element==null||!_aspxGetIsParent(element,newHoverElement))
this.SetDisappearTimer();if(element!=null)
this.ApplySubMenuItemHoverItem(element,hoverItem,hoverElement);if(indexPath!="")
this.RaiseItemMouseOut(indexPath);},OnItemOutTimer:function(){if(this.IsDisappearTimerActive()){this.ClearDisappearTimer();if(aspxGetMenuCollection().CheckFocusedElement())
this.SetDisappearTimer();else
aspxGetMenuCollection().DoHidePopupMenus(null,0,this.name,true,"");}},OnFocusedItemKeyDown:function(evt,focusedItem,focusedElement){var handled=false;var indexPath=this.GetItemIndexPathById(focusedItem.name);switch(evt.keyCode){case ASPxKey.Tab:{handled=this.FocusNextTabItem(indexPath,evt.shiftKey);break;}
case ASPxKey.Down:{if(this.IsVertical(indexPath)){this.FocusNextItem(indexPath);}
else{this.ShowSubMenu(indexPath);this.FocusItemByIndexPath(this.GetFirstChildIndexPath(indexPath));}
handled=true;break;}
case ASPxKey.Up:{if(this.IsVertical(indexPath)){this.FocusPrevItem(indexPath);}
else{this.ShowSubMenu(indexPath);this.FocusItemByIndexPath(this.GetFirstChildIndexPath(indexPath));}
handled=true;break;}
case ASPxKey.Left:{if(this.IsVertical(indexPath)){var parentIndexPath=this.GetParentIndexPath(indexPath);if(this.IsVertical(parentIndexPath)){this.FocusItemByIndexPath(parentIndexPath);}
else{this.FocusPrevItem(parentIndexPath);}}
else{this.FocusPrevItem(indexPath);}
handled=true;break;}
case ASPxKey.Right:{if(this.IsVertical(indexPath)){if(this.HasChildren(indexPath)){this.ShowSubMenu(indexPath);this.FocusItemByIndexPath(this.GetFirstChildIndexPath(indexPath));}
else{while(!this.IsRootItem(indexPath))
indexPath=this.GetParentIndexPath(indexPath);this.FocusNextItem(indexPath);}}
else{this.FocusNextItem(indexPath);}
handled=true;break;}
case ASPxKey.Esc:{var parentIndexPath=this.GetParentIndexPath(indexPath);this.FocusItemByIndexPath(parentIndexPath);var element=this.GetMenuElement(parentIndexPath);if(element!=null){this.DoHidePopupMenu(null,element);handled=true;}}}
if(handled)
_aspxPreventEventAndBubble(evt);},FocusItemByIndexPath:function(indexPath){var element=this.GetItemTextOrImageCell(indexPath);var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)_aspxSetFocus(link);},FocusNextTabItem:function(indexPath,shiftKey){if(this.IsRootItem(indexPath))return false;while(true){if(this.IsRootItem(indexPath)){if(!shiftKey){if(this.GetNextSiblingIndexPath(indexPath)!=null){this.FocusNextItem(indexPath);return true;}}
else{if(this.GetPrevSiblingIndexPath(indexPath)!=null){this.FocusPrevItem(indexPath);return true;}}
break;}
else{if(!shiftKey){if(this.GetNextSiblingIndexPath(indexPath)==null)
indexPath=this.GetParentIndexPath(indexPath);else{this.FocusNextItem(indexPath);return true;}}
else{if(this.GetPrevSiblingIndexPath(indexPath)==null)
indexPath=this.GetParentIndexPath(indexPath);else{this.FocusPrevItem(indexPath);return true;}}}}
return false;},FocusNextItem:function(indexPath){var newIndexPath=this.GetNextSiblingIndexPath(indexPath);if(newIndexPath==null)
newIndexPath=this.GetFirstSiblingIndexPath(indexPath);if(indexPath!=newIndexPath)
this.FocusItemByIndexPath(newIndexPath);},FocusPrevItem:function(indexPath){var newIndexPath=this.GetPrevSiblingIndexPath(indexPath);if(newIndexPath==null)
newIndexPath=this.GetLastSiblingIndexPath(indexPath);if(indexPath!=newIndexPath)
this.FocusItemByIndexPath(newIndexPath);},Focus:function(){this.FocusNextItem("-1");},OnCallback:function(result){for(var indexPath in result){var menuElement=this.GetMenuElement(indexPath);if(_aspxIsExists(menuElement)){var mainCell=this.GetMenuMainCell(menuElement);mainCell.innerHTML=result[indexPath];}}
this.InitializeInternal(false);this.showSubMenus=true;},CreateItems:function(itemsProperties){var itemType=this.GetClientItemType();this.rootItem=new itemType(this,null,0,"");this.rootItem.CreateItems(itemsProperties);},GetClientItemType:function(){return ASPxClientMenuItem;},GetItemByIndexPath:function(indexPath){var item=this.rootItem;if(indexPath!=""&&item!=null){var indexes=this.GetItemIndexes(indexPath);for(var i=0;i<indexes.length;i++)
item=item.GetItem(indexes[i]);}
return item;},CheckSelectedItem:function(indexPath){var selectedItem=this.GetSelectedItem();if(selectedItem!=null&&selectedItem.GetIndexPath()==indexPath)
this.SetSelectedItem(null);},SetItemChecked:function(indexPath,checked){var inputElement=this.GetCheckedItemsInputElement();if(inputElement!=null){var itemsGroup=this.GetItemsGroup(indexPath);if(itemsGroup!=null){if(!checked&&this.IsCheckedItem(indexPath)){_aspxArrayRemove(this.checkedItems,indexPath);this.DeselectItem(indexPath);}
else if(checked&&!this.IsCheckedItem(indexPath)){if(itemsGroup.length>1){for(var i=0;i<itemsGroup.length;i++){if(itemsGroup[i]==indexPath)continue;if(this.IsCheckedItem(itemsGroup[i])){_aspxArrayRemove(this.checkedItems,itemsGroup[i]);this.DeselectItem(itemsGroup[i]);}}}
this.SelectItem(indexPath);_aspxArrayPush(this.checkedItems,indexPath);}
this.UpdateCheckedInputElement(inputElement);}}},ChangeEnabledAttributes:function(indexPath,method,styleMethod){var itemElement=this.IsVertical(indexPath)?this.GetItemElement(indexPath):null;if(_aspxIsExists(itemElement))
method(itemElement,"onclick");var templateElement=this.GetItemTemplateCell(indexPath);if(_aspxIsExists(templateElement))
method(templateElement,"onclick");var imageElement=this.GetItemImageCell(indexPath);if(_aspxIsExists(imageElement)){method(imageElement,"onclick");styleMethod(imageElement,"cursor");var link=_aspxGetChildByTagName(imageElement,"A",0);if(link!=null){method(link,"onclick");method(link,"href");}}
var textElement=this.GetItemTextCell(indexPath);if(_aspxIsExists(textElement)){method(textElement,"onclick");styleMethod(textElement,"cursor");var link=_aspxGetChildByTagName(textElement,"A",0);if(link!=null){method(link,"onclick");method(link,"href");}
link=_aspxGetChildByTagName(textElement,"A",1);if(link!=null){method(link,"onclick");method(link,"href");}}
var popOutImageElement=this.GetItemPopOutImageCell(indexPath);if(_aspxIsExists(popOutImageElement)){method(popOutImageElement,"onclick");styleMethod(popOutImageElement,"cursor");}
var indentElement=this.GetItemIndentCell(indexPath);if(_aspxIsExists(indentElement)){method(indentElement,"onclick");styleMethod(indentElement,"cursor");}},IsItemEnabled:function(indexPath){var item=this.GetItemByIndexPath(indexPath);return(item!=null)?item.GetEnabled():true;},SetItemEnabled:function(indexPath,enabled,initialization){if(indexPath==""||!this.GetItemByIndexPath(indexPath).enabled)return;if(!initialization||!enabled)
this.ChangeItemEnabledStateItems(indexPath,enabled);this.ChangeItemEnabledAttributes(indexPath,enabled);},ChangeItemEnabledStateItems:function(indexPath,enabled){var element=this.GetItemTextOrImageCell(indexPath);if(element!=null)
aspxGetStateController().SetElementEnabled(element,enabled);},ChangeItemEnabledAttributes:function(indexPath,enabled){var element=this.GetItemTextOrImageCell(indexPath);if(element!=null){element.enabled=enabled;if(!enabled)
this.CheckSelectedItem(indexPath);this.ChangeEnabledAttributes(indexPath,_aspxChangeAttributesMethod(enabled),_aspxChangeStyleAttributesMethod(enabled));}},GetItemImageUrl:function(indexPath){var element=this.GetItemImageCell(indexPath);if(element!=null){var img=_aspxGetChildByTagName(element,"IMG",0);if(img!=null)
return img.src;}
element=this.GetItemTextCell(indexPath);if(element!=null){var img=_aspxGetChildByTagName(element,"IMG",0);if(img!=null)
return img.src;}
return"";},SetItemImageUrl:function(indexPath,url){var element=this.GetItemImageCell(indexPath);if(element!=null){var img=_aspxGetChildByTagName(element,"IMG",0);if(img!=null)
img.src=url;}
element=this.GetItemTextCell(indexPath);if(element!=null){var img=_aspxGetChildByTagName(element,"IMG",0);if(img!=null)
img.src=url;}},GetItemNavigateUrl:function(indexPath){var element=this.GetItemTextCell(indexPath);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
return link.href;}
element=this.GetItemImageCell(indexPath);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
return link.href;}
return"";},SetItemNavigateUrl:function(indexPath,url){var element=this.GetItemTextCell(indexPath);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
link.href=url;link=_aspxGetChildByTagName(element,"A",1);if(link!=null)
link.href=url;}
element=this.GetItemImageCell(indexPath);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
link.href=url;}},GetItemText:function(indexPath){var element=this.GetItemTextCell(indexPath);if(element!=null){var textNode=_aspxGetChildTextNode(element,0);if(textNode!=null)
return textNode.nodeValue;}
return"";},SetItemText:function(indexPath,text){var element=this.GetItemTextCell(indexPath);if(element!=null){var textNode=_aspxGetChildTextNode(element,0);if(textNode!=null)
textNode.nodeValue=text;}},SetItemVisible:function(indexPath,visible,initialization){if(indexPath==""||!this.GetItemByIndexPath(indexPath).visible)return;if(visible&&initialization)return;if(!visible)
this.CheckSelectedItem(indexPath);var element=null;if(this.IsVertical(indexPath)){element=this.GetItemElement(indexPath);if(element!=null)
_aspxSetElementDisplay(element,visible);}
else{element=this.GetItemTemplateCell(indexPath);if(element!=null)
_aspxSetElementDisplay(element,visible);element=this.GetItemImageCell(indexPath);if(element!=null)
_aspxSetElementDisplay(element,visible);element=this.GetItemTextCell(indexPath);if(element!=null)
_aspxSetElementDisplay(element,visible);element=this.GetItemPopOutImageCell(indexPath);if(element!=null)
_aspxSetElementDisplay(element,visible);}
this.SetIndentsVisiblility(indexPath);this.SetSeparatorsVisiblility(indexPath);},SetIndentsVisiblility:function(indexPath){var parent=this.GetItemByIndexPath(indexPath).parent;for(var i=0;i<parent.GetItemCount();i++){var item=parent.GetItem(i);var separatorVisible=item.GetVisible()&&this.HasNextVisibleItems(parent,i);var element=this.GetItemIndentElement(item.GetIndexPath());if(element!=null)_aspxSetElementDisplay(element,separatorVisible);}},SetSeparatorsVisiblility:function(indexPath){var parent=this.GetItemByIndexPath(indexPath).parent;for(var i=0;i<parent.GetItemCount();i++){var item=parent.GetItem(i);var separatorVisible=item.GetVisible()&&this.HasPrevVisibleItems(parent,i);var element=this.GetItemSeparatorElement(item.GetIndexPath());if(element!=null)_aspxSetElementDisplay(element,separatorVisible);element=this.GetItemSeparatorIndentElement(item.GetIndexPath());if(element!=null)_aspxSetElementDisplay(element,separatorVisible);}},HasNextVisibleItems:function(parent,index){for(var i=index+1;i<parent.GetItemCount();i++){if(parent.GetItem(i).GetVisible())
return true;}
return false;},HasPrevVisibleItems:function(parent,index){for(var i=index-1;i>=0;i--){if(parent.GetItem(i).GetVisible())
return true;}
return false;},GetItemIndentElement:function(indexPath){return _aspxGetElementById(this.name+__aspxMIIdSuffix+indexPath+"_II");},GetItemSeparatorElement:function(indexPath){return _aspxGetElementById(this.name+__aspxMIIdSuffix+indexPath+"_IS");},GetItemSeparatorIndentElement:function(indexPath){return _aspxGetElementById(this.name+__aspxMIIdSuffix+indexPath+"_ISI");},RaiseItemClick:function(indexPath,htmlEvent){var processOnServer=this.autoPostBack||this.IsServerEventAssigned("ItemClick");if(!this.ItemClick.IsEmpty()){var item=this.GetItemByIndexPath(indexPath);var htmlElement=this.GetItemTextOrImageCell(indexPath);var args=new ASPxClientMenuItemClickEventArgs(processOnServer,item,htmlElement,htmlEvent);this.ItemClick.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;},RaiseItemMouseOver:function(indexPath){if(!this.ItemMouseOver.IsEmpty()){var item=this.GetItemByIndexPath(indexPath);var htmlElement=this.GetItemTextOrImageCell(indexPath);var args=new ASPxClientMenuItemMouseEventArgs(item,htmlElement);this.ItemMouseOver.FireEvent(this,args);}},RaiseItemMouseOut:function(indexPath){if(!this.ItemMouseOut.IsEmpty()){var item=this.GetItemByIndexPath(indexPath);var htmlElement=this.GetItemTextOrImageCell(indexPath);var args=new ASPxClientMenuItemMouseEventArgs(item,htmlElement);this.ItemMouseOut.FireEvent(this,args);}},RaisePopUp:function(indexPath){var item=this.GetItemByIndexPath(indexPath);if(!this.PopUp.IsEmpty()){var args=new ASPxClientMenuItemEventArgs(false,item);this.PopUp.FireEvent(this,args);}},RaiseCloseUp:function(indexPath){var item=this.GetItemByIndexPath(indexPath);if(!this.CloseUp.IsEmpty()){var args=new ASPxClientMenuItemEventArgs(false,item);this.CloseUp.FireEvent(this,args);}},GetItemCount:function(){return(this.rootItem!=null)?this.rootItem.GetItemCount():0;},GetItem:function(index){return(this.rootItem!=null)?this.rootItem.GetItem(index):null;},GetItemByName:function(name){return(this.rootItem!=null)?this.rootItem.GetItemByName(name):null;},GetSelectedItem:function(){var inputElement=this.GetSelectedItemInputElement();if(inputElement!=null&&inputElement.value!="")
return this.GetItemByIndexPath(inputElement.value);return null;},SetSelectedItem:function(item){var indexPath=(item!=null)?item.GetIndexPath():"";this.SetSelectedItemInternal(indexPath,false);}});ASPxClientMenuBase.GetMenuCollection=function(){return aspxGetMenuCollection();}
ASPxClientMenuCollection=_aspxCreateClass(ASPxClientControlCollection,{constructor:function(){this.constructor.prototype.constructor.call(this);this.appearTimerID=-1;this.disappearTimerID=-1;this.visibleSubMenusMenuName="";this.visibleSubMenuIds=new Array();this.overXPos=-1;this.overYPos=-1;},RegisterVisiblePopupMenu:function(name,id){_aspxArrayPush(this.visibleSubMenuIds,id);this.visibleSubMenusMenuName=name;},UnregisterVisiblePopupMenu:function(name,id){_aspxArrayRemove(this.visibleSubMenuIds,id);if(this.visibleSubMenuIds.length==0)
this.visibleSubMenusMenuName="";},GetMenu:function(id){return this.Get(this.GetMenuName(id));},GetMenuName:function(id){var pos=id.lastIndexOf(__aspxMMIdSuffix);if(pos==-1)
pos=id.lastIndexOf(__aspxMIIdSuffix);if(pos>-1)
return id.substring(0,pos);return id;},GetMenuLevel:function(indexPath){if(indexPath=="")
return 0;else{var indexes=this.GetItemIndexes(indexPath);return indexes.length;}},GetMenuLevelById:function(id,isMenu){var indexPath=this.GetIndexPathById(id,isMenu);return this.GetMenuLevel(indexPath);},GetIndexPathById:function(id,isMenu){var idSuffix=isMenu?__aspxMMIdSuffix:__aspxMIIdSuffix;var pos=id.lastIndexOf(idSuffix);if(pos>-1){id=id.substring(pos+idSuffix.length);pos=id.lastIndexOf("_");if(pos>-1)
return id.substring(0,pos);}
return"";},GetItemIndexPath:function(indexes){var indexPath="";for(var i=0;i<indexes.length;i++){indexPath+=indexes[i];if(i<indexes.length-1)
indexPath+=__aspxItemIndexSeparator;}
return indexPath;},GetItemIndexes:function(indexPath){var indexes=indexPath.split(__aspxItemIndexSeparator);for(var i=0;i<indexes.length;i++)
indexes[i]=parseInt(indexes[i]);return indexes;},ClearAppearTimer:function(){this.appearTimerID=_aspxClearTimer(this.appearTimerID);},ClearDisappearTimer:function(){this.disappearTimerID=_aspxClearTimer(this.disappearTimerID);},IsAppearTimerActive:function(){return this.appearTimerID>-1;},IsDisappearTimerActive:function(){return this.disappearTimerID>-1;},SetAppearTimer:function(name,indexPath,timeout){this.appearTimerID=_aspxSetTimeout("aspxMIMOverTimer(\""+name+"\", \""+indexPath+"\")",timeout);},SetDisappearTimer:function(name,timeout){this.disappearTimerID=_aspxSetTimeout("aspxMIMOutTimer(\""+name+"\")",timeout);},GetMouseDownMenuLevel:function(evt){var srcElement=_aspxGetEventSource(evt);if(this.visibleSubMenusMenuName!=""){var element=_aspxGetParentById(srcElement,this.visibleSubMenusMenuName);if(element!=null)return 1;}
for(var i=0;i<this.visibleSubMenuIds.length;i++){var element=_aspxGetParentById(srcElement,this.visibleSubMenuIds[i]);if(element!=null)
return this.GetMenuLevelById(this.visibleSubMenuIds[i],true)+1;}
return-1;},CheckFocusedElement:function(){try{if(document.activeElement!=null){for(var i=0;i<this.visibleSubMenuIds.length;i++){var menuElement=_aspxGetElementById(this.visibleSubMenuIds[i]);if(menuElement!=null&&_aspxGetIsParent(menuElement,document.activeElement)){var tagName=document.activeElement.tagName;if(!__aspxIE||tagName=="INPUT"||tagName=="TEXTAREA"||tagName=="SELECT")
return true;}}}}catch(e){}
return false;},DoHidePopupMenus:function(evt,level,name,leavePopups,exceptId){for(var i=this.visibleSubMenuIds.length-1;i>=0;i--){var menu=this.GetMenu(this.visibleSubMenuIds[i]);if(menu!=null){var menuLevel=this.GetMenuLevelById(this.visibleSubMenuIds[i],true);if((!leavePopups||menuLevel>0)&&exceptId!=this.visibleSubMenuIds[i]){if(menuLevel>level||(menu.name!=name&&name!="")){var element=_aspxGetElementById(this.visibleSubMenuIds[i]);if(element!=null)
menu.DoHidePopupMenu(evt,element);}}}}},DoShowAtCurrentPos:function(name,indexPath){var pc=this.Get(name);var element=pc.GetMainElement();if(pc!=null&&!_aspxGetElementDisplay(element))
pc.DoShowPopupMenu(element,this.overXPos,this.overYPos,indexPath);},SaveCurrentMouseOverPos:function(evt){this.overXPos=_aspxGetEventX(evt);this.overYPos=_aspxGetEventY(evt);},OnMouseDown:function(evt){var menuLevel=this.GetMouseDownMenuLevel(evt);this.DoHidePopupMenus(evt,menuLevel,"",false,"");},HideAll:function(){this.DoHidePopupMenus(null,-1,"",false,"");}});var __aspxMCollection=null;function aspxGetMenuCollection(){if(__aspxMCollection==null)
__aspxMCollection=new ASPxClientMenuCollection();return __aspxMCollection;}
ASPxClientMenuItem=_aspxCreateClass(null,{constructor:function(menu,parent,index,name){this.menu=menu;this.parent=parent;this.index=index;this.name=name;this.enabled=true;this.clientEnabled=true;this.visible=true;this.clientVisible=true;this.items=[];this.indexPath=null;},CreateItems:function(itemsProperties){var itemType=this.menu.GetClientItemType();for(var i=0;i<itemsProperties.length;i++){var itemName=_aspxIsExists(itemsProperties[i][0])?itemsProperties[i][0]:"";var item=new itemType(this.menu,this,i,itemName);if(_aspxIsExists(itemsProperties[i][1]))
item.enabled=itemsProperties[i][1];if(_aspxIsExists(itemsProperties[i][2]))
item.clientEnabled=itemsProperties[i][2];if(_aspxIsExists(itemsProperties[i][3]))
item.visible=itemsProperties[i][3];if(_aspxIsExists(itemsProperties[i][4]))
item.clientVisible=itemsProperties[i][4];_aspxArrayPush(this.items,item);item.CreateItems(itemsProperties[i][5]);}},GetIndexPath:function(){if(this.indexPath==null){this.indexPath="";var item=this;while(item.parent!=null){this.indexPath=(this.indexPath!="")?item.index.toString()+__aspxItemIndexSeparator+this.indexPath:item.index.toString();item=item.parent;}}
return this.indexPath;},GetItemCount:function(){return this.items.length;},GetItem:function(index){return(0<=index&&index<this.items.length)?this.items[index]:null;},GetItemByName:function(name){for(var i=0;i<this.items.length;i++)
if(this.items[i].name==name)return this.items[i];for(var i=0;i<this.items.length;i++){var item=this.items[i].GetItemByName(name);if(item!=null)return item;}
return null;},GetChecked:function(){var indexPath=this.GetIndexPath();return this.menu.IsCheckedItem(indexPath);},SetChecked:function(value){var indexPath=this.GetIndexPath();this.menu.SetItemChecked(indexPath,value);},GetEnabled:function(){return this.enabled&&this.clientEnabled;},SetEnabled:function(value){if(this.clientEnabled!=value){this.clientEnabled=value;this.menu.SetItemEnabled(this.GetIndexPath(),value,false);}},GetImageUrl:function(){var indexPath=this.GetIndexPath();return this.menu.GetItemImageUrl(indexPath);},SetImageUrl:function(value){var indexPath=this.GetIndexPath();this.menu.SetItemImageUrl(indexPath,value);},GetNavigateUrl:function(){var indexPath=this.GetIndexPath();return this.menu.GetItemNavigateUrl(indexPath);},SetNavigateUrl:function(value){var indexPath=this.GetIndexPath();this.menu.SetItemNavigateUrl(indexPath,value);},GetText:function(){var indexPath=this.GetIndexPath();return this.menu.GetItemText(indexPath);},SetText:function(value){var indexPath=this.GetIndexPath();this.menu.SetItemText(indexPath,value);},GetVisible:function(){return this.visible&&this.clientVisible;},SetVisible:function(value){if(this.clientVisible!=value){this.clientVisible=value;this.menu.SetItemVisible(this.GetIndexPath(),value,false);}},InitializeEnabledAndVisible:function(recursive){this.menu.SetItemEnabled(this.GetIndexPath(),this.clientEnabled,true);this.menu.SetItemVisible(this.GetIndexPath(),this.clientVisible,true);if(recursive){for(var i=0;i<this.items.length;i++)
this.items[i].InitializeEnabledAndVisible(recursive);}}});ASPxClientMenu=_aspxCreateClass(ASPxClientMenuBase,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.isVertical=false;},IsVertical:function(indexPath){return this.isVertical||(indexPath.indexOf(__aspxItemIndexSeparator)>-1);}});ASPxClientMenuItemEventArgs=_aspxCreateClass(ASPxClientProcessingModeEventArgs,{constructor:function(processOnServer,item){this.constructor.prototype.constructor.call(this,processOnServer);this.item=item;}});ASPxClientMenuItemMouseEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(item,htmlElement){this.constructor.prototype.constructor.call(this);this.item=item;this.htmlElement=htmlElement;}});ASPxClientMenuItemClickEventArgs=_aspxCreateClass(ASPxClientMenuItemEventArgs,{constructor:function(processOnServer,item,htmlElement,htmlEvent){this.constructor.prototype.constructor.call(this,processOnServer,item);this.htmlElement=htmlElement;this.htmlEvent=htmlEvent;}});function aspxMIClick(evt,name,indexPath){var menu=aspxGetMenuCollection().Get(name);if(menu!=null)menu.OnItemClick(indexPath,evt);if(!__aspxNS)
evt.cancelBubble=true;return true;}
function aspxAMIMOver(source,args){var menu=aspxGetMenuCollection().GetMenu(args.item.name);if(menu!=null)menu.OnAfterItemOver(args.item,args.element);}
function aspxBMIMOver(source,args){var menu=aspxGetMenuCollection().GetMenu(args.item.name);if(menu!=null)menu.OnBeforeItemOver(args.item,args.element);}
function aspxMIMOverTimer(name,indexPath){var menu=aspxGetMenuCollection().Get(name);if(menu!=null)menu.OnItemOverTimer(indexPath);}
function aspxBIDisabled(source,args){var menu=aspxGetMenuCollection().GetMenu(args.item.name);if(menu!=null)menu.OnBeforeItemDisabled(args.item,args.element);}
function aspxFIKeyDown(source,args){var menu=aspxGetMenuCollection().GetMenu(args.item.name);if(menu!=null)menu.OnFocusedItemKeyDown(args.htmlEvent,args.item,args.element);}
function aspxAMIMOut(source,args){var menu=aspxGetMenuCollection().GetMenu(args.item.name);if(menu!=null)menu.OnAfterItemOut(args.item,args.element,args.toElement);}
function aspxMIMOutTimer(name){var menu=aspxGetMenuCollection().Get(name);if(menu!=null)menu.OnItemOutTimer();}
function aspxMContextMenu(evt){return _aspxCancelBubble(evt);}
_aspxAttachEventToElement(window,"load",aspxMenuWindowOnLoad);function aspxMenuWindowOnLoad(evt){aspxAddAfterSetFocusedState(aspxAMIMOver);aspxAddAfterClearFocusedState(aspxAMIMOut);aspxAddAfterSetHoverState(aspxAMIMOver);aspxAddAfterClearHoverState(aspxAMIMOut);aspxAddBeforeSetFocusedState(aspxBMIMOver);aspxAddBeforeSetHoverState(aspxBMIMOver);aspxAddBeforeDisabled(aspxBIDisabled);aspxAddFocusedItemKeyDown(aspxFIKeyDown);}
_aspxAttachEventToDocument("mousedown",aspxMenuDocumentMouseDown);function aspxMenuDocumentMouseDown(evt){return aspxGetMenuCollection().OnMouseDown(evt);}
function aspxMATimer(name,indexPath){var menu=aspxGetMenuCollection().Get(name);if(menu!=null)menu.OnAnimationTimer(indexPath);}
ASPxClientPopupMenu=_aspxCreateClass(ASPxClientMenuBase,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.popupAction="RightMouseClick";this.popupElementID="";this.popupElement=null;this.popupHorizontalOffset=0;this.popupVerticalOffset=0;this.popupHorizontalAlign=__aspxNotSetAlignIndicator;this.popupVerticalAlign=__aspxNotSetAlignIndicator;this.left=0;this.top=0;},Initialize:function(){this.GetPopupElement();ASPxClientMenuBase.prototype.Initialize.call(this);},GetPopupElement:function(){if(!_aspxIsExistsElement(this.popupElement)){this.popupElement=_aspxFindPopupElementById(this.popupElementID);if(_aspxIsExistsElement(this.popupElement)){this.popupElement.DXMenu=this;if(this.popupAction=="LeftMouseClick")
_aspxAttachEventToElement(this.popupElement,"mouseup",aspxMEvent);else if(this.popupAction=="RightMouseClick")
_aspxAttachEventToElement(this.popupElement,"contextmenu",aspxMEvent);else if(this.popupAction=="MouseOver"){_aspxAttachEventToElement(this.popupElement,"mouseover",aspxMEvent);_aspxAttachEventToElement(this.popupElement,"mouseout",aspxMEvent);}
if(this.popupAction=="LeftMouseClick"){_aspxAttachEventToElement(this.popupElement,"mousedown",aspxMEvent);this.popupElement.isPopuped=false;}}}
return this.popupElement;},IsMenuVisible:function(){var element=this.GetMainElement();return(element!=null)?_aspxGetElementDisplay(element):false;},IsParentElementPositionStatic:function(indexPath){return false;},GetClientSubMenuPos:function(element,indexPath,pos,isXPos){if(indexPath==""){var popupPosition=null;if(isXPos){popupPosition=_aspxGetPopupAbsoluteX(this.GetMenuMainCell(this.GetMainElement()),this.GetPopupElement(),this.popupHorizontalAlign,this.popupHorizontalOffset,pos,this.left);}
else{popupPosition=_aspxGetPopupAbsoluteY(this.GetMenuMainCell(this.GetMainElement()),this.GetPopupElement(),this.popupVerticalAlign,this.popupVerticalOffset,pos,this.top);}
popupPosition.position-=_aspxGetPositionElementOffset(element,isXPos);return popupPosition;}
return ASPxClientMenuBase.prototype.GetClientSubMenuPos.call(this,element,indexPath,pos,isXPos);},GetMenuElement:function(indexPath){if(indexPath=="")
return this.mainElement;return ASPxClientMenuBase.prototype.GetMenuElement.call(this,indexPath);},OnItemOverTimer:function(indexPath){if(indexPath==""){aspxGetMenuCollection().DoHidePopupMenus(null,-1,this.name,false,"");aspxGetMenuCollection().DoShowAtCurrentPos(this.name,indexPath);}
else
ASPxClientMenuBase.prototype.OnItemOverTimer.call(this,indexPath);},DoShow:function(x,y){var element=this.GetMainElement();if(element!=null&&!_aspxGetElementDisplay(element)){aspxGetMenuCollection().DoHidePopupMenus(null,-1,this.name,false,"");this.DoShowPopupMenu(element,x,y,"");}},DoShowByAPI:function(x,y){var enableAnimationBackup=this.enableAnimation;this.enableAnimation=false;this.DoShow(x,y);this.enableAnimation=enableAnimationBackup;},DoHidePopupMenu:function(evt,element){if((__aspxNS||__aspxSafariFamily)&&_aspxIsExists(evt)&&this.GetPopupElement()!=null&&_aspxIsExists(this.GetPopupElement().isPopuped)){if(_aspxFindParentPopupElementByEvent(evt,aspxTestPopupMenuElement)==this.GetPopupElement()){this.GetPopupElement().isPopuped=true;}}
ASPxClientMenuBase.prototype.DoHidePopupMenu.call(this,evt,element);},DoShowPopupMenuBorderCorrector:function(element,x,y,indexPath,toTheLeft,toTheTop){if(indexPath!="")
ASPxClientMenuBase.prototype.DoShowPopupMenuBorderCorrector.call(this,element,x,y,indexPath,toTheLeft,toTheTop);},ShowInternal:function(evt){var x=_aspxGetEventX(evt);var y=_aspxGetEventY(evt);if(evt.type=="mouseover")
aspxGetMenuCollection().SetAppearTimer(this.name,"",this.appearAfter);else
this.DoShow(x,y);},GetAnimationHorizontalDirection:function(indexPath,popupPosition){if(this.GetMenuLevel(indexPath)==0)
return _aspxGetAnimationHorizontalDirection(popupPosition,this.popupHorizontalAlign,this.popupVerticalAlign);else
return popupPosition.isInverted?1:-1;},GetAnimationVerticalDirection:function(indexPath,popupPosition){if(this.GetMenuLevel(indexPath)==0)
return _aspxGetAnimationVerticalDirection(popupPosition,this.popupHorizontalAlign,this.popupVerticalAlign);else
return 0;},ReplacePopupElementID:function(newPopupElementID){var popupElementIDBackup=this.popupElementID;this.popupElementID=newPopupElementID;this.popupElement=null;this.GetPopupElement();return popupElementIDBackup;},Hide:function(){var element=this.GetMainElement();if(element!=null)this.DoHidePopupMenu(null,element);},Show:function(){this.DoShowByAPI(__aspxInvalidPosition,__aspxInvalidPosition);},ShowAtElement:function(htmlElement){var popupElementBackup=this.popupElement;this.popupElement=htmlElement;this.DoShowByAPI(__aspxInvalidPosition,__aspxInvalidPosition);this.popupElement=popupElementBackup;},ShowAtElementByID:function(id){var htmlElement=document.getElementById(id);this.ShowAtElement(htmlElement);},ShowAtPos:function(x,y){var popupElementIDBackup=this.ReplacePopupElementID("");this.DoShowByAPI(x,y);this.ReplacePopupElementID(popupElementIDBackup);},GetVisible:function(){return this.IsMenuVisible();},SetVisible:function(visible){if(visible&&!this.IsMenuVisible())
this.Show();else if(!visible&&this.IsMenuVisible())
this.Hide();}});function aspxMEvent(evt){var element=_aspxFindParentPopupElementByEvent(evt,aspxTestPopupMenuElement);if(element!=null){if(evt.type=="mouseout")
return aspxPMOnMouseOut(evt,element);else if(evt.type=="mouseover")
return aspxPMOnMouseOver(evt,element);else if(evt.type=="mousedown")
return aspxPMOnMouseDown(evt,element);else
return aspxPMOnMouseUp(evt,element);}}
function aspxPMOnMouseDown(evt,element){if(!__aspxNS&&!__aspxSafariFamily&&_aspxIsExists(element.isPopuped))
element.isPopuped=element.DXMenu.IsMenuVisible();}
function aspxPMOnMouseUp(evt,element){if(element.DXMenu.popupAction=="RightMouseClick"||_aspxGetIsLeftButtonPressed(evt)){if(element.DXMenu.popupAction=="RightMouseClick")
_aspxPreventContextMenu(evt);if(element.isPopuped!=true)
element.DXMenu.ShowInternal(evt);else if((__aspxNS||__aspxSafariFamily)&&_aspxIsExists(element.isPopuped))
element.isPopuped=false;return _aspxCancelBubble(evt);}}
function aspxPMOnMouseOver(evt,element){if(!element.DXMenu.IsMenuVisible())
element.DXMenu.ShowInternal(evt);}
function aspxPMOnMouseOut(evt,element){if(!element.DXMenu.IsMenuVisible())
aspxGetMenuCollection().ClearAppearTimer();}
function aspxTestPopupMenuElement(element){return _aspxIsExists(element.DXMenu);}
_aspxAttachEventToDocument("mousemove",aspxPopupControlDocumentMouseMove);function aspxPopupControlDocumentMouseMove(evt){if(aspxGetMenuCollection().IsAppearTimerActive()){var element=_aspxFindParentPopupElementByEvent(evt,aspxTestPopupMenuElement);if(element!=null&&!element.DXMenu.IsMenuVisible())
aspxGetMenuCollection().SaveCurrentMouseOverPos(evt);}}
ASPxClientTabControlBase=_aspxCreateClass(ASPxClientControl,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.activeTabIndex=0;this.callbackCount=0;this.cookieName="";this.emptyHeight=false;this.emptyWidth=false;this.tabAlign="Left";this.tabPosition="Top";this.tabCount=0;this.tabs=[];this.tabsContentRequest=[];this.handleClickOnWholeTab=true;this.TabClick=new ASPxClientEvent();this.ActiveTabChanged=new ASPxClientEvent();this.ActiveTabChanging=new ASPxClientEvent();this.InitializeOnResize();},Initialize:function(){this.constructor.prototype.Initialize.call(this);this.CorrrectCellsBounds(true);},InlineInitialize:function(){this.InitializeEnabledAndVisible();this.CorrrectCellsBounds(true);},InitializeEnabledAndVisible:function(){for(var i=0;i<this.tabs.length;i++){this.SetTabVisible(i,this.tabs[i].clientVisible,true);this.SetTabEnabled(i,this.tabs[i].clientEnabled,true);}},InitializeCallBackData:function(){var element=this.GetContentElement(this.activeTabIndex);if(element!=null)element.loaded=true;},InitializeOnResize:function(){var element=this.GetMainElement();if(_aspxIsExists(element))
element.onresize=new Function("aspxTCResize(\""+this.name+"\");");},GetTabsCell:function(){return this.GetChild("_TC");},GetTabElement:function(index,active){return this.GetChild("_"+(active?"A":"")+"T"+index);},GetContentsCell:function(){return this.GetChild("_CC");},GetContentElement:function(index){return this.GetChild("_C"+index);},GetSeparatorElement:function(index){return this.GetChild("_T"+index+"S");},GetLeftAlignCellElement:function(){return this.GetChild("_LAC");},GetRightAlignCellElement:function(){return this.GetChild("_RAC");},GetTabLayoutElement:function(element){if(!this.IsTopBottomTabPosition())
return element.parentNode;return element;},GetActiveTabIndexInputElement:function(index){return _aspxGetElementById(this.name+"ATI");},IsTopBottomTabPosition:function(){return(this.tabPosition=="Top"||this.tabPosition=="Bottom");},CorrrectCellsBounds:function(initialization){if(this.isInitialized||initialization)
window.setTimeout("aspxTCCorrectBounds(\""+this.name+"\");",1);},CorrrectCellsBoundsTimer:function(){var mainElement=this.GetMainElement();if(mainElement==null||mainElement.offsetWidth==0||mainElement.offsetHeight==0)return;mainElement.corrected=true;if(__aspxIE&&!this.emptyHeight&&this.tabAlign!="Justify"){if(this.IsTopBottomTabPosition())
this.CorrectContentCellHeight();else
this.CorrectAlignCellsHeight();}
if(this.emptyHeight&&!this.IsTopBottomTabPosition()){this.CorrectTabsCellHeight();if(__aspxIE)
this.CorrectAlignCellsHeight();}
if(this.emptyWidth&&this.IsTopBottomTabPosition()&&this.tabAlign!="Justify")
this.CorrectTabsCellWidth();this.CorrectOperaTabsCellAlignment();this.CorrectOperaTabCellsAlignment();},CorrectTabsCellHeight:function(){var mainElement=this.GetMainElement();var tabsCell=this.GetTabsCell();if(mainElement!=null&&tabsCell){var leftAlignCell=this.GetLeftAlignCellElement();if(leftAlignCell!=null)
leftAlignCell.style.height="auto";var rightAlignCell=this.GetRightAlignCellElement();if(rightAlignCell!=null)
rightAlignCell.style.height="auto";tabsCell.style.height="auto";tabsCell.style.height=mainElement.offsetHeight+"px";if(leftAlignCell!=null&&rightAlignCell==null)
leftAlignCell.style.height="100%";if(leftAlignCell==null&&rightAlignCell!=null)
rightAlignCell.style.height="100%";if(leftAlignCell!=null&&rightAlignCell!=null){leftAlignCell.style.height="50%";rightAlignCell.style.height="50%";}}},CorrectTabsCellWidth:function(){var mainElement=this.GetMainElement();var tabsCell=this.GetTabsCell();if(mainElement!=null&&tabsCell){var leftAlignCell=this.GetLeftAlignCellElement();if(leftAlignCell!=null)
leftAlignCell.style.width="auto";var rightAlignCell=this.GetRightAlignCellElement();if(rightAlignCell!=null)
rightAlignCell.style.width="auto";tabsCell.style.width="auto";tabsCell.style.width=mainElement.clientWidth;if(leftAlignCell!=null&&rightAlignCell==null)
leftAlignCell.style.width="100%";if(leftAlignCell==null&&rightAlignCell!=null)
rightAlignCell.style.width="100%";if(leftAlignCell!=null&&rightAlignCell!=null){leftAlignCell.style.width="50%";rightAlignCell.style.width="50%";}}},CorrectContentCellHeight:function(){var mainElement=this.GetMainElement();var tabsCell=this.GetTabsCell();var contentsCell=this.GetContentsCell();if(mainElement!=null&&tabsCell!=null&&contentsCell!=null){var tabsHeight=tabsCell.clientHeight;tabsCell.style.height=tabsHeight+"px";contentsCell.style.height="auto";contentsCell.style.height=(mainElement.clientHeight-tabsHeight)+"px";}},CorrectAlignCellsHeight:function(){var mainElement=this.GetMainElement();var tabsCell=this.GetTabsCell();if(mainElement!=null&&tabsCell!=null){var leftAlignCell=this.GetLeftAlignCellElement();var rightAlignCell=this.GetRightAlignCellElement();var tabsTable=tabsCell.firstChild;if(tabsTable!=null){if(leftAlignCell!=null||rightAlignCell!=null){var tabsHeight=0;for(var i=0;i<tabsTable.rows.length;i++){var cell=tabsTable.rows[i].cells[0];if(cell!=leftAlignCell&&cell!=rightAlignCell)
tabsHeight+=cell.offsetHeight;}
if(leftAlignCell!=null)
leftAlignCell.style.height="auto";if(rightAlignCell!=null)
rightAlignCell.style.height="auto";var correctionHeight=mainElement.clientHeight-tabsHeight;if(leftAlignCell!=null)
leftAlignCell.style.height=((rightAlignCell!=null)?Math.round(correctionHeight/2):correctionHeight)+"px";if(rightAlignCell!=null)
rightAlignCell.style.height=((leftAlignCell!=null)?Math.round(correctionHeight/2):correctionHeight)+"px";}}}},CorrectOperaTabsCellAlignment:function(){if(!__aspxOpera||this.tabAlign!="Justify")return;if(!this.IsTopBottomTabPosition()&&!this.emptyHeight)return;var element=this.GetTabsCell();_aspxSetElementDisplay(element,false);_aspxSetElementDisplay(element,true);},CorrectOperaTabCellsAlignment:function(){if(!__aspxOpera||!this.IsTopBottomTabPosition())return;var element=this.GetLeftAlignCellElement();if(element!=null){_aspxSetElementDisplay(element,false);_aspxSetElementDisplay(element,true);}
element=this.GetRightAlignCellElement();if(element!=null){_aspxSetElementDisplay(element,false);_aspxSetElementDisplay(element,true);}
for(var i=0;i<this.tabCount;i++){if(this.activeTabIndex==i)continue;element=this.GetTabElement(i,false);if(element!=null){_aspxSetElementDisplay(element,false);_aspxSetElementDisplay(element,true);}}},FixControlSize:function(){this.FixElementSize(this.GetMainElement());this.FixElementSize(this.GetContentsCell());},UnfixControlSize:function(){this.UnfixElementSize(this.GetMainElement());this.UnfixElementSize(this.GetContentsCell());},FixElementSize:function(element){if(element==null)return;_aspxChangeStyleAttribute(element,"width",(__aspxIE?element.clientWidth:element.offsetWidth)+"px");_aspxChangeStyleAttribute(element,"height",(__aspxIE?element.clientHeight:element.offsetHeight)+"px");},UnfixElementSize:function(element){if(element==null)return;_aspxRestoreStyleAttribute(element,"width");_aspxRestoreStyleAttribute(element,"height");},ChangeTabState:function(index,active){var element=this.GetTabElement(index,true);if(element!=null)_aspxSetElementDisplay(this.GetTabLayoutElement(element),active);element=this.GetTabElement(index,false);if(element!=null)_aspxSetElementDisplay(this.GetTabLayoutElement(element),!active);element=this.GetContentElement(index);if(element!=null)_aspxSetElementDisplay(element,active);},ChangeActiveTab:function(index,hasLink){var processingMode=this.RaiseActiveTabChanging(index);if(processingMode=="Client"){var element=this.GetContentElement(index);if(_aspxIsFunction(this.callBack)&&element!=null&&!element.loaded){if(this.callbackCount==0)
this.FixControlSize();this.DoChangeActiveTab(index);if(!element.loading){this.callbackCount++;element.loading=true;this.CreateLoadingPanelWithAbsolutePosition(element,this.GetContentsCell());this.CreateCallback(index);_aspxArrayPush(this.tabsContentRequest,index);}
this.CorrectOperaTabCellsAlignment();}
else{this.DoChangeActiveTab(index);this.CorrrectCellsBounds(false);this.CorrectOperaTabCellsAlignment();var activeContentElement=this.GetContentElement(this.activeTabIndex);var collection=aspxGetControlCollection();collection.AdjustControls(activeContentElement,__aspxCheckSizeCorrectedFlag);this.RaiseActiveTabChanged(index);}}
else if(processingMode=="Server"&&!hasLink)
this.SendPostBack("ACTIVATE:"+index);},DoChangeActiveTab:function(index){if(__aspxFirefox3){var contentsCell=this.GetContentsCell();var isContentsCellExists=_aspxIsExistsElement(contentsCell);if(isContentsCellExists)
_aspxSetElementVisibility(contentsCell,false);this.ChangeTabState(index,true);this.ChangeTabState(this.activeTabIndex,false);this.activeTabIndex=index;if(isContentsCellExists)
_aspxSetElementVisibility(contentsCell,true);}else{this.ChangeTabState(this.activeTabIndex,false);this.activeTabIndex=index;this.ChangeTabState(this.activeTabIndex,true);}
this.UpdateActiveTabIndexInputElement();this.UpdateActiveTabIndexCookie();},SetActiveTabIndexInternal:function(index,hasLink){if(this.activeTabIndex==index)return;var lastScrollYPos=_aspxGetDocumentScrollTop();this.ChangeActiveTab(index,hasLink);var scrollY=_aspxGetDocumentScrollTop();if(lastScrollYPos!=scrollY)
window.scrollTo(_aspxGetDocumentScrollLeft(),lastScrollYPos);this.UpdateHoverState(index);},UpdateActiveTabIndexCookie:function(){if(this.cookieName=="")return;_aspxDelCookie(this.cookieName);_aspxSetCookie(this.cookieName,this.activeTabIndex);},UpdateActiveTabIndexInputElement:function(){var element=this.GetActiveTabIndexInputElement();if(element!=null)element.value=this.activeTabIndex;},UpdateHoverState:function(index){var element=this.GetTabElement(index,true);if(element!=null)aspxGetStateController().SetCurrentHoverElementBySrcElement(element);},OnResize:function(){var mainElement=this.GetMainElement();if(mainElement!=null&&!_aspxIsExists(mainElement.corrected))
this.CorrrectCellsBounds(false);},OnTabClick:function(evt,index){var processingMode=this.RaiseTabClick(index,evt);var isLinkClicked=(_aspxGetParentByTagName(_aspxGetEventSource(evt),"A")!=null);var element=this.GetTabElement(index,false);var linkElement=(element!=null)?_aspxGetChildByTagName(element,"A",0):null;if(processingMode!="Handled"){var hasLink=isLinkClicked||linkElement!=null;if(processingMode=="Server"&&!hasLink)
this.SendPostBack("CLICK:"+index);else
this.SetActiveTabIndexInternal(index,hasLink);if(this.handleClickOnWholeTab&&!isLinkClicked&&linkElement!=null)
_aspxNavigateUrl(linkElement.href,linkElement.target);return true;}
return false;},OnCallbackInternal:function(html,index,isError){this.SetCallbackContent(html,index,isError);if(!isError)
this.RaiseActiveTabChanged(index);_aspxArrayRemoveAt(this.tabsContentRequest,0);},OnCallback:function(result){this.OnCallbackInternal(result.html,result.index,false);},OnCallbackError:function(result,data){this.OnCallbackInternal(result,data,true);},OnCallbackGeneralError:function(result){var callbackTabIndex=(this.tabsContentRequest.length>0)?this.tabsContentRequest[0]:this.activeTabIndex;this.SetCallbackContent(result,callbackTabIndex,true);_aspxArrayRemoveAt(this.tabsContentRequest,0);},SetCallbackContent:function(html,index,isError){var element=this.GetContentElement(index);if(element!=null){if(!isError)
element.loaded=true;element.loading=false;element.innerHTML=html;this.callbackCount--;if(this.callbackCount==0){this.UnfixControlSize();this.CorrrectCellsBounds(false);this.CorrectOperaTabCellsAlignment();}}},CreateTabs:function(tabsProperties){for(var i=0;i<tabsProperties.length;i++){var tabName=_aspxIsExists(tabsProperties[i][0])?tabsProperties[i][0]:"";var tab=new ASPxClientTab(this,i,tabName);if(_aspxIsExists(tabsProperties[i][1]))
tab.enabled=tabsProperties[i][1];if(_aspxIsExists(tabsProperties[i][2]))
tab.clientEnabled=tabsProperties[i][2];if(_aspxIsExists(tabsProperties[i][3]))
tab.visible=tabsProperties[i][3];if(_aspxIsExists(tabsProperties[i][4]))
tab.clientVisible=tabsProperties[i][4];_aspxArrayPush(this.tabs,tab);}},RaiseTabClick:function(index,htmlEvent){var processingMode=this.autoPostBack||this.IsServerEventAssigned("TabClick")?"Server":"Client";if(!this.TabClick.IsEmpty()){var htmlElement=this.GetTabElement(index,this.activeTabIndex==index);var args=new ASPxClientTabControlTabClickEventArgs(processingMode=="Server",this.GetTab(index),htmlElement,htmlEvent);this.TabClick.FireEvent(this,args);if(args.cancel)
processingMode="Handled";else
processingMode=args.processOnServer?"Server":"Client";}
return processingMode;},RaiseActiveTabChanged:function(index){if(!this.ActiveTabChanged.IsEmpty()){var args=new ASPxClientTabControlTabEventArgs(this.GetTab(index));this.ActiveTabChanged.FireEvent(this,args);}},RaiseActiveTabChanging:function(index){var processingMode=this.autoPostBack?"Server":"Client";if(!this.ActiveTabChanging.IsEmpty()){var args=new ASPxClientTabControlTabCancelEventArgs(processingMode=="Server",this.GetTab(index));this.ActiveTabChanging.FireEvent(this,args);if(args.cancel)
processingMode="Handled";else
processingMode=args.processOnServer?"Server":"Client";}
return processingMode;},GetActiveTab:function(){return(this.activeTabIndex>-1)?this.GetTab(this.activeTabIndex):null;},SetActiveTab:function(tab){if(this.IsTabVisible(tab.index))
this.SetActiveTabIndexInternal(tab.index,false);},GetTabCount:function(){return this.tabs.length;},GetTab:function(index){return(0<=index&&index<this.tabs.length)?this.tabs[index]:null;},GetTabByName:function(name){for(var i=0;i<this.tabs.length;i++)
if(this.tabs[i].name==name)return this.tabs[i];return null;},IsTabEnabled:function(index){return this.tabs[index].GetEnabled();},SetTabEnabled:function(index,enabled,initialization){if(!this.tabs[index].enabled)return;if(!initialization||!enabled)
this.ChangeTabEnabledStateItems(index,enabled);this.ChangeTabEnabledAttributes(index,enabled);},ChangeTabEnabledAttributes:function(index,enabled){if(enabled){this.ChangeTabElementsEnabledAttributes(index,_aspxRestoreAttribute,_aspxRestoreStyleAttribute);if(!this.IsTabEnabled(this.activeTabIndex)&&this.IsTabVisible(index))
this.SetActiveTabIndexInternal(index,false);}
else{if(this.activeTabIndex==index){for(var i=0;i<this.GetTabCount();i++){if(this.IsTabVisible(i)&&this.IsTabEnabled(i)&&i!=index){this.SetActiveTabIndexInternal(i,false);break;}}}
this.ChangeTabElementsEnabledAttributes(index,_aspxResetAttribute,_aspxResetStyleAttribute);}},ChangeTabElementsEnabledAttributes:function(index,method,styleMethod){var element=this.GetTabElement(index,false);if(_aspxIsExists(element)){method(element,"onclick");styleMethod(element,"cursor");var link=_aspxGetChildByTagName(element,"A",0);if(link!=null){method(link,"href");styleMethod(link,"cursor");}
link=_aspxGetChildByTagName(element,"A",1);if(link!=null){method(link,"href");styleMethod(link,"cursor");}}
var activeElement=this.GetTabElement(index,true);if(_aspxIsExists(activeElement)){method(activeElement,"onclick");styleMethod(activeElement,"cursor");}},ChangeTabEnabledStateItems:function(index,enabled){var element=this.GetTabElement(index,false);if(element!=null)
aspxGetStateController().SetElementEnabled(element,enabled);var activeElement=this.GetTabElement(index,true);if(activeElement!=null)
aspxGetStateController().SetElementEnabled(activeElement,enabled);},GetTabTextCell:function(index,active){return this.GetChild("_"+(active?"A":"")+"T"+index+"T");},GetTabImageCell:function(index,active){return this.GetChild("_"+(active?"A":"")+"T"+index+"I");},GetTabImageUrl:function(index,active){var element=this.GetTabImageCell(index,active);if(element!=null){var img=_aspxGetChildByTagName(element,"IMG",0);if(img!=null)
return img.src;}
return"";},SetTabImageUrl:function(index,active,url){var element=this.GetTabImageCell(index,active);if(element!=null){var img=_aspxGetChildByTagName(element,"IMG",0);if(img!=null)
img.src=url;}},GetTabNavigateUrl:function(index){var element=this.GetTabTextCell(index,false);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
return link.href;}
element=this.GetTabImageCell(index,false);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
return link.href;}
return"";},SetTabNavigateUrl:function(index,url){var element=this.GetTabTextCell(index,false);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
link.href=url;}
var element=this.GetTabImageCell(index,false);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
link.href=url;}},GetTabText:function(index){var element=this.GetTabTextCell(index,false);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
return link.innerHTML;else{var span=_aspxGetChildByTagName(element,"SPAN",0);if(span!=null)
return span.innerHTML;else
return element.innerHTML;}}
return"";},SetTabText:function(index,text){var element=this.GetTabTextCell(index,false);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
link.innerHTML=text;else{var span=_aspxGetChildByTagName(element,"SPAN",0);if(span!=null)
span.innerHTML=text;else
element.innerHTML=text;}}
element=this.GetTabTextCell(index,true);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
link.innerHTML=text;else{var span=_aspxGetChildByTagName(element,"SPAN",0);if(span!=null)
span.innerHTML=text;else
element.innerHTML=text;}}},IsTabVisible:function(index){return this.tabs[index].GetVisible();},SetTabVisible:function(index,visible,initialization){if(!this.tabs[index].visible)return;if(visible&&initialization)return;var element=this.GetTabElement(index,false);if(element!=null)element=this.GetTabLayoutElement(element);var activeElement=this.GetTabElement(index,true);if(activeElement!=null)activeElement=this.GetTabLayoutElement(activeElement);var contentElement=this.GetContentElement(index);if(!visible){if(this.activeTabIndex==index){for(var i=0;i<this.GetTabCount();i++){if(this.IsTabVisible(i)&&this.IsTabEnabled(i)&&i!=index){this.SetActiveTabIndexInternal(i,false);break;}}
for(var i=0;i<this.GetTabCount();i++){if(this.IsTabVisible(i)&&i!=index){this.SetActiveTabIndexInternal(i,false);break;}}
if(this.activeTabIndex==index){this.activeTabIndex=-1;_aspxSetElementDisplay(this.GetMainElement(),false);}}
if(element!=null)
_aspxSetElementDisplay(element,false);if(activeElement!=null)
_aspxSetElementDisplay(activeElement,false);if(contentElement!=null)
_aspxSetElementDisplay(contentElement,false);}
else{if(element!=null)
_aspxSetElementDisplay(element,this.activeTabIndex!=index);if(activeElement!=null)
_aspxSetElementDisplay(activeElement,this.activeTabIndex==index);if(contentElement!=null)
_aspxSetElementDisplay(contentElement,this.activeTabIndex==index);if(this.activeTabIndex==-1){_aspxSetElementDisplay(this.GetMainElement(),true);this.SetActiveTabIndexInternal(index,false);}
else if(!this.IsTabEnabled(this.activeTabIndex)&&this.IsTabEnabled(index))
this.SetActiveTabIndexInternal(index,false);}
this.SetSeparatorsVisiblility();this.CorrrectCellsBounds(false);},SetSeparatorsVisiblility:function(){for(var i=0;i<this.tabs.length;i++){var separatorVisible=this.tabs[i].GetVisible()&&this.HasNextVisibleTabs(i);var separatorElement=this.GetSeparatorElement(i);if(separatorElement!=null){separatorElement=this.GetTabLayoutElement(separatorElement);_aspxSetElementDisplay(separatorElement,separatorVisible);}}},HasNextVisibleTabs:function(index){for(var i=index+1;i<this.tabs.length;i++){if(this.tabs[i].GetVisible())
return true;}
return false;}});ASPxClientTabControl=_aspxCreateClass(ASPxClientTabControlBase,{});ASPxClientPageControl=_aspxCreateClass(ASPxClientTabControlBase,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.handleClickOnWholeTab=false;},GetTabContentHTML:function(tab){var element=this.GetContentElement(tab.index);return(element!=null)?element.innerHTML:"";},SetTabContentHTML:function(tab,html){var element=this.GetContentElement(tab.index);if(element!=null){element.innerHTML=html;this.CorrrectCellsBounds(false);}}});ASPxClientTab=_aspxCreateClass(null,{constructor:function(tabControl,index,name){this.tabControl=tabControl;this.index=index;this.name=name;this.enabled=true;this.clientEnabled=true;this.visible=true;this.clientVisible=true;},GetEnabled:function(){return this.enabled&&this.clientEnabled;},SetEnabled:function(value){if(this.clientEnabled!=value){this.clientEnabled=value;this.tabControl.SetTabEnabled(this.index,value,false);}},GetImageUrl:function(active){if(!_aspxIsExists(active))active=false;return this.tabControl.GetTabImageUrl(this.index,active);},SetImageUrl:function(value,active){if(!_aspxIsExists(active))active=false;this.tabControl.SetTabImageUrl(this.index,active,value);},GetActiveImageUrl:function(){return this.tabControl.GetTabImageUrl(this.index,true);},SetActiveImageUrl:function(value){this.tabControl.SetTabImageUrl(this.index,true,value);},GetNavigateUrl:function(){return this.tabControl.GetTabNavigateUrl(this.index);},SetNavigateUrl:function(value){this.tabControl.SetTabNavigateUrl(this.index,value);},GetText:function(){return this.tabControl.GetTabText(this.index);},SetText:function(value){this.tabControl.SetTabText(this.index,value);},GetVisible:function(){return this.visible&&this.clientVisible;},SetVisible:function(value){if(this.clientVisible!=value){this.clientVisible=value;this.tabControl.SetTabVisible(this.index,value,false);}}});ASPxClientTabControlTabEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(tab,htmlElement,htmlEvent){this.constructor.prototype.constructor.call(this);this.tab=tab;}});ASPxClientTabControlTabCancelEventArgs=_aspxCreateClass(ASPxClientCancelEventArgs,{constructor:function(processOnServer,tab){this.constructor.prototype.constructor.call(this,processOnServer);this.tab=tab;}});ASPxClientTabControlTabClickEventArgs=_aspxCreateClass(ASPxClientTabControlTabCancelEventArgs,{constructor:function(processOnServer,tab,htmlElement,htmlEvent){this.constructor.prototype.constructor.call(this,processOnServer,tab);this.htmlElement=htmlElement;this.htmlEvent=htmlEvent;}});function aspxTCResize(name){var tc=aspxGetControlCollection().Get(name);if(tc!=null)tc.OnResize();}
function aspxTCCorrectBounds(name){var tc=aspxGetControlCollection().Get(name);if(tc!=null)tc.CorrrectCellsBoundsTimer();}
function aspxTCTClick(evt,name,index){var tc=aspxGetControlCollection().Get(name);if(tc!=null){if(!__aspxNS)
evt.cancelBubble=true;return tc.OnTabClick(evt,index);}
return true;}
ASPxClientNavBar=_aspxCreateClass(ASPxClientControl,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.animationOffset=10;this.animationDelay=10;this.animationMaxDelay=400;this.autoCollapse=false;this.allowExpanding=true;this.allowSelectItem=false;this.cookieName="";this.groupCount=0;this.enableAnimation=false;this.groups=[];this.groupsExpanding=new Array();this.groupsExpandingRequest=[];this.ItemClick=new ASPxClientEvent();this.ExpandedChanged=new ASPxClientEvent();this.ExpandedChanging=new ASPxClientEvent();this.HeaderClick=new ASPxClientEvent();},InlineInitialize:function(){this.InitializeEnabledAndVisible();this.InitializeSelectedItem();},InitializeEnabledAndVisible:function(){for(var i=0;i<this.groups.length;i++){var group=this.groups[i];for(var j=0;j<group.items.length;j++){this.SetItemEnabled(i,j,group.items[j].clientEnabled,true);this.SetItemVisible(i,j,group.items[j].clientVisible,true);}
this.SetGroupVisible(i,group.clientVisible,true);}},InitializeSelectedItem:function(){if(!this.allowSelectItem)return;var inputElement=this.GetSelectedItemInputElement();if(inputElement!=null){var element=this.GetItemTextElementByIndexPath(inputElement.value);if(element!=null)
aspxGetStateController().SelectElementBySrcElement(element);}},InitializeCallBackData:function(){for(var i=0;i<this.GetGroupCountCore();i++){if(this.groupsExpanding[i]){var element=this.GetGroupContentElement(i);if(element!=null)element.loaded=true;}}},GetClickableGroupHeaderElement:function(index){var isDisplayed=false;var element=this.GetGroupHeaderExpandedElement(index);if(element!=null)isDisplayed=!_aspxGetElementDisplay(element)||!this.allowExpanding;if(!isDisplayed)
element=this.GetGroupHeaderCollapsedElement(index);return element;},GetGroupHeaderExpandedElement:function(index){return this.GetChild("_GHE"+index);},GetGroupHeaderCollapsedElement:function(index){return this.GetChild("_GHC"+index);},GetGroupContentElement:function(index){return this.GetChild("_GC"+index);},GetGroupContentAnimationElement:function(index){return this.GetChild("_GCA"+index);},GetRowElement:function(cellElement){return cellElement.parentNode;},GetItemElement:function(groupIndex,itemIndex){return this.GetChild("_I"+this.GetIndexPath(groupIndex,itemIndex)+"_");},GetItemSeparatorElement:function(groupIndex,itemIndex){return this.GetChild("_I"+this.GetIndexPath(groupIndex,itemIndex)+"S");},GetItemTextElementByIndexPath:function(indexPath){return this.GetChild("_I"+indexPath+"_T");},GetItemImageElementByIndexPath:function(indexPath){return this.GetChild("_I"+indexPath+"_I");},GetGroupRow:function(groupIndex){return this.GetChild("_GR"+groupIndex);},GetGroupSeparatorRow:function(groupIndex){return this.GetChild("_GSR"+groupIndex);},GetGroupStateInputElement:function(index){return _aspxGetElementById(this.name+"GS");},GetSelectedItemInputElement:function(){return _aspxGetElementById(this.name+"SI");},DoItemClick:function(groupIndex,itemIndex,hasItemLink,htmlEvent){var processOnServer=this.RaiseItemClick(groupIndex,itemIndex,htmlEvent);if(processOnServer&&!hasItemLink)
this.SendPostBack("CLICK:"+this.GetIndexPath(groupIndex,itemIndex));},SetExpandedInternal:function(groupIndex,expanded){if(expanded==this.groupsExpanding[groupIndex])return;var processingMode=this.RaiseExpandedChanging(groupIndex);if(processingMode=="Client"){if(expanded||!this.autoCollapse){if(this.autoCollapse){for(var i=0;i<this.GetGroupCountCore();i++){if(i!=groupIndex&&this.groupsExpanding[i])
this.ChangeExpanding(i,false);}}
this.ChangeExpanding(groupIndex,expanded);}}
else if(processingMode=="Server")
this.SendPostBack("EXPAND:"+groupIndex);},ChangeExpanding:function(groupIndex,expanded){var element=this.GetGroupContentElement(groupIndex);if(expanded&&_aspxIsFunction(this.callBack)&&element!=null&&!element.loaded){this.DoChangeExpanding(groupIndex,expanded,false);if(!element.loading){element.loading=true;this.CreateLoadingPanelInsideContainer(this.GetGroupContentElement(groupIndex));this.CreateCallback(groupIndex);_aspxArrayPush(this.groupsExpandingRequest,groupIndex);}}
else{this.DoChangeExpanding(groupIndex,expanded,this.enableAnimation);if(!this.enableAnimation)
this.RaiseExpandedChanged(groupIndex);}},DoChangeExpanding:function(groupIndex,expanded,doAnimation){if(doAnimation){var element=this.GetGroupContentAnimationElement(groupIndex);var contentElement=this.GetGroupContentElement(groupIndex);if(element!=null&&contentElement!=null){if(expanded){element.style.height="0px";_aspxSetElementDisplay(this.GetRowElement(contentElement),true);if(__aspxNS&&!__aspxFirefox){var innerElement=_aspxGetChildByTagName(element,"TABLE",0);if(innerElement!=null)
element.style.width=innerElement.offsetWidth+"px";else{innerElement=_aspxGetChildByTagName(element,"UL",0);if(innerElement!=null)
element.style.width=element.clientWidth+"px";}}}
else{element.style.height=element.offsetHeight+"px";}
element.style.overflow="hidden";element.expanding=expanded;element.animationCount=1;element.animationStart=new Date();element.timerID=window.setTimeout("aspxNBAnimT(\""+this.name+"\", "+groupIndex+")",this.animationDelay);}
else
this.ChangeGroupExpandState(groupIndex,expanded);}
else
this.ChangeGroupExpandState(groupIndex,expanded);},ChangeGroupExpandState:function(groupIndex,expanded){this.DoChangeGroupExpandState(groupIndex,expanded);if(expanded)
aspxGetControlCollection().AdjustControls(this.GetGroupContentElement(groupIndex),__aspxCheckSizeCorrectedFlag);},DoChangeGroupExpandState:function(groupIndex,expanded){var element=this.GetGroupContentElement(groupIndex);if(element!=null)_aspxSetElementDisplay(this.GetRowElement(element),expanded);element=this.GetGroupHeaderExpandedElement(groupIndex);if(element!=null)_aspxSetElementDisplay(this.GetRowElement(element),expanded);element=this.GetGroupHeaderCollapsedElement(groupIndex);if(element!=null)_aspxSetElementDisplay(this.GetRowElement(element),!expanded);this.groupsExpanding[groupIndex]=expanded;this.UpdateGroupStateInputElement();this.UpdateGroupStateCookie();},GetGroupCountCore:function(){return(this.groups.length>0)?this.groups.length:this.groupCount;},GetIndexPath:function(groupIndex,itemIndex){return(groupIndex!=-1&&itemIndex!=-1)?groupIndex+__aspxItemIndexSeparator+itemIndex:"";},GetGroupIndex:function(indexPath){var indexes=indexPath.split(__aspxItemIndexSeparator);return(indexes.length>0)?indexes[0]:-1;},GetItemIndex:function(indexPath){var indexes=indexPath.split(__aspxItemIndexSeparator);return(indexes.length>1)?indexes[1]:-1;},GetGroupState:function(){var state="";for(var i=0;i<this.GetGroupCountCore();i++){state+=this.groupsExpanding[i]?"1":"0";if(i<this.GetGroupCountCore()-1)state+=";";}
return state;},UpdateGroupStateCookie:function(){if(this.cookieName=="")return;_aspxDelCookie(this.cookieName);_aspxSetCookie(this.cookieName,this.GetGroupState());},UpdateGroupStateInputElement:function(){var element=this.GetGroupStateInputElement();if(element!=null)element.value=this.GetGroupState();},SetSelectedItemInternal:function(groupIndex,itemIndex){var indexPath=this.GetIndexPath(groupIndex,itemIndex);if(this.allowSelectItem){var inputElement=this.GetSelectedItemInputElement();if(inputElement!=null){var element=this.GetItemTextElementByIndexPath(inputElement.value);if(element!=null)
aspxGetStateController().DeselectElementBySrcElement(element);inputElement.value=indexPath;element=this.GetItemTextElementByIndexPath(inputElement.value);if(element!=null)
aspxGetStateController().SelectElementBySrcElement(element);}}},OnAnimationTimer:function(groupIndex){var element=this.GetGroupContentAnimationElement(groupIndex);if(element!=null){window.clearTimeout(element.timerID);var animationOffset=this.animationOffset*element.animationCount;var height=element.offsetHeight+(element.expanding?animationOffset:-animationOffset);var innerElement=_aspxGetChildByTagName(element,"TABLE",0);if(innerElement==null)
innerElement=_aspxGetChildByTagName(element,"UL",0);var finished=(element.expanding?(height>=innerElement.offsetHeight):(height<=0))||(new Date()-element.animationStart>this.animationMaxDelay);if(finished){this.ChangeGroupExpandState(groupIndex,element.expanding);element.style.overflow="";element.style.height="";element.style.width="";this.RaiseExpandedChanged(groupIndex);}
else{element.style.height=height+"px";element.animationCount++;element.timerID=window.setTimeout("aspxNBAnimT(\""+this.name+"\", "+groupIndex+")",this.animationDelay);}}},OnHeaderClick:function(groupIndex,evt){var processingMode=this.RaiseHeaderClick(groupIndex,evt);var linkElement=_aspxGetParentByTagName(_aspxGetEventSource(evt),"A");if(linkElement==null||linkElement.href==__aspxAccessibilityEmptyUrl){if(processingMode=="Client"&&this.allowExpanding){var expanded=this.groupsExpanding[groupIndex];this.SetExpandedInternal(groupIndex,!expanded);aspxUpdateHoverState(evt);}
else if(processingMode=="Server")
this.SendPostBack("HEADERCLICK:"+groupIndex);}},OnItemClick:function(groupIndex,itemIndex,evt){var element=this.GetItemElement(groupIndex,itemIndex);var isLinkClicked=(_aspxGetParentByTagName(_aspxGetEventSource(evt),"A")!=null);var linkElement=(element!=null)?_aspxGetChildByTagName(element,"A",0):null;aspxClearHoverState();this.SetSelectedItemInternal(groupIndex,itemIndex);aspxUpdateHoverState(evt);this.DoItemClick(groupIndex,itemIndex,isLinkClicked||(linkElement!=null),evt);if(!isLinkClicked&&linkElement!=null)
_aspxNavigateUrl(linkElement.href,linkElement.target);},OnCallbackInternal:function(html,index,isError){this.SetCallbackContent(html,index,isError);if(!isError)
this.RaiseExpandedChanged(index);_aspxArrayRemoveAt(this.groupsExpandingRequest,0);},OnCallback:function(result){this.OnCallbackInternal(result.html,result.index,false);},OnCallbackError:function(result,data){this.OnCallbackInternal(result,data,true);},OnCallbackGeneralError:function(result){var callbackGroupIndex=(this.groupsExpandingRequest.length>0)?this.groupsExpandingRequest[0]:0;this.SetCallbackContent(result,callbackGroupIndex,true);_aspxArrayRemoveAt(this.groupsExpandingRequest,0);},SetCallbackContent:function(html,index,isError){var element=this.GetGroupContentElement(index);if(element!=null){element.innerHTML=html;if(!isError)
element.loaded=true;element.loading=false;}},CreateGroups:function(groupsProperties){for(var i=0;i<groupsProperties.length;i++){var groupName=_aspxIsExists(groupsProperties[i][0])?groupsProperties[i][0]:"";var group=new ASPxClientNavBarGroup(this,i,groupName);if(_aspxIsExists(groupsProperties[i][1]))
group.enabled=groupsProperties[i][1];if(_aspxIsExists(groupsProperties[i][2]))
group.visible=groupsProperties[i][2];if(_aspxIsExists(groupsProperties[i][3]))
group.clientVisible=groupsProperties[i][3];_aspxArrayPush(this.groups,group);group.CreateItems(groupsProperties[i][4]);}},RaiseItemClick:function(groupIndex,itemIndex,htmlEvent){var processOnServer=this.autoPostBack||this.IsServerEventAssigned("ItemClick");if(!this.ItemClick.IsEmpty()){var htmlElement=this.GetItemElement(groupIndex,itemIndex);var args=new ASPxClientNavBarItemEventArgs(processOnServer,this.GetGroup(groupIndex).GetItem(itemIndex),htmlElement,htmlEvent);this.ItemClick.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;},RaiseExpandedChanged:function(groupIndex){if(!this.ExpandedChanged.IsEmpty()){var args=new ASPxClientNavBarGroupEventArgs(this.GetGroup(groupIndex));this.ExpandedChanged.FireEvent(this,args);}},RaiseExpandedChanging:function(groupIndex){var processingMode=this.autoPostBack?"Server":"Client";if(!this.ExpandedChanging.IsEmpty()){var args=new ASPxClientNavBarGroupCancelEventArgs(processingMode=="Server",this.GetGroup(groupIndex));this.ExpandedChanging.FireEvent(this,args);if(args.cancel)
processingMode="Handled";else
processingMode=args.processOnServer?"Server":"Client";}
return processingMode;},RaiseHeaderClick:function(groupIndex,htmlEvent){var processingMode=this.autoPostBack||this.IsServerEventAssigned("HeaderClick")?"Server":"Client";if(!this.HeaderClick.IsEmpty()){var htmlElement=this.GetClickableGroupHeaderElement(groupIndex);var args=new ASPxClientNavBarGroupClickEventArgs(processingMode=="Server",this.GetGroup(groupIndex),htmlElement,htmlEvent);this.HeaderClick.FireEvent(this,args);if(args.cancel)
processingMode="Handled";else
processingMode=args.processOnServer?"Server":"Client";}
return processingMode;},GetGroupCount:function(){return this.groups.length;},GetGroup:function(index){return(0<=index&&index<this.groups.length)?this.groups[index]:null;},GetGroupByName:function(name){for(var i=0;i<this.groups.length;i++)
if(this.groups[i].name==name)return this.groups[i];return null;},GetActiveGroup:function(){if(this.autoCollapse){for(var i=0;i<this.groups.length;i++){if(this.groups[i].GetExpanded())
return this.groups[i];}}
return null;},SetActiveGroup:function(group){if(this.autoCollapse&&group!=null)
group.SetExpanded(true);},GetItemByName:function(name){for(var i=0;i<this.groups.length;i++){var item=this.groups[i].GetItemByName(name);if(item!=null)return item;}
return null;},GetSelectedItem:function(){var inputElement=this.GetSelectedItemInputElement();if(inputElement!=null&&inputElement.value!=""){var groupIndex=this.GetGroupIndex(inputElement.value);var itemIndex=this.GetItemIndex(inputElement.value);if(groupIndex>-1&&itemIndex>-1)
return this.GetGroup(groupIndex).GetItem(itemIndex);}
return null;},SetSelectedItem:function(item){var groupIndex=(item!=null)?item.group.index:-1;var itemIndex=(item!=null)?item.index:-1;this.SetSelectedItemInternal(groupIndex,itemIndex);},CollapseAll:function(){for(var i=0;i<this.groupsExpanding.length;i++){if(this.groupsExpanding[i])
this.SetExpandedInternal(i,false);}},ExpandAll:function(){for(var i=0;i<this.groupsExpanding.length;i++){if(!this.groupsExpanding[i])
this.SetExpandedInternal(i,true);}},CheckSelectedItem:function(groupIndex,itemIndex){var selectedItem=this.GetSelectedItem();if(selectedItem!=null&&selectedItem.group.index==groupIndex&&selectedItem.index==itemIndex)
this.SetSelectedItem(null);},ChangeItemElementsEnabledAttributes:function(groupIndex,itemIndex,method,styleMethod){var indexPath=this.GetIndexPath(groupIndex,itemIndex);var imageElement=this.GetItemImageElementByIndexPath(indexPath);if(_aspxIsExists(imageElement)){method(imageElement,"onclick");styleMethod(imageElement,"cursor");var link=_aspxGetChildByTagName(imageElement,"A",0);if(link!=null)
method(link,"href");}
var textElement=this.GetItemTextElementByIndexPath(indexPath);if(_aspxIsExists(textElement)){method(textElement,"onclick");styleMethod(textElement,"cursor");var link=_aspxGetChildByTagName(textElement,"A",0);if(link!=null)
method(link,"href");link=_aspxGetChildByTagName(textElement,"A",1);if(link!=null)
method(link,"href");}
var itemElement=this.GetItemElement(groupIndex,itemIndex);if(_aspxIsExists(itemElement)){method(itemElement,"onclick");if(imageElement==null&&textElement==null){styleMethod(itemElement,"cursor");var link=_aspxGetChildByTagName(itemElement,"A",0);if(link!=null)
method(link,"href");}}},SetItemEnabled:function(groupIndex,itemIndex,enabled,initialization){if(!this.groups[groupIndex].items[itemIndex].enabled)return;if(!initialization||!enabled)
this.ChangeItemEnabledStateItems(groupIndex,itemIndex,enabled);this.ChangeItemEnabledAttributes(groupIndex,itemIndex,enabled);},ChangeItemEnabledAttributes:function(groupIndex,itemIndex,enabled){if(!enabled)
this.CheckSelectedItem(groupIndex,itemIndex);this.ChangeItemElementsEnabledAttributes(groupIndex,itemIndex,_aspxChangeAttributesMethod(enabled),_aspxChangeStyleAttributesMethod(enabled));},ChangeItemEnabledStateItems:function(groupIndex,itemIndex,enabled){var indexPath=this.GetIndexPath(groupIndex,itemIndex);var element=this.GetItemTextElementByIndexPath(indexPath);if(element==null)
element=this.GetItemImageElementByIndexPath(indexPath);if(element==null)
element=this.GetItemElement(groupIndex,itemIndex);if(element!=null)
aspxGetStateController().SetElementEnabled(element,enabled);},GetItemImageUrl:function(groupIndex,itemIndex){var indexPath=this.GetIndexPath(groupIndex,itemIndex);var element=this.GetItemImageElementByIndexPath(indexPath);if(element!=null){var img=_aspxGetChildByTagName(element,"IMG",0);if(img!=null)
return img.src;}
element=this.GetItemTextElementByIndexPath(indexPath);if(element!=null){var img=_aspxGetChildByTagName(element,"IMG",0);if(img!=null)
return img.src;}
return"";},SetItemImageUrl:function(groupIndex,itemIndex,url){var indexPath=this.GetIndexPath(groupIndex,itemIndex);var element=this.GetItemImageElementByIndexPath(indexPath);if(element!=null){var img=_aspxGetChildByTagName(element,"IMG",0);if(img!=null)
img.src=url;}
element=this.GetItemTextElementByIndexPath(indexPath);if(element!=null){var img=_aspxGetChildByTagName(element,"IMG",0);if(img!=null)
img.src=url;}},GetItemNavigateUrl:function(groupIndex,itemIndex){var indexPath=this.GetIndexPath(groupIndex,itemIndex);var element=this.GetItemTextElementByIndexPath(indexPath);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
return link.href;}
element=this.GetItemImageElementByIndexPath(indexPath);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
return link.href;}
return"";},SetItemNavigateUrl:function(groupIndex,itemIndex,url){var indexPath=this.GetIndexPath(groupIndex,itemIndex);var element=this.GetItemTextElementByIndexPath(indexPath);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
link.href=url;link=_aspxGetChildByTagName(element,"A",1);if(link!=null)
link.href=url;}
var element=this.GetItemImageElementByIndexPath(indexPath);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
link.href=url;}},GetItemText:function(groupIndex,itemIndex){var indexPath=this.GetIndexPath(groupIndex,itemIndex);var element=this.GetItemTextElementByIndexPath(indexPath);if(element!=null){var textNode=_aspxGetChildTextNode(element,0);if(textNode!=null)
return textNode.nodeValue;}
return"";},SetItemText:function(groupIndex,itemIndex,text){var indexPath=this.GetIndexPath(groupIndex,itemIndex);var element=this.GetItemTextElementByIndexPath(indexPath);if(element!=null){var textNode=_aspxGetChildTextNode(element,0);if(textNode!=null)
textNode.nodeValue=text;}},SetItemVisible:function(groupIndex,itemIndex,visible,initialization){if(!this.groups[groupIndex].items[itemIndex].visible)return;if(visible&&initialization)return;if(!visible)
this.CheckSelectedItem(groupIndex,itemIndex);var element=this.GetItemElement(groupIndex,itemIndex);if(element!=null)_aspxSetElementDisplay(element,visible);this.SetItemSeparatorsVisiblility(groupIndex);},SetItemSeparatorsVisiblility:function(groupIndex){var group=this.groups[groupIndex];for(var i=0;i<group.items.length;i++){var separatorVisible=group.items[i].GetVisible()&&this.HasNextVisibleItems(group,i);var separatorElement=this.GetItemSeparatorElement(groupIndex,i);if(separatorElement!=null)_aspxSetElementDisplay(separatorElement,separatorVisible);}},HasNextVisibleItems:function(group,index){for(var i=index+1;i<group.items.length;i++){if(group.items[i].GetVisible())
return true;}
return false;},SetGroupVisible:function(groupIndex,visible,initialization){if(!this.groups[groupIndex].visible)return;if(visible&&initialization)return;var element=this.GetGroupRow(groupIndex);if(element!=null)_aspxSetElementDisplay(element,visible);this.SetGroupSeparatorsVisiblility();},SetGroupSeparatorsVisiblility:function(){for(var i=0;i<this.groups.length;i++){var separatorVisible=this.groups[i].GetVisible()&&this.HasNextVisibleGroups(i);var separatorElement=this.GetGroupSeparatorRow(i);if(separatorElement!=null)_aspxSetElementDisplay(separatorElement,separatorVisible);}},HasNextVisibleGroups:function(index){for(var i=index+1;i<this.groups.length;i++){if(this.groups[i].GetVisible())
return true;}
return false;}});ASPxClientNavBarGroup=_aspxCreateClass(null,{constructor:function(navBar,index,name){this.navBar=navBar;this.index=index;this.name=name;this.enabled=true;this.visible=true;this.clientVisible=true;this.items=[];},CreateItems:function(itemsProperties){for(var i=0;i<itemsProperties.length;i++){var itemName=_aspxIsExists(itemsProperties[i][0])?itemsProperties[i][0]:"";var item=new ASPxClientNavBarItem(this.navBar,this,i,itemName);if(_aspxIsExists(itemsProperties[i][1]))
item.enabled=itemsProperties[i][1];if(_aspxIsExists(itemsProperties[i][2]))
item.clientEnabled=itemsProperties[i][2];if(_aspxIsExists(itemsProperties[i][3]))
item.visible=itemsProperties[i][3];if(_aspxIsExists(itemsProperties[i][4]))
item.clientVisible=itemsProperties[i][4];_aspxArrayPush(this.items,item);}},GetEnabled:function(){return this.enabled;},GetExpanded:function(){return this.navBar.groupsExpanding[this.index];},SetExpanded:function(value){this.navBar.SetExpandedInternal(this.index,value);},GetVisible:function(){return this.visible&&this.clientVisible;},SetVisible:function(value){if(this.clientVisible!=value){this.clientVisible=value;this.navBar.SetGroupVisible(this.index,value,false);}},GetItemCount:function(groupIndex){return this.items.length;},GetItem:function(index){return(0<=index&&index<this.items.length)?this.items[index]:null;},GetItemByName:function(name){for(var i=0;i<this.items.length;i++)
if(this.items[i].name==name)return this.items[i];return null;}});ASPxClientNavBarItem=_aspxCreateClass(null,{constructor:function(navBar,group,index,name){this.navBar=navBar;this.group=group;this.index=index;this.name=name;this.enabled=true;this.clientEnabled=true;this.visible=true;this.clientVisible=true;},GetEnabled:function(){return this.enabled&&this.clientEnabled;},SetEnabled:function(value){if(this.clientEnabled!=value){this.clientEnabled=value;this.navBar.SetItemEnabled(this.group.index,this.index,value,false);}},GetImageUrl:function(){return this.navBar.GetItemImageUrl(this.group.index,this.index);},SetImageUrl:function(value){this.navBar.SetItemImageUrl(this.group.index,this.index,value);},GetNavigateUrl:function(){return this.navBar.GetItemNavigateUrl(this.group.index,this.index);},SetNavigateUrl:function(value){this.navBar.SetItemNavigateUrl(this.group.index,this.index,value);},GetText:function(){return this.navBar.GetItemText(this.group.index,this.index);},SetText:function(value){this.navBar.SetItemText(this.group.index,this.index,value);},GetVisible:function(){return this.visible&&this.clientVisible;},SetVisible:function(value){if(this.clientVisible!=value){this.clientVisible=value;this.navBar.SetItemVisible(this.group.index,this.index,value,false);}}});ASPxClientNavBarItemEventArgs=_aspxCreateClass(ASPxClientProcessingModeEventArgs,{constructor:function(processOnServer,item,htmlElement,htmlEvent){this.constructor.prototype.constructor.call(this,processOnServer);this.item=item;this.htmlElement=htmlElement;this.htmlEvent=htmlEvent;}});ASPxClientNavBarGroupEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(group){this.group=group;}});ASPxClientNavBarGroupCancelEventArgs=_aspxCreateClass(ASPxClientCancelEventArgs,{constructor:function(processOnServer,group){this.constructor.prototype.constructor.call(this,processOnServer);this.group=group;}});ASPxClientNavBarGroupClickEventArgs=_aspxCreateClass(ASPxClientNavBarGroupCancelEventArgs,{constructor:function(processOnServer,group,htmlElement,htmlEvent){this.constructor.prototype.constructor.call(this,processOnServer,group);this.htmlElement=htmlElement;this.htmlEvent=htmlEvent;}});function aspxNBAnimT(name,groupIndex){var nb=aspxGetControlCollection().Get(name);if(nb!=null)nb.OnAnimationTimer(groupIndex);}
function aspxNBHClick(evt,name,groupIndex){var nb=aspxGetControlCollection().Get(name);if(nb!=null)nb.OnHeaderClick(groupIndex,evt);if(!__aspxNS)
evt.cancelBubble=true;return true;}
function aspxNBIClick(evt,name,groupIndex,itemIndex){var nb=aspxGetControlCollection().Get(name);if(nb!=null)nb.OnItemClick(groupIndex,itemIndex,evt);if(!__aspxNS)
evt.cancelBubble=true;return true;}
ASPxClientCallback=_aspxCreateClass(ASPxClientControl,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.CallbackComplete=new ASPxClientEvent();},SendCallback:function(parameter){this.PerformCallback(parameter);},PerformCallback:function(parameter){if(!_aspxIsExists(parameter))parameter="";this.CreateCallback(parameter);},OnCallback:function(result){var args=new ASPxClientCallbackCompleteEventArgs(result.parameter,result.data);this.CallbackComplete.FireEvent(this,args);}});ASPxClientCallbackCompleteEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(parameter,result){this.constructor.prototype.constructor.call(this);this.parameter=parameter;this.result=result;}});ASPxClientObjectContainer=_aspxCreateClass(ASPxClientControl,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.needFixObjectBounds=false;this.FlashScriptCommand=new ASPxClientEvent();},Initialize:function(){if(this.needFixObjectBounds)
this.FixObjectBounds();if(__aspxSafariFamily&&!this.GetVisible())
this.SetVisible_Safari(false);this.constructor.prototype.Initialize.call(this);},DoFlashScriptCommand:function(command,args){this.RaiseFlashScriptCommand(command,args);},FixObjectBounds:function(){var mainElement=this.GetMainElement();if(mainElement!=null&&mainElement.body!=null&&mainElement.body.style!=null){mainElement.body.style.border="none";mainElement.body.style.margin="0px";mainElement.body.style.padding="0px";mainElement.body.style.overflow="hidden";}},SetVisible:function(visible){ASPxClientControl.prototype.SetVisible.call(this,visible);if(__aspxSafariFamily)
this.SetVisible_Safari(visible);},SetVisible_Safari:function(visible){var mainElement=this.GetMainElement();var method=visible?_aspxRestoreStyleAttribute:_aspxChangeStyleAttribute;method(mainElement,"width","0px");method(mainElement,"height","0px");},RaiseFlashScriptCommand:function(command,args){if(!this.FlashScriptCommand.IsEmpty()){var eventArgs=new ASPxClientFlashScriptCommandEventArgs(command,args);this.FlashScriptCommand.FireEvent(this,eventArgs);}},Back:function(){this.GetMainElement().Back();},GetVariable:function(name){return this.GetMainElement().GetVariable(name);},Forward:function(){this.GetMainElement().Forward();},GotoFrame:function(frameNumber){this.GetMainElement().GotoFrame(frameNumber);},IsPlaying:function(){return __aspxIE?this.GetMainElement().Playing:this.GetMainElement().IsPlaying();},LoadMovie:function(layerNumber,url){this.GetMainElement().LoadMovie(layerNumber,url);},Pan:function(x,y,mode){this.GetMainElement().Pan(x,y,mode);},PercentLoaded:function(){this.GetMainElement().PercentLoaded();},Play:function(){this.GetMainElement().Play();},Rewind:function(){this.GetMainElement().Rewind();},SetVariable:function(name,value){this.GetMainElement().SetVariable(name,value);},SetZoomRect:function(left,top,right,bottom){this.GetMainElement().SetZoomRect(left,top,right,bottom);},StopPlay:function(){if(__aspxIE)
this.GetMainElement().Stop();else
this.GetMainElement().StopPlay();},TotalFrames:function(){return __aspxIE?this.GetMainElement().TotalFrames:this.GetMainElement().TotalFrames();},Zoom:function(percent){this.GetMainElement().Zoom(percent);},QTPlay:function(){this.GetMainElement().Play();},QTStopPlay:function(){this.GetMainElement().Stop();},QTRewind:function(){this.GetMainElement().Rewind();},QTStep:function(count){this.GetMainElement().Step(count);}});ASPxClientFlashScriptCommandEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(command,args){this.command=command;this.args=args;}});var __aspxPCWIdSuffix="_PW";function ASPxPCResizeCursorInfo(horizontalDirection,verticalDirection,horizontalOffset,verticalOffset){this.horizontalDirection=horizontalDirection;this.verticalDirection=verticalDirection;this.horizontalOffset=horizontalOffset;this.verticalOffset=verticalOffset;this.course=verticalDirection+horizontalDirection;}
ASPxClientPopupControl=_aspxCreateClass(ASPxClientControl,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.leadingAfterInitCall=true;this.adjustInnerControlsSizeOnShow=true;this.animationDelay=30;this.animationMaxDelay=400;this.appearAfter=300;this.disappearAfter=500;this.allowResize=false;this.enableAnimation=true;this.allowCorrectYOffsetPosition=true;this.contentUrl="";this.contentUrlArray=[];this.cookieName="";this.closeAction="OuterMouseClick";this.popupAction="LeftMouseClick";this.popupElementID="";this.popupElementIDArray=[];this.showOnPageLoad=false;this.showOnPageLoadArray=[];this.popupHorizontalAlign=__aspxNotSetAlignIndicator;this.popupVerticalAlign=__aspxNotSetAlignIndicator;this.popupHorizontalOffset=0;this.popupVerticalOffset=0;this.shadowHeight=5;this.shadowWidth=5;this.windows=[];this.windowCount=0;this.isDragged=false;this.isResized=false;this.zIndex=-1;this.left=0;this.top=0;this.isDraggedArray=[];this.isResizedArray=[];this.zIndexArray=[];this.leftArray=[];this.topArray=[];this.height=0;this.width=0;this.heightArray=[];this.widthArray=[];this.isLiveResizingMode=true;this.isPopupPositionCorrectionOn=true;this.SSLSecureBlankUrl="";this.windowElements=new Object();this.hideBodyScrollWhenModal=true;this.popupElement=null;this.popupElements=[];this.headerHeight=0;this.headerHeightArray=[];this.footerHeight=0;this.footerHeightArray=[];this.ResizeBorderSize=6;this.ResizeCornerBorderSize=20;this.CloseButtonClick=new ASPxClientEvent();this.CloseUp=new ASPxClientEvent();this.PopUp=new ASPxClientEvent();this.Resize=new ASPxClientEvent();this.Shown=new ASPxClientEvent();aspxGetPopupControlCollection().Add(this);},Initialize:function(){this.InitializeArrays();if(this.HasDefaultWindow())
this.InitializeWindow(-1);for(var i=0;i<this.popupElementIDArray.length;i++)
this.InitializeWindow(i);this.constructor.prototype.Initialize.call(this);},AfterInitialize:function(){if(this.HasDefaultWindow())
this.AfterInitializeWindow(-1);for(var i=0;i<this.popupElementIDArray.length;i++)
this.AfterInitializeWindow(i);this.constructor.prototype.AfterInitialize.call(this);},InitializeArrays:function(){if(this.GetWindowCountCore()>0){if(this.contentUrlArray.length==0)
this.InitializeArray(this.contentUrlArray,"");if(this.popupElementIDArray.length==0)
this.InitializeArray(this.popupElementIDArray,"");if(this.showOnPageLoadArray.length==0)
this.InitializeArray(this.showOnPageLoadArray,false);if(this.isDraggedArray.length==0)
this.InitializeArray(this.isDraggedArray,false);if(this.isResizedArray.length==0)
this.InitializeArray(this.isResizedArray,false);if(this.zIndexArray.length==0)
this.InitializeArray(this.zIndexArray,-1);if(this.leftArray.length==0)
this.InitializeArray(this.leftArray,0);if(this.topArray.length==0)
this.InitializeArray(this.topArray,0);if(this.widthArray.length==0)
this.InitializeArray(this.widthArray,0);if(this.heightArray.length==0)
this.InitializeArray(this.heightArray,0);if(__aspxIE){if(this.headerHeightArray.length==0)
this.InitializeArray(this.headerHeightArray,-1);if(this.footerHeightArray.length==0)
this.InitializeArray(this.footerHeightArray,-1);}}},InitializeArray:function(array,value){for(var i=0;i<this.GetWindowCountCore();i++)
array[i]=value;},InitializeWindow:function(index){this.GetPopupElement(index);var element=this.GetWindowElement(index);if(element!=null){element.onresize=new Function("aspxPWResize(\""+this.name+"\",\""+element.id+"\");");if(__aspxIE)
this.AttachOnDragStartEventToWindowImages(index);element.isHiding=false;element.isIEContentHeightInit=false;element.isPopupPositionCorrectionOn=this.isPopupPositionCorrectionOn||!this.GetShowOnPageLoad(index);if(this.GetShowOnPageLoad(index)&&this.GetZIndex(index)>0){this.FirstShowWindow(index,false);aspxGetPopupControlCollection().SetWindowElementZIndex(element,this.GetZIndex(index));element.isPopupPositionCorrectionOn=true;}}},AfterInitializeWindow:function(index){if(this.GetShowOnPageLoad(index)&&this.GetZIndex(index)<0){this.FirstShowWindow(index,true);var element=this.GetWindowElement(index);if(element!=null)
element.isPopupPositionCorrectionOn=true;}},AttachOnDragStartEventToWindowImages:function(index){this.AttachChildImagesPreventDragStartEvent(this.GetWindowHeaderElement(index));this.AttachChildImagesPreventDragStartEvent(this.GetWindowFooterElement(index));},AttachChildImagesPreventDragStartEvent:function(parentElem){var images=parentElem==null?null:_aspxGetElementsByTagName(parentElem,"img");if(images!=null){for(var i=0;i<images.length;i++)
images[i].ondragstart=new Function("return _aspxPreventDragStart(event)");}},FirstShowWindow:function(index,allowChangeZIndex){var isFreeWindow=this.GetIsDragged(index);var x=__aspxInvalidPosition;var y=__aspxInvalidPosition;if(isFreeWindow){x=this.GetWindowLeft(index);y=this.GetWindowTop(index);var popupHorizontalOffsetBackup=this.popupHorizontalOffset;var popupVerticalOffsetBackup=this.popupVerticalOffset;this.popupHorizontalOffset=0;this.popupVerticalOffset=0;}
var enableAnimationBackup=this.enableAnimation;this.enableAnimation=false;this.DoShowWindowAtPos(index,x,y,isFreeWindow,false,allowChangeZIndex);this.enableAnimation=enableAnimationBackup;if(isFreeWindow){this.popupHorizontalOffset=popupHorizontalOffsetBackup;this.popupVerticalOffset=popupVerticalOffsetBackup;}},GetIsDragged:function(index){if(0<=index&&index<this.isDraggedArray.length)
return this.isDraggedArray[index];return this.isDragged;},SetIsDragged:function(index,value){if(0<=index&&index<this.isDraggedArray.length)
this.isDraggedArray[index]=value;else
this.isDragged=value;},GetIsResized:function(index){if(0<=index&&index<this.isResizedArray.length)
return this.isResizedArray[index];return this.isResized;},SetIsResized:function(index,value){if(0<=index&&index<this.isResizedArray.length)
this.isResizedArray[index]=value;else
this.isResized=value;},HasDefaultWindow:function(){return this.GetWindowCountCore()==0;},GetCurrentLeft:function(index){return this.GetPosition(index,true);},GetCurrentTop:function(index){return this.GetPosition(index,false);},GetHeaderHeight:function(index){if(0<=index&&index<this.headerHeightArray.length)
return this.headerHeightArray[index];return this.headerHeight;},GetFooterHeight:function(index){if(0<=index&&index<this.footerHeightArray.length)
return this.footerHeightArray[index];return this.footerHeight;},SetHeaderHeight:function(index,height){if(0<=index&&index<this.headerHeightArray.length)
this.headerHeightArray[index]=height;else
this.headerHeight=height;},SetFooterHeight:function(index,height){if(0<=index&&index<this.footerHeightArray.length)
return this.footerHeightArray[index]=height;else
this.footerHeight=height;},GetPosition:function(index,isLeft){if(0<=index&&index<this.GetWindowCountCore())
return isLeft?this.leftArray[index]:this.topArray[index];return isLeft?this.left:this.top;},GetPopupElement:function(index){var popupElement=this.GetPopupElementInternal(index);if(!_aspxIsExistsElement(popupElement)){var popupElement=_aspxFindPopupElementById(this.GetPopupElementID(index));if(_aspxIsExistsElement(popupElement)){popupElement.DXPopupControl=this;popupElement.DXPopupWindowIndex=index;popupElement.isPopuped=false;if(this.popupAction=="LeftMouseClick")
_aspxAttachEventToElement(popupElement,"mouseup",aspxPEMEvent);else if(this.popupAction=="RightMouseClick")
_aspxAttachEventToElement(popupElement,"contextmenu",aspxPEMEvent);else if(this.popupAction=="MouseOver")
_aspxAttachEventToElement(popupElement,"mouseover",aspxPEMOver);if(this.popupAction=="LeftMouseClick"||this.popupAction=="RightMouseClick"){_aspxAttachEventToElement(popupElement,"mousedown",aspxPEMEvent);var modalElement=this.GetWindowModalElement(index);if(_aspxIsExists(modalElement))
_aspxAttachEventToElement(modalElement,"mousedown",aspxPWMEMDown);}
this.SetPopupElementInternal(index,popupElement);}}
return popupElement;},GetPopupElementInternal:function(index){if(0<=index&&index<this.GetWindowCountCore())
return this.popupElements[index];return this.popupElement;},SetPopupElementInternal:function(index,element){if(0<=index&&index<this.GetWindowCountCore())
this.popupElements[index]=element;else
this.popupElement=element;},GetPopupElementID:function(index){if(0<=index&&index<this.GetWindowCountCore())
return this.popupElementIDArray[index];return this.popupElementID;},GetShowOnPageLoad:function(index){if(0<=index&&index<this.showOnPageLoadArray.length)
return this.showOnPageLoadArray[index];return this.showOnPageLoad;},GetWindowCountCore:function(){return(this.windows.length>0)?this.windows.length:this.windowCount;},GetWindowIFrame:function(index){var element=this.GetWindowElement(index);var iFrame=element.overflowElement;if(!_aspxIsExists(iFrame)){iFrame=this.FindWindowIFrame(index);element.overflowElement=iFrame;}
return iFrame;},FindWindowIFrame:function(index){return _aspxGetElementById(this.name+"_DXPWIF"+index);},GetWindowModalElement:function(index){var element=this.GetWindowElement(index);if(!_aspxIsExists(element))return;var modalElement=element.modalElement;if(!_aspxIsExists(modalElement)){modalElement=this.FindWindowModalElement(index);element.modalElement=modalElement;if(_aspxIsExists(modalElement)){modalElement.DXModalPopupControl=this;modalElement.DXModalPopupWindowIndex=index;}}
return modalElement;},FindWindowModalElement:function(index){return _aspxGetElementById(this.name+"_DXPWMB"+index);},GetWindowElementId:function(index){return this.name+__aspxPCWIdSuffix+index;},GetWindowElement:function(index){if(!_aspxIsExistsElement(this.windowElements[index]))
this.windowElements[index]=_aspxGetElementById(this.GetWindowElementId(index));return this.windowElements[index];},GetWindowChild:function(index,idPostfix){return _aspxGetChildById(this.GetWindowElement(index),this.name+idPostfix);},GetWindowContentIFrameDivElementID:function(index){return this.name+"_CIFD"+index;},GetWindowContentIFrameDivElement:function(index){return this.GetWindowChild(index,"_CIFD"+index);},GetWindowContentIFrameElementId:function(index){return this.name+"_CIF"+index;},GetWindowContentIFrameElement:function(index){return this.GetWindowChild(index,"_CIF"+index);},GetWindowContentIFrameUrl:function(index){if(0<=index&&index<this.contentUrlArray.length)
return this.contentUrlArray[index];return this.contentUrl;},SetWindowContentIFrameUrl:function(index,url){if(0<=index&&index<this.contentUrlArray.length)
this.contentUrlArray[index]=url;else
this.contentUrl=url;},ShowWindowContentUrl:function(index){if(__aspxMozilla||__aspxSafariFamily){var contentIFrameDiv=this.GetWindowContentIFrameDivElement(index);var contentIFrame=this.GetWindowContentIFrameElement(index);if(_aspxIsExists(contentIFrameDiv))
contentIFrameDiv.style.height="100%";if(_aspxIsExists(contentIFrame))
contentIFrame.style.height=contentIFrameDiv.clientHeight+"px";}
this.LoadWindowContentUrl(index);},LoadWindowContentUrl:function(index){var url=this.GetWindowContentIFrameUrl(index);this.LoadWindowContentFromUrl(index,url);},LoadWindowContentFromUrl:function(index,url){var element=this.GetWindowContentIFrameElement(index);if(_aspxIsExists(element)&&element.src!=url){element.src=url;this.SetWindowContentIFrameUrl(index,element.src);}},GetWindowContentElement:function(index){return this.GetWindowChild(index,"_PWC"+index);},GetWindowHeaderElement:function(index){return this.GetWindowChild(index,"_PWH"+index);},GetWindowHeaderGripElement:function(index){return this.GetWindowChild(index,"_FGRP"+index);},GetWindowFooterElement:function(index){return this.GetWindowChild(index,"_PWF"+index);},GetWindowIndex:function(element){var id=element.id;var pos=id.lastIndexOf(__aspxPCWIdSuffix);return parseInt(id.substr(pos+__aspxPCWIdSuffix.length));},GetWindowMainCell:function(element){return this.GetWindowMainTable(element).rows[0].cells[0];},GetWindowMainTable:function(element){var index=this.GetWindowIndex(element);var shadowTable=this.GetWindowChild(index,"_PWST"+index);return shadowTable!=null?shadowTable:element;},GetWindowClientTable:function(index){return this.GetWindowChild(index,"_CLW"+index);},GetWindowLeft:function(index){if(0<=index&&index<this.leftArray.length)
return this.leftArray[index];return this.left;},SetWindowLeft:function(index,left){if(0<=index&&index<this.leftArray.length)
this.leftArray[index]=left;else
this.left=left;},GetWindowHeightInternal:function(index){if(0<=index&&index<this.heightArray.length)
return this.heightArray[index];return this.height;},SetWindowHeight:function(index,height){if(0<=index&&index<this.heightArray.length)
this.heightArray[index]=height;else
this.height=height;},GetWindowWidthInternal:function(index){if(0<=index&&index<this.widthArray.length)
return this.widthArray[index];return this.width;},SetWindowWidth:function(index,width){if(0<=index&&index<this.widthArray.length)
this.widthArray[index]=width;else
this.width=width;},GetWindowTop:function(index){if(0<=index&&index<this.topArray.length)
return this.topArray[index];return this.top;},SetWindowTop:function(index,top){if(0<=index&&index<this.topArray.length)
return this.topArray[index]=top;else
return this.top=top;},GetWindowsStateInputElement:function(){return _aspxGetElementById(this.name+"WS");},GetZIndex:function(index){if(0<=index&&index<this.zIndexArray.length)
return this.zIndexArray[index];return this.zIndex;},GetCurrentZIndex:function(index){var element=this.GetWindowElement(index);if(element!=null){if(element.style.zIndex!="")
return element.style.zIndex;if(0<=index&&index<this.GetWindowCountCore())
return this.zIndexArray[index];return this.zIndex;}},GetCurrentWindowWidth:function(index){var element=this.GetWindowElement(index);if(element!=null){var mainCell=this.GetWindowMainCell(element);if(mainCell.firstChild.offsetWidth>0)
return mainCell.firstChild.offsetWidth;return this.GetWindowWidthInternal(index);}},GetCurrentWindowHeight:function(index){var element=this.GetWindowElement(index);if(element!=null){var mainCell=this.GetWindowMainCell(element);if(mainCell.firstChild.offsetHeight>0)
return mainCell.firstChild.offsetHeight;return this.GetWindowHeightInternal(index);}},GetClientPopupPos:function(element,popupElement,pos,isX,isDragged){var index=this.GetWindowIndex(element);var popupPosition=null;if(isDragged)
popupPosition=new _aspxPopupPosition(this.GetPosition(index,isX),false);else{popupPosition=isX?this.GetClientPopupPosX(element,popupElement,pos):this.GetClientPopupPosY(element,popupElement,pos);popupPosition.position=_aspxPrepareClientPosForElement(popupPosition.position,element,isX);}
if(__aspxFirefox&&!__aspxFirefox3&&_aspxIsExists(this.GetWindowModalElement(index)))
popupPosition.position-=isX?_aspxGetDocumentScrollLeft():_aspxGetDocumentScrollTop();if(__aspxIE&&!__aspxIE55&&popupElement!=null&&_aspxIsExistsAbsoluteOrRelativePosParent(popupElement))
popupPosition.position-=_aspxGetIEDocumentClientOffset(isX);return popupPosition;},GetClientPopupPosX:function(element,popupElement,x){var mainElement=this.GetWindowMainCell(element);var popupPosition=_aspxGetPopupAbsoluteX(mainElement,popupElement,this.popupHorizontalAlign,this.popupHorizontalOffset,x,this.GetWindowLeft(this.GetWindowIndex(element)));return this.CorrectPopupPositionForClientWindow(element,popupPosition,true);},GetClientPopupPosY:function(element,popupElement,y){var mainElement=this.GetWindowMainCell(element);var popupPosition=_aspxGetPopupAbsoluteY(mainElement,popupElement,this.popupVerticalAlign,this.popupVerticalOffset,y,this.GetWindowTop(this.GetWindowIndex(element)));return(this.allowCorrectYOffsetPosition?this.CorrectPopupPositionForClientWindow(element,popupPosition,false):popupPosition);},CorrectPopupPositionForClientWindow:function(element,popupPosition,isX){if(element.isPopupPositionCorrectionOn){var min=isX?_aspxGetDocumentScrollLeft():_aspxGetDocumentScrollTop();var max=min+(isX?_aspxGetDocumentClientWidth():_aspxGetDocumentClientHeight());max-=(isX?element.offsetWidth+this.shadowWidth:element.offsetHeight+this.shadowHeight);if(popupPosition.position>max)popupPosition.position=max;if(popupPosition.position<min)popupPosition.position=min;}
return popupPosition;},DoShowWindow:function(index,evt){if(!this.InternalIsWindowVisible(index)){var x=_aspxGetEventX(evt);var y=_aspxGetEventY(evt);this.DoShowWindowAtPos(index,x,y,false,true,true);}},DoShowWindowAtPos:function(index,x,y,ignorePopupElement,closeOtherWindows,allowChangeZIndex){var element=this.GetWindowElement(index);if(element!=null){if(this.adjustInnerControlsSizeOnShow){var windowContent=this.GetWindowContentElement(index);var collection=aspxGetControlCollection();collection.CollapseControls(windowContent,__aspxCheckSizeCorrectedFlag);}
this.FFTextCurFixShow(index,true);if(closeOtherWindows)
aspxGetPopupControlCollection().DoHideAllWindows(null,this.GetWindowElementId(index),false);var isMoving=this.InternalIsWindowVisible(index);_aspxSetElementDisplay(element,true);if(__aspxIE&&!element.isIEContentHeightInit){element.isIEContentHeightInit=true;this.GetWindowContentElement(index).style.height="0px";this.CorrectContentCellHeight(element,false);}
var popupElement=ignorePopupElement?null:this.GetPopupElement(index);var isDragged=this.GetIsDragged(index);var horizontalPopupPosition=this.GetClientPopupPos(element,popupElement,x,true,isDragged);var verticalPopupPosition=this.GetClientPopupPos(element,popupElement,y,false,isDragged);var clientX=horizontalPopupPosition.position;var clientY=verticalPopupPosition.position;this.SetWindowPos(index,null,clientX,clientY,true);this.DoShowWindowModalElement(index);var isAnimationNeed=this.enableAnimation&&!isMoving;if(isAnimationNeed){this.StartAnimation(element,index,horizontalPopupPosition,verticalPopupPosition);}
else{this.SetWindowPos(index,element,clientX,clientY,false);_aspxSetElementVisibility(element,true);}
if(!isMoving){aspxGetPopupControlCollection().RegisterVisibleWindow(element);this.RaisePopUp(index);if(!this.enableAnimation)
this.RaiseShowen(index);}
if(allowChangeZIndex){aspxGetPopupControlCollection().ActivateWindowElement(element);}
if(!isAnimationNeed&&__aspxNetscape&&_aspxIsExists(this.GetWindowModalElement(index))){_aspxSetElementDisplay(element,false);_aspxSetElementDisplay(element,true);}
this.ShowWindowContentUrl(index);if(this.adjustInnerControlsSizeOnShow){collection.AdjustControls(windowContent,__aspxCheckSizeCorrectedFlag);}}},DoShowWindowIFrame:function(index,x,y,width,height){if(!this.renderIFrameForPopupElements)return;var element=this.GetWindowElement(index);var iFrame=this.GetWindowIFrame(index);if(_aspxIsExists(element)&&_aspxIsExists(iFrame)){var cell=this.GetWindowMainCell(element);if(width<0)
width=cell.offsetWidth;if(height<0)
height=cell.offsetHeight;_aspxSetStyleSize(iFrame,width,height);if(x!=__aspxInvalidPosition&&y!=__aspxInvalidPosition)
_aspxSetStylePosition(iFrame,x,y);_aspxSetElementDisplay(iFrame,true);}},DoShowWindowModalElement:function(index){var modalElement=this.GetWindowModalElement(index);if(_aspxIsExists(modalElement)){if(this.hideBodyScrollWhenModal)
_aspxHideBodyScroll();_aspxSetElementDisplay(modalElement,true);aspxGetPopupControlCollection().AdjustModalElementBounds(modalElement);_aspxSetElementVisibility(modalElement,true);aspxGetPopupControlCollection().RegisterVisibleModalElement(modalElement);}},DoHideWindow:function(index){if(!this.InternalIsWindowVisible(index))return;this.FFTextCurFixHide(index,true);var element=this.GetWindowElement(index);if(element!=null){element.isHiding=true;this.SetIsDragged(index,false);this.UpdateWindowsStateInputElement();this.UpdateWindowsStateCookie();element.isHiding=false;_aspxStopAnimation(element);_aspxSetElementVisibility(element,false);_aspxSetElementDisplay(element,false);this.DoHideWindowModalElement(element);this.DoHideWindowIFrame(element);aspxGetPopupControlCollection().UnregisterVisibleWindow(element);this.RaiseCloseUp(index);}},DoHideWindowIFrame:function(element){if(!this.renderIFrameForPopupElements)return;var iFrame=element.overflowElement;if(_aspxIsExists(iFrame))
_aspxSetElementDisplay(iFrame,false);},DoHideWindowModalElement:function(element){var modalElement=element.modalElement;if(_aspxIsExists(modalElement)){aspxGetPopupControlCollection().UnregisterVisibleModalElement(modalElement);if(this.hideBodyScrollWhenModal)
_aspxRestoreBodyScroll();_aspxSetStyleSize(modalElement,1,1);_aspxSetElementVisibility(modalElement,false);_aspxSetElementDisplay(modalElement,false);}},SetWindowDisplay:function(index,value){var pcwElement=this.GetWindowElement(index);this.SetFFTextCurFixShowing(index,value,false);_aspxSetElementDisplay(pcwElement,value);},GetTextCurFixDiv:function(index){return _aspxGetElementById(this.name+"_"+"TCFix"+index);},FFTextCurFixShow:function(index,isSetVisibility){this.SetFFTextCurFixShowing(index,true,isSetVisibility);},FFTextCurFixHide:function(index,isSetVisibility){this.SetFFTextCurFixShowing(index,false,isSetVisibility);},SetFFTextCurFixShowing:function(index,value,isSetVisibility){if(__aspxFirefox&&_aspxIsExists(this.GetWindowModalElement(index))){var fixDiv=this.GetTextCurFixDiv(index);if(_aspxIsExists(fixDiv)){if(isSetVisibility)
_aspxSetElementVisibility(fixDiv,value);_aspxSetElementDisplay(fixDiv,value);}}},SetWindowPos:function(index,element,x,y,saveToCache){if(saveToCache){this.SetIsDragged(index,true);this.SetWindowLeft(index,x);this.SetWindowTop(index,y);this.UpdateWindowsStateInputElement();this.UpdateWindowsStateCookie();}
if(element!=null){_aspxSetStylePosition(element,x,y);this.DoShowWindowIFrame(index,x,y,__aspxInvalidDimension,__aspxInvalidDimension);}},CorrectContentCellHeight:function(element,isResizing){if(__aspxIE){var index=this.GetWindowIndex(element);var clientTable=this.GetWindowClientTable(index);var headerCell=this.GetWindowHeaderElement(index);var contentCell=this.GetWindowContentElement(index);var footerCell=this.GetWindowFooterElement(index);var windowMainCell=this.GetWindowMainCell(element);var mainCellHeight=windowMainCell.clientHeight-this.GetTwoVerticalPaddingSize(windowMainCell);var headerHeight=_aspxIsExists(headerCell)?headerCell.offsetHeight:0;var footerHeight=_aspxIsExists(footerCell)?footerCell.offsetHeight:0;if(isResizing){headerHeight=this.GetHeaderHeight(index);footerHeight=this.GetFooterHeight(index);}
else{this.SetHeaderHeight(index,headerHeight);this.SetFooterHeight(index,footerHeight);}
var correctedHeight=mainCellHeight-headerHeight-footerHeight;contentCell.style.height=correctedHeight+"px";var verticalsPaddings=contentCell.offsetHeight-correctedHeight;contentCell.style.height=correctedHeight-verticalsPaddings+"px";}},GetTwoVerticalPaddingSize:function(element){var heightWithBorders=element.clientHeight;var paddingTopBackup=element.style.paddingTop;var paddingBottomBackup=element.style.paddingBottom;element.style.paddingTop="0px";element.style.paddingBottom="0px";var heightWithoutBorders=element.clientHeight;element.style.paddingTop=paddingTopBackup;element.style.paddingBottom=paddingBottomBackup;return(heightWithBorders-heightWithoutBorders);},InternalIsWindowVisible:function(index){var element=this.GetWindowElement(index);return(element!=null)?_aspxGetElementVisibility(element):false;},OnActivate:function(index){var element=this.GetWindowElement(index);if(element!=null)
aspxGetPopupControlCollection().ActivateWindowElement(element);},OnAnimationTimer:function(index){var animationDivElement=this.GetWindowElement(index);if(_aspxIsExists(animationDivElement)){var element=this.GetWindowMainTable(animationDivElement);var mainCell=this.GetWindowMainCell(animationDivElement);var iframeElement=this.GetWindowIFrame(index);_aspxOnAnimationTimer(animationDivElement,element,mainCell,iframeElement,this.animationDelay,this.animationMaxDelay,__aspxPCAnimationAccelerator);}},OnAnimationStop:function(index){this.RaiseShowen(index);},OnDragStart:function(evt,index){this.SetIsDragged(index,true);this.ShowDragCursor(index);var element=this.GetWindowElement(index);var gragXOffset=_aspxGetAbsoluteX(element)-_aspxGetEventX(evt)-_aspxGetIEDocumentClientOffset(true);var gragYOffset=_aspxGetAbsoluteY(element)-_aspxGetEventY(evt)-_aspxGetIEDocumentClientOffset(false);gragXOffset=_aspxPrepareClientPosForElement(gragXOffset,element,true);gragYOffset=_aspxPrepareClientPosForElement(gragYOffset,element,false);aspxGetPopupControlCollection().InitDragObject(this,index,gragXOffset,gragYOffset);},OnDrag:function(index,x,y){var element=this.GetWindowElement(index);if(element!=null){_aspxSetStylePosition(element,x,y);this.SetWindowLeft(index,x);this.SetWindowTop(index,y);var iFrame=element.overflowElement;if(_aspxIsExists(iFrame))
_aspxSetStylePosition(iFrame,x,y);if(__aspxOpera)
_aspxClearSelection();}},OnDragStop:function(index){var element=this.GetWindowElement(index);this.HideDragCursor(index);this.UpdateWindowsStateInputElement();this.UpdateWindowsStateCookie();},CreateResizePanel:function(index){var element=this.GetWindowElement(index);var mainCell=this.GetWindowMainCell(element);var resizePanel=document.createElement("DIV");element.parentNode.appendChild(resizePanel);resizePanel.style.overflow="hidden";resizePanel.style.position="absolute";resizePanel.style.zIndex=__aspxPopupControlZIndex+aspxGetPopupControlCollection().visiblePopupWindowIds.length*2+2;if(!this.isLiveResizingMode)
resizePanel.style.border="black 1px dotted";return resizePanel;},OnResizeStart:function(evt,index){if(!aspxGetPopupControlCollection().IsResizeInint()){this.SetIsResized(index,true);var cursor=this.CreateResizeCursorInfo(evt,index);if(cursor.course!=""){var resizePanel=this.CreateResizePanel(index);this.UpdateResizeCursor(resizePanel,cursor.verticalDirection,cursor.horizontalDirection);aspxGetPopupControlCollection().InitResizeObject(this,index,cursor,resizePanel);this.OnResize(evt,index,cursor,resizePanel);}}
return aspxGetPopupControlCollection().IsResizeInint();},OnResize:function(evt,index,cursor,resizePanel){this.OnResizePanel(evt,index,cursor,resizePanel);if(this.isLiveResizingMode)
this.OnResizeWindow(index,cursor,resizePanel);if(!__aspxIE)
_aspxClearSelection();},OnResizePanel:function(evt,index,cursor,resizePanel){var x=_aspxGetEventX(evt);var y=_aspxGetEventY(evt);var element=this.GetWindowElement(index);var mainCell=this.GetWindowMainCell(element);var clientWindow=this.GetWindowClientTable(index);var left=_aspxGetAbsoluteX(mainCell);var top=_aspxGetAbsoluteY(mainCell);var newLeft=_aspxGetAbsoluteX(element);var newTop=_aspxGetAbsoluteY(element);var newHeight=mainCell.offsetHeight;var newWidth=mainCell.offsetWidth;if(cursor.horizontalDirection=="e")
newWidth=x-newLeft+cursor.horizontalOffset+1;if(cursor.verticalDirection=="s")
newHeight=y-newTop+cursor.verticalOffset+1;if(cursor.horizontalDirection=="w"){newLeft=_aspxPrepareClientPosForElement(x,element,true)-cursor.horizontalOffset;newWidth=newWidth-(x-left)+cursor.horizontalOffset;}else
newLeft=_aspxPrepareClientPosForElement(newLeft,element,true);if(cursor.verticalDirection=="n"){newTop=_aspxPrepareClientPosForElement(y,element,false)-cursor.verticalOffset;newHeight=newHeight-(y-top)+cursor.verticalOffset;}else
newTop=_aspxPrepareClientPosForElement(newTop,element,false);if(!this.isLiveResizingMode){newWidth-=2;newHeight-=2;}
if(newWidth>0&&newHeight>0){_aspxSetStylePosition(resizePanel,newLeft-_aspxGetIEDocumentClientOffset(true),newTop-_aspxGetIEDocumentClientOffset(false));_aspxSetStyleSize(resizePanel,newWidth,newHeight);this.SetWindowLeft(index,newLeft);this.SetWindowTop(index,newTop);}},OnResizeWindow:function(index,cursor,resizePanel){this.SetClientWindowSize(index,resizePanel.offsetWidth,resizePanel.offsetHeight);var element=this.GetWindowElement(index);var mainCell=this.GetWindowMainCell(element);var heightCorrection=mainCell.offsetHeight-resizePanel.offsetHeight;var widthCorrection=mainCell.offsetWidth-resizePanel.offsetWidth;var left=_aspxGetAbsoluteX(resizePanel)-(cursor.horizontalDirection=="w"?widthCorrection:0)-_aspxGetIEDocumentClientOffset(true);var top=_aspxGetAbsoluteY(resizePanel)-(cursor.verticalDirection=="n"?heightCorrection:0)-_aspxGetIEDocumentClientOffset(false);left=_aspxPrepareClientPosForElement(left,element,true);top=_aspxPrepareClientPosForElement(top,element,false);_aspxSetStylePosition(element,left,top);this.DoShowWindowIFrame(index,left,top,__aspxInvalidDimension,__aspxInvalidDimension);},OnResizeStop:function(evt,index,cursor,resizePanel){if(this.allowResize){if(!this.isLiveResizingMode){var collection=aspxGetControlCollection();var windowElement=this.GetWindowElement(index);collection.CollapseControls(windowElement);this.OnResizeWindow(index,cursor,resizePanel);}
this.CreateResizeCursorInfo(evt,index);this.UpdateWindowsStateInputElement();this.UpdateWindowsStateCookie();this.RaiseResize(index);if(!this.isLiveResizingMode)
collection.AdjustControls(windowElement);}},SetClientWindowSize:function(index,width,height){var element=this.GetWindowElement(index);var mainCell=this.GetWindowMainCell(element);var clientWindow=this.GetWindowClientTable(index);var windowHorizontalTwoBorderSize=mainCell.offsetWidth-clientWindow.offsetWidth;var windowVerticalTwoBorderSize=mainCell.offsetHeight-clientWindow.offsetHeight;var contentIFrameDiv=this.GetWindowContentIFrameDivElement(index);var contentIFrame=this.GetWindowContentIFrameElement(index);width-=windowHorizontalTwoBorderSize;height-=windowVerticalTwoBorderSize;if(width>=0&&height>=0){if(__aspxIE){this.GetWindowContentElement(index).style.height="0px";mainCell.style.height="0px";}else{if(_aspxIsExists(contentIFrame))
contentIFrame.style.height="0px";if(_aspxIsExists(contentIFrameDiv))
contentIFrameDiv.style.height="0px";}
_aspxSetStyleSize(clientWindow,width,height);_aspxSetStyleSize(mainCell,width,height);if(__aspxMozilla){_aspxSetElementDisplay(element,false);_aspxSetElementDisplay(element,true);}
_aspxSetStyleSize(element,clientWindow.offsetWidth+this.shadowWidth+windowHorizontalTwoBorderSize,clientWindow.offsetHeight+this.shadowHeight+windowVerticalTwoBorderSize);this.CorrectContentCellHeight(element,true);this.SetWindowWidth(index,clientWindow.offsetWidth);this.SetWindowHeight(index,clientWindow.offsetHeight);if(_aspxIsExists(contentIFrameDiv))
contentIFrameDiv.style.height="100%";if(_aspxIsExists(contentIFrame))
contentIFrame.style.height="100%";}},CreateResizeCursorInfo:function(evt,index){var element=this.GetWindowElement(index);var mainCell=this.GetWindowMainCell(element);var clientWindow=this.GetWindowClientTable(index);var headerElement=this.GetWindowHeaderElement(index);var left=_aspxGetAbsoluteX(mainCell);var top=_aspxGetAbsoluteY(mainCell);var x=_aspxGetEventX(evt);var y=_aspxGetEventY(evt);var leftOffset=Math.abs(x-left);var rightOffset=Math.abs(x-left-mainCell.offsetWidth+1);var topOffset=Math.abs(y-top);var bottomOffset=Math.abs(y-top-mainCell.offsetHeight+1);var cursorInfo=this.CreateResizeBorderCursorInfo(index,leftOffset,rightOffset,topOffset,bottomOffset);var gripCell=this.GetWindowHeaderGripElement(index);if(gripCell){var gripCursorInfo=this.CreateGripCursorInfo(index,mainCell,gripCell,rightOffset,bottomOffset);if(_aspxIsExists(gripCursorInfo))
cursorInfo=gripCursorInfo;}
this.UpdateResizeCursor(clientWindow,cursorInfo.verticalDirection,cursorInfo.horizontalDirection);this.UpdateResizeCursor(mainCell,cursorInfo.verticalDirection,cursorInfo.horizontalDirection);if(_aspxIsExists(headerElement))
this.UpdateResizeCursor(headerElement,cursorInfo.verticalDirection,cursorInfo.horizontalDirection);return cursorInfo;},CreateGripCursorInfo:function(index,mainCell,gripCell,rightOffset,bottomOffset){var gripWidth=mainCell.offsetWidth-(_aspxGetAbsoluteX(gripCell)-_aspxGetAbsoluteX(mainCell));var gripHeight=mainCell.offsetHeight-(_aspxGetAbsoluteY(gripCell)-_aspxGetAbsoluteY(mainCell));if(gripHeight>bottomOffset&&gripWidth>rightOffset)
return new ASPxPCResizeCursorInfo("e","s",rightOffset,bottomOffset);return null;},CreateResizeBorderCursorInfo:function(index,leftOffset,rightOffset,topOffset,bottomOffset){var ResizeBorderSize=this.ResizeBorderSize;var verticalDirection=this.GetResizeVerticalCourse(ResizeBorderSize,topOffset,bottomOffset);ResizeBorderSize=verticalDirection!=""?this.ResizeCornerBorderSize:this.ResizeBorderSize;var horizontalDirection=this.GetResizeHorizontalCourse(ResizeBorderSize,leftOffset,rightOffset);if(verticalDirection==""&&horizontalDirection!="")
verticalDirection=this.GetResizeVerticalCourse(this.ResizeCornerBorderSize,topOffset,bottomOffset);var horizontalOffset=leftOffset<rightOffset?leftOffset:rightOffset;var verticalOffset=topOffset<bottomOffset?topOffset:bottomOffset;return new ASPxPCResizeCursorInfo(horizontalDirection,verticalDirection,horizontalOffset,verticalOffset);},GetResizeVerticalCourse:function(ResizeBorderSize,topOffset,bottomOffset){if(ResizeBorderSize>topOffset)return"n";if(ResizeBorderSize>bottomOffset)return"s";return"";},GetResizeHorizontalCourse:function(ResizeBorderSize,leftOffset,rightOffset){if(ResizeBorderSize>leftOffset)return"w";if(ResizeBorderSize>rightOffset)return"e";return"";},UpdateResizeCursor:function(element,verticalDirection,horizontalDirection){var cursor=verticalDirection+horizontalDirection;if(cursor!=""){cursor+="-resize";this.ShowTemporaryCursor(element,cursor);}
else
this.HideTemporaryCursor(element);},ShowTemporaryCursor:function(element,cursor){_aspxChangeStyleAttribute(element,"cursor",cursor);},HideTemporaryCursor:function(element){_aspxRestoreStyleAttribute(element,"cursor");},ResizeWindowIFrame:function(index){if(!this.renderIFrameForPopupElements)return;if(!this.InternalIsWindowVisible(index))return;var iFrame=this.GetWindowIFrame(index);if(_aspxIsExists(iFrame)){var cell=this.GetWindowMainCell(this.GetWindowElement(index));_aspxSetStyleSize(iFrame,cell.offsetWidth,cell.offsetHeight);}},ShowDragCursor:function(index){var dragElement=this.GetDragElement(index);if(dragElement)
this.ShowTemporaryCursor(dragElement,"move");},HideDragCursor:function(index){var dragElement=this.GetDragElement(index);if(dragElement!=null)
this.HideTemporaryCursor(dragElement);},GetDragElement:function(index){var headerElement=this.GetWindowHeaderElement(index);var element=this.GetWindowElement(index);if(element!=null)
return(headerElement!=null?headerElement:this.GetWindowMainCell(element));return null;},OnActivateMouseDown:function(evt,index){this.OnActivate(index);},OnCloseButtonClick:function(index){this.RaiseCloseButtonClick(index);this.DoHideWindow(index);},OnMouseDown:function(evt,index,isDraggingAllowed){if(_aspxGetIsLeftButtonPressed(evt)){_aspxClearSelection();var isResizing=false;if(this.allowResize)
isResizing=this.OnResizeStart(evt,index);if(isDraggingAllowed&&!isResizing)
this.OnDragStart(evt,index);}},OnMouseMove:function(evt,index){this.CreateResizeCursorInfo(evt,index);},StartAnimation:function(animationDivElement,index,horizontalPopupPosition,verticalPopupPosition){var element=this.GetWindowMainTable(animationDivElement);var clientX=horizontalPopupPosition.position;var clientY=verticalPopupPosition.position;var args="(\""+this.name+"\", "+index+")";var onTimerString="aspxPCATimer"+args;var onAnimStopCallString="aspxPCAStop"+args;_aspxInitAnimationDiv(animationDivElement,clientX,clientY,onTimerString,onAnimStopCallString);var horizontalDirection=_aspxGetAnimationHorizontalDirection(horizontalPopupPosition,this.popupHorizontalAlign,this.popupVerticalAlign);var verticalDirection=_aspxGetAnimationVerticalDirection(verticalPopupPosition,this.popupHorizontalAlign,this.popupVerticalAlign);var xPos=horizontalDirection*animationDivElement.offsetHeight;var yPos=verticalDirection*animationDivElement.offsetWidth;_aspxSetStylePosition(element,xPos,yPos);_aspxSetElementVisibility(animationDivElement,true);this.DoShowWindowIFrame(index,clientX,clientY,0,0);animationDivElement.timerID=window.setTimeout(animationDivElement.onTimerString,this.animationDelay);},GetWindowsState:function(){var state="";if(this.HasDefaultWindow()){state+=this.GetWindowState(-1);}
for(var i=0;i<this.GetWindowCountCore();i++){state+=this.GetWindowState(i);if(i<this.GetWindowCountCore()-1)state+=";";}
return state;},GetWindowState:function(index){var element=this.GetWindowElement(index);if(element!=null){var mainCell=this.GetWindowMainCell(element);var visibleFlag=(!this.InternalIsWindowVisible(index)||element.isHiding)?"0":"1";var isDraggedFlag=this.GetIsDragged(index)?"1":"0";var zIndex=this.GetCurrentZIndex(index);var isResized=this.GetIsResized(index);var isResizedFlag=isResized?"1":"0";var width=isResized?this.GetCurrentWindowWidth(index):0;var height=isResized?this.GetCurrentWindowHeight(index):0;var state=visibleFlag+":"+isDraggedFlag+":"+zIndex+":"+
this.GetCurrentLeft(index)+":"+this.GetCurrentTop(index)+":"+isResizedFlag+":"+
width+":"+height;return state;}
return"";},UpdateWindowsStateCookie:function(){if(this.cookieName=="")return;_aspxDelCookie(this.cookieName);_aspxSetCookie(this.cookieName,this.GetWindowsState());},UpdateWindowsStateInputElement:function(){var element=this.GetWindowsStateInputElement();if(element!=null)element.value=this.GetWindowsState();},CreateWindows:function(windowsNames){for(var i=0;i<windowsNames.length;i++){var window=new ASPxClientPopupWindow(this,i,windowsNames[i]);_aspxArrayPush(this.windows,window);}},RaiseCloseButtonClick:function(index){var window=index<0?null:this.GetWindow(index);if(!this.CloseButtonClick.IsEmpty()){var args=new ASPxClientPopupWindowEventArgs(false,window);this.CloseButtonClick.FireEvent(this,args);}},RaiseCloseUp:function(index){var window=index<0?null:this.GetWindow(index);if(!this.CloseUp.IsEmpty()){var args=new ASPxClientPopupWindowEventArgs(false,window);this.CloseUp.FireEvent(this,args);}},RaisePopUp:function(index){var window=index<0?null:this.GetWindow(index);if(!this.PopUp.IsEmpty()){var args=new ASPxClientPopupWindowEventArgs(false,window);this.PopUp.FireEvent(this,args);}},RaiseResize:function(index){var window=index<0?null:this.GetWindow(index);if(!this.Resize.IsEmpty()){var args=new ASPxClientPopupWindowEventArgs(false,window);this.Resize.FireEvent(this,args);}},RaiseShowen:function(index){var window=index<0?null:this.GetWindow(index);if(!this.Shown.IsEmpty()){var args=new ASPxClientPopupWindowEventArgs(false,window);this.Shown.FireEvent(this,args);}},GetHeight:function(){return this.GetWindowHeight(null);},GetWidth:function(){return this.GetWindowWidth(null);},SetSize:function(width,height){this.SetWindowSize(null,width,height);},GetWindowHeight:function(window){var index=(window!=null)?window.index:-1;var element=this.GetWindowElement(index);var mainCell=this.GetWindowMainCell(element);return mainCell.offsetHeight;},GetWindowWidth:function(window){var index=(window!=null)?window.index:-1;var element=this.GetWindowElement(index);var mainCell=this.GetWindowMainCell(element);return mainCell.offsetWidth;},SetWindowSize:function(window,width,height){var index=(window!=null)?window.index:-1;this.SetClientWindowSize(index,width,height);var iFrame=this.GetWindowIFrame(index);if(_aspxIsExists(iFrame))
_aspxSetStyleSize(iFrame,width,height);},IsVisible:function(){return this.InternalIsWindowVisible(-1);},GetContentHTML:function(){return this.GetContentHtml();},SetContentHTML:function(html){this.SetContentHtml(html);},GetContentHtml:function(){return this.GetWindowContentHtml(null);},SetContentHtml:function(html){this.SetWindowContentHtml(null,html);},GetContentIFrame:function(window){return this.GetWindowContentIFrame(null);},GetContentUrl:function(){return this.GetWindowContentUrl(null);},SetContentUrl:function(url){this.SetWindowContentUrl(null,url);},RefreshContentUrl:function(){this.RefreshWindowContentUrl(null);},Show:function(){this.ShowWindow(null);},ShowAtElement:function(htmlElement){this.ShowWindowAtElement(null,htmlElement);},ShowAtElementByID:function(id){var htmlElement=document.getElementById(id);this.ShowWindowAtElement(null,htmlElement);},ShowAtPos:function(x,y){this.ShowWindowAtPos(null,Math.round(x),Math.round(y));},Hide:function(){this.HideWindow(null);},IsWindowVisible:function(window){var index=(window!=null)?window.index:-1;return this.InternalIsWindowVisible(index);},GetWindow:function(index){return(0<=index&&index<this.windows.length)?this.windows[index]:null;},GetWindowByName:function(name){for(var i=0;i<this.windows.length;i++)
if(this.windows[i].name==name)return this.windows[i];return null;},GetWindowCount:function(){return this.GetWindowCountCore();},ShowWindow:function(window){var index=(window!=null)?window.index:-1;this.DoShowWindowAtPos(index,__aspxInvalidPosition,__aspxInvalidPosition,false,false,true);},ShowWindowAtElement:function(window,htmlElement){var index=(window!=null)?window.index:-1;var popupElementBackup=this.GetPopupElement(index);this.SetPopupElementInternal(index,htmlElement);this.ShowWindow(window);this.SetPopupElementInternal(index,popupElementBackup);},ShowWindowAtElementByID:function(window,id){var htmlElement=document.getElementById(id);this.ShowWindowAtElement(window,htmlElement);},ShowWindowAtPos:function(window,x,y){var index=(window!=null)?window.index:-1;this.DoShowWindowAtPos(index,x,y,true,false,true);},HideWindow:function(window){var index=(window!=null)?window.index:-1;this.DoHideWindow(index);},GetWindowContentHTML:function(window){return this.GetWindowContentHtml(window);},SetWindowContentHTML:function(window,html){this.SetWindowContentHtml(window,html);},GetWindowContentHtml:function(window){var index=(window!=null)?window.index:-1;var element=this.GetWindowContentElement(index);return(element!=null)?element.innerHTML:"";},SetWindowContentHtml:function(window,html){var index=(window!=null)?window.index:-1;var element=this.GetWindowContentElement(index);if(element!=null){element.innerHTML=html;this.ResizeWindowIFrame(index);}},GetWindowContentIFrame:function(window){var index=(window!=null)?window.index:-1;return this.GetWindowContentIFrameElement(index);},GetWindowContentUrl:function(window){var index=(window!=null)?window.index:-1;if(!this.IsWindowVisible(window))
return this.GetWindowContentIFrameUrl(index);var element=this.GetWindowContentIFrameElement(index);return(element!=null)?element.src:"";},SetWindowContentUrl:function(window,url){var index=(window!=null)?window.index:-1;var element=this.GetWindowContentIFrameElement(index);this.SetWindowContentIFrameUrl(index,url);var src=(__aspxIE&&!this.IsWindowVisible(window))?this.SSLSecureBlankUrl:url;if(element==null)
this.CreateWidnowContentIFrameElement(index,src);else
element.src=src;},RefreshWindowContentUrl:function(window){this.SetWindowContentUrl(window,this.GetWindowContentUrl(window));},UpdatePosition:function(){this.UpdatePositionAtElement(this.GetPopupElement(-1));},UpdatePositionAtElement:function(popupElement){this.UpdateWindowPositionAtElement(null,popupElement);},UpdateWindowPosition:function(window){var index=(window!=null)?window.index:-1;this.UpdateWindowPositionAtElement(window,this.GetPopupElement(index));},UpdateWindowPositionAtElement:function(window,popupElement){var index=(window!=null)?window.index:-1;this.UpdateWindowPositionInternal(index,popupElement);},UpdateWindowPositionInternal:function(index,popupElement){var element=this.GetWindowElement(index);if(this.InternalIsWindowVisible(index)&&element!=null){var horizontalPopupPosition=this.GetClientPopupPos(element,popupElement,__aspxInvalidPosition,true,false);var verticalPopupPosition=this.GetClientPopupPos(element,popupElement,__aspxInvalidPosition,false,false);this.SetWindowPos(index,element,horizontalPopupPosition.position,verticalPopupPosition.position,true);}else
this.DoShowWindowAtPos(index,__aspxInvalidDimension,__aspxInvalidDimension,false,false,false);},CreateWidnowContentIFrameElement:function(index,src){var content=this.GetWindowContentElement(index);var iframeParent=content;content.innerHTML="";var iframe=this.CreateContentIFrameElement(index,src);var iframeDiv=null;if(!__aspxIE){iframeDiv=this.CreateContentIFrameDivElement(index);content.appendChild(iframeDiv);iframeParent=iframeDiv;}
iframeParent.appendChild(iframe);if(!__aspxIE){if(__aspxOpera)
iframe.style.height="100%";else
iframe.style.height=iframeDiv.clientHeight+"px";}
return iframe;},CreateContentIFrameElement:function(index,src){var iframe=document.createElement("IFRAME");iframe.id=this.GetWindowContentIFrameElementId(index);iframe.scrolling="auto";iframe.frameBorder=0;iframe.style.width="100%";iframe.style.height=__aspxIE?"100%":"0px";iframe.src=src;return iframe;},CreateContentIFrameDivElement:function(index){var iframeDiv=document.createElement("DIV");iframeDiv.id=this.GetWindowContentIFrameDivElementID(index);iframeDiv.style.width="100%";iframeDiv.style.height="100%";return iframeDiv;},GetWindowHeaderTextCell:function(index){return this.GetWindowChild(index,"_PWH"+index+"T");},GetWindowHeaderImageCell:function(index){return this.GetWindowChild(index,"_PWH"+index+"I");},GetWindowFooterTextCell:function(index){return this.GetWindowChild(index,"_PWF"+index+"T");},GetWindowFooterImageCell:function(index){return this.GetWindowChild(index,"_PWF"+index+"I");},GetWindowHeaderImageUrl:function(index){var element=this.GetWindowHeaderImageCell(index);if(element!=null){var img=_aspxGetChildByTagName(element,"IMG",0);if(img!=null)
return img.src;}
return"";},SetWindowHeaderImageUrl:function(index,url){var element=this.GetWindowHeaderImageCell(index);if(element!=null){var img=_aspxGetChildByTagName(element,"IMG",0);if(img!=null)
img.src=url;}},GetWindowFooterImageUrl:function(index){var element=this.GetWindowFooterImageCell(index);if(element!=null){var img=_aspxGetChildByTagName(element,"IMG",0);if(img!=null)
return img.src;}
return"";},SetWindowFooterImageUrl:function(index,url){var element=this.GetWindowFooterImageCell(index);if(element!=null){var img=_aspxGetChildByTagName(element,"IMG",0);if(img!=null)
img.src=url;}},GetWindowHeaderNavigateUrl:function(index){var element=this.GetWindowHeaderTextCell(index);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
return link.href;}
element=this.GetWindowHeaderImageCell(index);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
return link.href;}
return"";},SetWindowHeaderNavigateUrl:function(index,url){var element=this.GetWindowHeaderTextCell(index);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
link.href=url;}
var element=this.GetWindowHeaderImageCell(index);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
link.href=url;}},GetWindowFooterNavigateUrl:function(index){var element=this.GetWindowFooterTextCell(index);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
return link.href;}
element=this.GetWindowFooterImageCell(index);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
return link.href;}
return"";},SetWindowFooterNavigateUrl:function(index,url){var element=this.GetWindowFooterTextCell(index);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
link.href=url;}
var element=this.GetWindowFooterImageCell(index);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
link.href=url;}},GetWindowHeaderText:function(index){var element=this.GetWindowHeaderTextCell(index);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
return link.innerHTML;else
return element.innerHTML;}
return"";},SetWindowHeaderText:function(index,text){var element=this.GetWindowHeaderTextCell(index);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
link.innerHTML=text;else
element.innerHTML=text;}},GetWindowFooterText:function(index){var element=this.GetWindowFooterTextCell(index);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
return link.innerHTML;else
return element.innerHTML;}
return"";},SetWindowFooterText:function(index,text){var element=this.GetWindowFooterTextCell(index);if(element!=null){var link=_aspxGetChildByTagName(element,"A",0);if(link!=null)
link.innerHTML=text;else
element.innerHTML=text;}},GetHeaderImageUrl:function(){return this.GetWindowHeaderImageUrl(-1);},SetHeaderImageUrl:function(value){this.SetWindowHeaderImageUrl(-1,value);},GetFooterImageUrl:function(){return this.GetWindowFooterImageUrl(-1);},SetFooterImageUrl:function(value){this.SetWindowFooterImageUrl(-1,value);},GetHeaderNavigateUrl:function(){return this.GetWindowHeaderNavigateUrl(-1);},SetHeaderNavigateUrl:function(value){this.SetWindowHeaderNavigateUrl(-1,value);},GetFooterNavigateUrl:function(){return this.GetWindowFooterNavigateUrl(-1);},SetFooterNavigateUrl:function(value){this.SetWindowFooterNavigateUrl(-1,value);},GetHeaderText:function(){return this.GetWindowHeaderText(-1);},SetHeaderText:function(value){this.SetWindowHeaderText(-1,value);},GetFooterText:function(){return this.GetWindowFooterText(-1);},SetFooterText:function(value){this.SetWindowFooterText(-1,value);},GetVisible:function(){return this.IsVisible();},SetVisible:function(visible){if(visible&&!this.IsVisible())
this.Show();else if(!visible&&this.IsVisible())
this.Hide();}});ASPxClientPopupControl.GetPopupControlCollection=function(){return aspxGetPopupControlCollection();}
ASPxClientPopupControlCollection=_aspxCreateClass(ASPxClientControlCollection,{constructor:function(){this.constructor.prototype.constructor.call(this);this.draggingControl=null;this.draggingWindowIndex=-1;this.gragXOffset=0;this.gragYOffset=0;this.visibleModalElements=new Array();this.visiblePopupWindowIds=new Array();this.zIndex=__aspxPopupControlZIndex;this.overControl=null;this.overWindowIndex=-1;this.overXPos=__aspxInvalidPosition;this.overYPos=__aspxInvalidPosition;this.appearTimerID=-1;this.disappearTimerID=-1;this.resizeControl=null;this.resizeIndex=-2;this.resizeCursor="";this.resizePanel=null;this.selectBanned=false;},DoHideAllWindows:function(srcElement,excptId,applyToAll){for(var i=this.visiblePopupWindowIds.length-1;i>=0;i--){var id=this.visiblePopupWindowIds[i];if(id==excptId)continue;if(srcElement!=null&&_aspxGetParentById(srcElement,id)!=null)continue;var pos=id.lastIndexOf(__aspxPCWIdSuffix);var name=id.substring(0,pos);var index=id.substr(pos+__aspxPCWIdSuffix.length);var popupControl=aspxGetPopupControlCollection().Get(name);if(popupControl!=null&&((popupControl.closeAction!="CloseButton"&&popupControl.closeAction!="None")||applyToAll)){popupControl.DoHideWindow(parseInt(index));}}},DoShowAtCurrentPos:function(name,index){var pc=this.Get(name);if(pc!=null&&!pc.InternalIsWindowVisible(index))
pc.DoShowWindowAtPos(index,this.overXPos,this.overYPos,false,true,true);},ActivateWindowElement:function(element){var visibleWindowsCount=this.visiblePopupWindowIds.length;if(__aspxPopupControlZIndex<=element.style.zIndex&&element.style.zIndex!=visibleWindowsCount*2+__aspxPopupControlZIndex){this.DeleteWindowFromZIndexOrder(element);}
this.SetWindowElementZIndex(element,__aspxPopupControlZIndex+visibleWindowsCount*2);},DeleteWindowFromZIndexOrder:function(element){for(var i=this.visiblePopupWindowIds.length-1;i>=0;i--){var windowElement=_aspxGetElementById(this.visiblePopupWindowIds[i]);if(!_aspxIsExists(windowElement))
_aspxArrayRemoveAt(this.visiblePopupWindowIds,i);else if(windowElement.style.zIndex>element.style.zIndex)
this.SetWindowElementZIndex(windowElement,windowElement.style.zIndex-2);}},SetWindowElementZIndex:function(element,zIndex){element.style.zIndex=zIndex;var iFrame=element.overflowElement;if(_aspxIsExists(iFrame))
iFrame.style.zIndex=zIndex-1;var modalElement=element.modalElement;if(_aspxIsExists(modalElement))
modalElement.style.zIndex=zIndex-1;this.UpdateWindowsStateInputElement(element.id);this.UpdateWindowsStateCookie(element.id);},AdjustModalElementsBounds:function(){for(var i=0;i<this.visibleModalElements.length;i++)
this.AdjustModalElementBounds(this.visibleModalElements[i]);},AdjustModalElementBounds:function(element){if(!_aspxIsExistsElement(element))return;var x=_aspxPrepareClientPosForElement(0,element,true);var y=_aspxPrepareClientPosForElement(0,element,false);_aspxSetStylePosition(element,x,y);if(__aspxNS)_aspxSetStyleSize(element,1,1);_aspxSetStyleSize(element,_aspxGetDocumentWidth(),_aspxGetDocumentHeight());},ClearAppearTimer:function(){this.appearTimerID=_aspxClearTimer(this.appearTimerID);},ClearDisappearTimer:function(){this.disappearTimerID=_aspxClearTimer(this.disappearTimerID);},IsAppearTimerActive:function(){return this.appearTimerID>-1;},IsDisappearTimerActive:function(){return this.disappearTimerID>-1;},SetAppearTimer:function(name,index,timeout){this.appearTimerID=_aspxSetTimeout("aspxPEMOverTimer(\""+name+"\", "+index+")",timeout);},SetDisappearTimer:function(name,index,timeout){this.disappearTimerID=_aspxSetTimeout("aspxPEMOutTimer(\""+name+"\", "+index+")",timeout);},InitDragObject:function(control,index,x,y){this.draggingControl=control;this.draggingWindowIndex=index;this.gragXOffset=x;this.gragYOffset=y;this.selectBanned=true;},InitOverObject:function(control,index,evt){this.overControl=control;this.overWindowIndex=index;this.SaveCurrentMouseOverPos(evt);},InitResizeObject:function(control,index,cursor,resizePanel){this.resizeControl=control;this.resizeIndex=index;this.resizeCursor=cursor;this.resizePanel=resizePanel;this.selectBanned=true;},IsResizeInint:function(){return this.resizeControl!=null;},ClearDragObject:function(){this.draggingControl=null;this.draggingWindowIndex=-1;this.gragXOffset=0;this.gragYOffset=0;this.selectBanned=this.resizeControl!=null;},ClearResizeObject:function(){this.resizeControl=null;this.resizeIndex=-2;this.resizeCursor="";this.selectBanned=this.draggingControl!=null;this.resizePanel.parentNode.removeChild(this.resizePanel);},Drag:function(evt){var x=_aspxGetEventX(evt)+this.gragXOffset;var y=_aspxGetEventY(evt)+this.gragYOffset;this.draggingControl.OnDrag(this.draggingWindowIndex,x,y);},DragStop:function(){this.draggingControl.OnDragStop(this.draggingWindowIndex);this.ClearDragObject();},ResizeStop:function(evt){this.resizeControl.OnResizeStop(evt,this.resizeIndex,this.resizeCursor,this.resizePanel);aspxGetPopupControlCollection().ClearResizeObject();},OnPWMouseMove:function(evt,name,index){if(this.draggingControl==null&&this.overControl==null&&this.resizeControl==null){var pc=aspxGetPopupControlCollection().Get(name);if(pc!=null)pc.OnMouseMove(evt,index);}},OnMouseDown:function(evt){var srcElement=_aspxGetEventSource(evt);this.DoHideAllWindows(srcElement,"",false);aspxGetPopupControlCollection().ClearAppearTimer();},OnMouseMove:function(evt){if(this.draggingControl!=null){if(__aspxIE&&!_aspxGetIsLeftButtonPressed(evt))
return this.DragStop();else
this.Drag(evt);}
else if(this.overControl!=null){this.OnMouseOver(evt);}
else if(this.resizeControl!=null){if(__aspxIE&&!_aspxGetIsLeftButtonPressed(evt))
this.ResizeStop(evt);else
this.resizeControl.OnResize(evt,this.resizeIndex,this.resizeCursor,this.resizePanel);}},OnMouseOver:function(evt){var element=_aspxFindParentPopupElementByEvent(evt,aspxTestPopupControlOverElement);if(element!=null){this.ClearDisappearTimer();this.SaveCurrentMouseOverPos(evt);return _aspxCancelBubble(evt);}
this.OnMouseOut();},OnMouseOut:function(){if(!_aspxIsExists(this.overControl)||_aspxIsExists(this.draggingControl))return;this.ClearAppearTimer();if(this.overControl.closeAction=="MouseOut"&&this.overControl.InternalIsWindowVisible(this.overWindowIndex)){if(!this.IsDisappearTimerActive())
this.SetDisappearTimer(this.overControl.name,this.overWindowIndex,this.overControl.disappearAfter);}
else
this.OverStop();},OnMouseUp:function(evt){if(this.draggingControl!=null)
this.DragStop();if(this.resizeControl!=null)
this.ResizeStop(evt);},OnResize:function(evt){this.AdjustModalElementsBounds();},OnScroll:function(evt){this.AdjustModalElementsBounds();},OnSelectStart:function(){return!this.selectBanned;},OverStop:function(){this.overControl=null;this.overWindowIndex=-1;},SaveCurrentMouseOverPos:function(evt){this.overXPos=_aspxGetEventX(evt);this.overYPos=_aspxGetEventY(evt);},RegisterVisibleModalElement:function(element){if(_aspxArrayIndexOf(this.visibleModalElements,element)==-1)
_aspxArrayPush(this.visibleModalElements,element);},UnregisterVisibleModalElement:function(element){_aspxArrayRemove(this.visibleModalElements,element);},RegisterVisibleWindow:function(element){if(_aspxArrayIndexOf(this.visiblePopupWindowIds,element.id)==-1)
_aspxArrayPush(this.visiblePopupWindowIds,element.id);},UnregisterVisibleWindow:function(element){this.DeleteWindowFromZIndexOrder(element);_aspxArrayRemove(this.visiblePopupWindowIds,element.id);},UpdateWindowsStateCookie:function(id){var pos=id.lastIndexOf(__aspxPCWIdSuffix);var name=id.substring(0,pos);var popupControl=aspxGetPopupControlCollection().Get(name);if(popupControl!=null)
popupControl.UpdateWindowsStateCookie(false);},UpdateWindowsStateInputElement:function(id){var pos=id.lastIndexOf(__aspxPCWIdSuffix);var name=id.substring(0,pos);var popupControl=aspxGetPopupControlCollection().Get(name);if(popupControl!=null)
popupControl.UpdateWindowsStateInputElement(false);},HideAllWindows:function(){this.DoHideAllWindows(null,"",true);}});var __aspxPopupControlCollection=null;function aspxGetPopupControlCollection(){if(__aspxPopupControlCollection==null)
__aspxPopupControlCollection=new ASPxClientPopupControlCollection();return __aspxPopupControlCollection;}
ASPxClientPopupWindow=_aspxCreateClass(null,{constructor:function(popupControl,index,name){this.popupControl=popupControl;this.index=index;this.name=name;},GetHeaderImageUrl:function(){return this.popupControl.GetWindowHeaderImageUrl(this.index);},SetHeaderImageUrl:function(value){this.popupControl.SetWindowHeaderImageUrl(this.index,value);},GetFooterImageUrl:function(){return this.popupControl.GetWindowFooterImageUrl(this.index);},SetFooterImageUrl:function(value){this.popupControl.SetWindowFooterImageUrl(this.index,value);},GetHeaderNavigateUrl:function(){return this.popupControl.GetWindowHeaderNavigateUrl(this.index);},SetHeaderNavigateUrl:function(value){this.popupControl.SetWindowHeaderNavigateUrl(this.index,value);},GetFooterNavigateUrl:function(){return this.popupControl.GetWindowFooterNavigateUrl(this.index);},SetFooterNavigateUrl:function(value){this.popupControl.SetWindowFooterNavigateUrl(this.index,value);},GetHeaderText:function(){return this.popupControl.GetWindowHeaderText(this.index);},SetHeaderText:function(value){this.popupControl.SetWindowHeaderText(this.index,value);},GetFooterText:function(){return this.popupControl.GetWindowFooterText(this.index);},SetFooterText:function(value){this.popupControl.SetWindowFooterText(this.index,value);}});ASPxClientPopupWindowEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(processOnServer,window){this.constructor.prototype.constructor.call(this);this.window=window;}});function aspxPEMOverTimer(name,index){aspxGetPopupControlCollection().DoShowAtCurrentPos(name,index);}
function aspxPEMOutTimer(name,index){var pc=aspxGetPopupControlCollection().Get(name);aspxGetPopupControlCollection().OverStop();if(pc!=null)pc.DoHideWindow(index);}
function aspxPWCBClick(name,index){var pc=aspxGetPopupControlCollection().Get(name);if(pc!=null)pc.OnCloseButtonClick(index);}
function aspxPWCBMDown(evt){return _aspxCancelBubble(evt);}
function aspxPEMOver(evt){var element=_aspxFindParentPopupElementByEvent(evt,aspxTestPopupControlElement);if(element!=null){var popupControl=element.DXPopupControl;var index=element.DXPopupWindowIndex;if(!popupControl.InternalIsWindowVisible(index)){aspxGetPopupControlCollection().SetAppearTimer(popupControl.name,index,popupControl.appearAfter);aspxGetPopupControlCollection().InitOverObject(popupControl,index,evt);}}}
function aspxPWMEMDown(evt){var element=_aspxGetEventSource(evt);if(element!=null){var popupElement=element.DXModalPopupControl.GetPopupElement(element.DXModalPopupWindowIndex);popupElement.isPopuped=true;}}
function aspxPEMEvent(evt){var element=_aspxFindParentPopupElementByEvent(evt,aspxTestPopupControlElement);if(element!=null){if(evt.type=="mousedown"){if(element.DXPopupControl.InternalIsWindowVisible(element.DXPopupWindowIndex))
element.isPopuped=true;else
element.isPopuped=false;aspxGetPopupControlCollection().OnMouseDown(evt);}
else{if(element.DXPopupControl.popupAction=="RightMouseClick"||_aspxGetIsLeftButtonPressed(evt)){if(element.DXPopupControl.popupAction=="RightMouseClick")
_aspxPreventContextMenu(evt);if(!(element.isPopuped&&element.DXPopupControl.closeAction=="OuterMouseClick"))
element.DXPopupControl.DoShowWindow(element.DXPopupWindowIndex,evt);if(element.DXPopupControl.closeAction=="MouseOut")
aspxGetPopupControlCollection().InitOverObject(element.DXPopupControl,element.DXPopupWindowIndex,evt);return false;}}}}
function aspxPWDGMDown(evt,name,index){var pc=aspxGetPopupControlCollection().Get(name);if(pc!=null){pc.OnActivateMouseDown(evt,index);pc.OnMouseDown(evt,index,true);}
if(!__aspxIE)
evt.preventDefault();return aspxPWCBMDown(evt);}
function aspxPWGripMDown(evt,name,index){aspxPWMDown(evt,name,index,false);return aspxPWCBMDown(evt);}
function aspxPWMDown(evt,name,index,isDraggingAllowed){var pc=aspxGetPopupControlCollection().Get(name);if(pc!=null){pc.OnActivateMouseDown(evt,index);pc.OnMouseDown(evt,index,isDraggingAllowed);}}
function aspxPWResize(name,index){var pc=aspxGetPopupControlCollection().Get(name);if(pc!=null)pc.ResizeWindowIFrame(index);}
function aspxPWMMove(evt,name,index){aspxGetPopupControlCollection().OnPWMouseMove(evt,name,index);}
function aspxPCATimer(name,index){var pc=aspxGetPopupControlCollection().Get(name);if(pc!=null)pc.OnAnimationTimer(index);}
function aspxPCAStop(name,index){var pc=aspxGetPopupControlCollection().Get(name);if(pc!=null)pc.OnAnimationStop(index);}
_aspxAttachEventToDocument("mousedown",aspxPopupControlDocumentMouseDown);function aspxPopupControlDocumentMouseDown(evt){if(_aspxFindParentPopupElementByEvent(evt,aspxTestPopupControlElement)==null)
return aspxGetPopupControlCollection().OnMouseDown(evt);}
_aspxAttachEventToDocument("mouseup",aspxPopupControlDocumentMouseUp);function aspxPopupControlDocumentMouseUp(evt){return aspxGetPopupControlCollection().OnMouseUp(evt);}
_aspxAttachEventToDocument("mousemove",aspxPopupControlDocumentMouseMove);function aspxPopupControlDocumentMouseMove(evt){if(typeof(aspxGetPopupControlCollection)!="undefined")
aspxGetPopupControlCollection().OnMouseMove(evt);}
_aspxAttachEventToDocument("mouseout",aspxPopupControlDocumentMouseOut);function aspxPopupControlDocumentMouseOut(){if(typeof(aspxGetPopupControlCollection)!="undefined")
aspxGetPopupControlCollection().OnMouseOut();}
_aspxAttachEventToElement(window,"resize",aspxPopupControlWindowResize);function aspxPopupControlWindowResize(evt){aspxGetPopupControlCollection().OnResize(evt);}
_aspxAttachEventToElement(window,"scroll",aspxPopupControlWindowScroll);function aspxPopupControlWindowScroll(evt){aspxGetPopupControlCollection().OnScroll(evt);}
_aspxAttachEventToDocument("selectstart",aspxPopupControlDocumentSelectStart);function aspxPopupControlDocumentSelectStart(evt){var ret=aspxGetPopupControlCollection().OnSelectStart(evt);if(!ret)return false;}
function aspxTestPopupControlElement(element){return(_aspxIsExists(element.DXPopupControl)&&_aspxIsExists(element.DXPopupWindowIndex));}
function aspxTestPopupControlOverElement(element){var collection=aspxGetPopupControlCollection();var windowId=collection.overControl.GetWindowElementId(collection.overWindowIndex);var popupElementId=collection.overControl.GetPopupElement(collection.overWindowIndex).id;return(element.id==windowId||element.id==popupElementId);}
var __aspxTINonProcessingSymbols=["^","\\","\'"];var __aspxTIWildCards=["*","?"];var __aspxTIGroupElementClassName="dxg";var __aspxTIItemElementClassName="dxtxi";var __aspxTITextElementClassName="dxtxt";var __aspxTIDefaultFilterIntervalDelay=200;ASPxClientTitleIndex=_aspxCreateClass(ASPxClientControl,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.allowMultipleCallbacks=false;this.autoFocus=false;this.columnCount=1;this.filterDelay=0;this.rowCount=-1;this.showBackToTop=false;this.groupSpacing=0;this.groupContentPaddingBottom=0;this.groupContentPaddingTop=0;this.lastFilterMask="";this.pasteTimerID=-1;this.filterTimerID=-1;this.mainCellWidth=0;this.columnElements=new Object();this.groupElements=new Object();this.itemElements=new Object();this.ItemClick=new ASPxClientEvent();this.InitializeAutoComplete();},Initialize:function(){if(_aspxIsExists(this.GetFilterInputElement())){this.CleanWhitespaceInControl();if(this.filterDelay>__aspxTIDefaultFilterIntervalDelay)
__aspxTIDefaultFilterIntervalDelay=this.filterDelay;}
if(this.autoFocus&&_aspxIsExists(this.GetFilterInputElement())&&_aspxIsFocusable(this.GetFilterInputElement()))
this.GetFilterInputElement().focus();this.constructor.prototype.Initialize.call(this);},InitializeAutoComplete:function(){var element=this.GetFilterInputElement();if(_aspxIsExists(element))element.autocomplete="off";},GetCategoryHeaderElement:function(rowIndex){return this.GetChild("_CH"+rowIndex);},GetColumnElement:function(index,rowIndex){var columnId=(this.rowCount>0)?"_C"+index+"_"+rowIndex:"_C"+index;if(!_aspxIsExistsElement(this.columnElements[columnId]))
this.columnElements[columnId]=this.GetChild(columnId);return this.columnElements[columnId];},GetContentTDWidth:function(){return _aspxGetParentByTagName(this.GetCategoryHeaderElement(0),'td').clientWidth;},GetEmptyResultCaptionElement:function(){return this.GetChild("_TI_E");},GetFilterInputElement:function(){return this.GetChild("_FI");},GetGroupElements:function(columnElement){if(!_aspxIsValidElements(this.groupElements[columnElement.id]))
this.groupElements[columnElement.id]=_aspxGetChildsByClassName(columnElement,__aspxTIGroupElementClassName);return this.groupElements[columnElement.id];},GetItemText:function(nodeElement){var textElem=this.GetItemTextElement(nodeElement);if(_aspxIsExists(textElem)&&_aspxIsExists(textElem.nodeValue))
return _aspxTrim(textElem.nodeValue);else
return"";},GetItemElements:function(groupElement){var groupText=this.GetItemText(groupElement);if(!_aspxIsValidElements(this.itemElements[groupText]))
this.itemElements[groupText]=_aspxGetChildsByClassName(groupElement,__aspxTIItemElementClassName);return this.itemElements[groupText];},GetItemTextElement:function(nodeElement){var textElement=_aspxGetChildsByClassName(nodeElement,__aspxTITextElementClassName)[0];return _aspxIsExists(textElement)?_aspxGetChildTextNode(textElement,0):null;},GetIndexPanelIndexInputElement:function(){return _aspxGetElementById(this.name+"PI");},GetContentCell:function(){return this.GetChild("_CCell");},GetTreeViewCell:function(){return this.GetChild("_ICell");},SetPrevFilterMask:function(filterMask){if(!_aspxIsExists(this.lastFilterMask))
this.lastFilterMask="";this.lastFilterMask=filterMask;},SetFilterTimer:function(fi,timeout){var str="aspxSFilterTimer(\""+this.name+"\")";if(timeout==0)
eval(str);else
this.filterTimerID=_aspxSetTimeout(str,timeout);},SetPasteTimer:function(){var str="aspxSPasteTimer(\""+this.name+"\")";this.pasteTimerID=_aspxSetInterval(str,__aspxTIDefaultFilterIntervalDelay);},ClearFilterTimer:function(){this.filterTimerID=_aspxClearTimer(this.filterTimerID);},ClearPasteTimer:function(){this.pasteTimerID=_aspxClearInterval(this.pasteTimerID);},CleanWhitespaceInControl:function(){if(this.rowCount>0)
this.CleanWhitespace(_aspxGetParentByTagName(this.GetCategoryHeaderElement(0),"table"));else{for(var j=0;j<this.columnCount;j++)
this.CleanWhitespace(this.GetColumnElement(j,-1));}},CleanWhitespace:function(element){if(element.hasChildNodes()){var i=0;while(i<element.childNodes.length){var node=element.childNodes[i];if(node.nodeType==3&&!/\S/.test(node.nodeValue))
node.parentNode.removeChild(node);else{i++;if(node.nodeType!=3)
this.CleanWhitespace(node);}}}},CreateFilterRegEx:function(filterMask){var regExString="^";for(var i=0;i<filterMask.length;i++){var index=_aspxArrayIndexOf(__aspxTIWildCards,filterMask.charAt(i));if(index>-1){switch(index){case 0:regExString+=".*";break;case 1:regExString+=".{1}";break;}}
else{var index=_aspxArrayIndexOf(__aspxTINonProcessingSymbols,filterMask.charAt(i));if(index==-1)
regExString+="["+filterMask.charAt(i)+"]";}}
regExString+=".*";return new RegExp(regExString,'i');},OnCallback:function(result){var inputElement=this.GetIndexPanelIndexInputElement();if(inputElement!=null)
inputElement.value=result.index;var element=this.GetContentCell();if(element!=null)
element.innerHTML=result.html;},IsAllowableKeyCode:function(keyCode){return(((keyCode>=48)&&(keyCode<=57))||((keyCode>=186)&&(keyCode<=192))||((keyCode>=219)&&(keyCode<=226))||((keyCode>=65)&&(keyCode<=90))||((keyCode>=65)&&(keyCode<=90))||((keyCode>=96)&&(keyCode<=107))||((keyCode>=109)&&(keyCode<=111))||keyCode==8||keyCode==45||keyCode==46);},IsFirstCategoryTR:function(categoryElem){var spacingElem=categoryElem.parentNode.previousSibling;return!_aspxIsExists(spacingElem);},IsFirstCategory:function(categoryElem,index){var i=index-1;while(i>=0){if(_aspxGetElementDisplay(this.GetCategoryHeaderElement(i).parentNode))
return false;i--;}
return true;},IsFirstGroupInColumn:function(groupIndex,columnElem){var groupElements=this.GetGroupElements(columnElem);var i=groupIndex-1;while(i>=0){if(_aspxGetElementDisplay(groupElements[i]))
return false;i--;}
return true;},IsFilterTimerActive:function(){return this.filterTimerID>-1;},IsFilterMaskChanged:function(filterMask){if(!_aspxIsExists(this.lastFilterMask))
this.lastFilterMask="";return this.lastFilterMask.toUpperCase()!=filterMask.toUpperCase();},CorrectCategorySpacing:function(categoryElem,index){var headerTR=categoryElem.parentNode;if(!this.IsFirstCategoryTR(categoryElem)&&(this.groupSpacing!=0)&&this.IsFirstCategory(categoryElem,index))
_aspxSetElementDisplay(headerTR.previousSibling,false);},CorrectNodesPaddings:function(columnIndex,rowIndex){var columnElem=this.GetColumnElement(columnIndex,rowIndex);var groupElements=this.GetGroupElements(columnElem);for(var i=0;i<groupElements.length;i++){if(_aspxGetElementDisplay(groupElements[i])){if(this.IsFirstGroupInColumn(i,columnElem))
_aspxChangeStyleAttribute(groupElements[i],"paddingTop",0);else
_aspxRestoreStyleAttribute(groupElements[i],"paddingTop");this.CorrectGroupContentPadding(groupElements[i]);}}},CorrectGroupContentPadding:function(groupElement){var itemElements=this.GetItemElements(groupElement);for(var i=0;i<itemElements.length;i++){if(_aspxGetElementDisplay(itemElements[i])){if(i==0)
_aspxChangeStyleAttribute(itemElements[i],"paddingTop",0);else
_aspxRestoreStyleAttribute(itemElements[i],"paddingTop");}}},DoIndexPanelItemClick:function(value){var inputElement=this.GetIndexPanelIndexInputElement();if(inputElement!=null){if(_aspxIsExists(this.GetFilterInputElement()))
this.GetFilterInputElement().disabled=true;this.CreateCallback(value+__aspxCallbackSeparator+value);}},DoBeginCallback:function(command){this.CreateLoadingPanelWithAbsolutePosition(this.GetTreeViewCell());ASPxClientControl.prototype.DoBeginCallback.call(this,command);},OnControlClick:function(clickedElement,htmlEvent){var itemElement=_aspxGetParentByClassName(clickedElement,__aspxItemClassName);if(_aspxIsExists(itemElement)){var processOnServer=this.RaiseItemClick(itemElement,htmlEvent);var hasItemLink=this.GetLinkElement(itemElement)!=null;if(processOnServer&&!hasItemLink){var name=this.GetItemElementName(itemElement);this.SendPostBack("CLICK:"+name);}}},RaiseItemClick:function(itemElement,htmlEvent){var processOnServer=this.autoPostBack||this.IsServerEventAssigned("ItemClick");if(!this.ItemClick.IsEmpty()){var name=this.GetItemElementName(itemElement);var args=new ASPxClientTitleIndexItemEventArgs(processOnServer,name,itemElement,htmlEvent);this.ItemClick.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;},DoFilter:function(filterMask){filterMask=_aspxTrim(filterMask);if(this.IsFilterMaskChanged(filterMask)){this.SetPrevFilterMask(filterMask);var filterRegEx=this.CreateFilterRegEx(filterMask);var isData=false;if(this.rowCount>0){var categoryCount=0;if(this.GetContentTDWidth()!=0)
this.mainCellWidth=this.GetContentTDWidth();for(var i=0;i<this.rowCount;i++){var categoryElem=this.GetCategoryHeaderElement(i);var visibleColCount=0;for(var j=0;j<this.columnCount;j++){var visibleItemCount=this.FilterColumnInCategory(j,i,filterMask,filterRegEx);if(visibleItemCount!=0)
visibleColCount++;}
if(visibleColCount!=0){this.ShowCategory(categoryElem);this.CorrectCategorySpacing(categoryElem,i);categoryCount++;}
else
this.HideCategory(categoryElem);}
isData=categoryCount!=0;}
else{var visibleColCount=0;for(var i=0;i<this.columnCount;i++){var visibleCategoryNodeCount=this.FilterColumn(i,-1,filterMask,filterRegEx);this.CorrectNodesPaddings(i,-1);if(visibleCategoryNodeCount!=0)
visibleColCount++;}
isData=visibleColCount!=0;}
if(isData)
this.HideEmptyResultCaption();else
this.ShowEmptyResultCaption();}},DoFilterInternal:function(){this.DoFilter(this.GetFilterInputElement().value);},FilterColumn:function(columnIndex,rowIndex,filterMask,filterRegEx){var columnElem=this.GetColumnElement(columnIndex,rowIndex);var groupElements=this.GetGroupElements(columnElem);var visibleGroupCount=0;for(var i=0;i<groupElements.length;i++){visibleItemsCount=this.FilterItems(groupElements[i],filterRegEx);if(visibleItemsCount>0){visibleGroupCount++;this.ShowGroup(groupElements[i]);}
else
this.HideGroup(groupElements[i]);}
if(visibleGroupCount!=0){_aspxSetElementVisibility(columnElem,true);this.SetColumnSeparatorDisplay(columnElem,true,columnIndex,rowIndex);}
else{_aspxSetElementVisibility(columnElem,false);this.SetColumnSeparatorDisplay(columnElem,false,columnIndex,rowIndex);}
return visibleGroupCount;},FilterColumnInCategory:function(columnIndex,rowIndex,filterMask,filterRegEx){var columnElem=this.GetColumnElement(columnIndex,rowIndex);var visibleItemCount=0;if(_aspxIsExists(columnElem)){var itemElements=this.GetItemElements(columnElem);for(var i=0;i<itemElements.length;i++){var itemText=this.GetItemText(itemElements[i]);if(!filterRegEx.test(itemText))
_aspxSetElementDisplay(itemElements[i],false);else{_aspxSetElementDisplay(itemElements[i],true);visibleItemCount++;}}
if(visibleItemCount!=0){this.SetColumnSeparatorDisplay(columnElem,true,columnIndex,rowIndex);}
else{this.SetColumnSeparatorDisplay(columnElem,false,columnIndex,rowIndex);}}
return visibleItemCount;},FilterItems:function(parentNodeElem,filterRegEx){var itemElements=this.GetItemElements(parentNodeElem);var visibleNodeCount=0;for(var i=0;i<itemElements.length;i++){var itemText=this.GetItemText(itemElements[i]);if(filterRegEx.test(itemText)){_aspxSetElementDisplay(itemElements[i],true);visibleNodeCount++;}
else
_aspxSetElementDisplay(itemElements[i],false);}
return visibleNodeCount;},ShowCategory:function(categoryElement){var headerTR=categoryElement.parentNode;_aspxSetElementDisplay(headerTR,true);if((this.groupSpacing!=0)&&!this.IsFirstCategoryTR(categoryElement))
_aspxSetElementDisplay(headerTR.previousSibling,true);var categoryContentElem=null;if(this.groupContentPaddingTop==0){categoryContentElem=headerTR.nextSibling;_aspxSetElementDisplay(headerTR.nextSibling,true);}
else{_aspxSetElementDisplay(headerTR.nextSibling,true);categoryContentElem=headerTR.nextSibling.nextSibling;_aspxSetElementDisplay(headerTR.nextSibling.nextSibling,true);}
if(this.groupContentPaddingBottom!=0)
_aspxSetElementDisplay(categoryContentElem.nextSibling,true);if(this.showBackToTop){if(this.groupContentPaddingBottom!=0)
_aspxSetElementDisplay(categoryContentElem.nextSibling.nextSibling,true);else
_aspxSetElementDisplay(categoryContentElem.nextSibling,true);}},HideCategory:function(categoryElement){var headerTR=categoryElement.parentNode;_aspxSetElementDisplay(headerTR,false);if((this.groupSpacing!=0)&&!this.IsFirstCategoryTR(categoryElement))
_aspxSetElementDisplay(headerTR.previousSibling,false);var categoryContentElem=null;if(this.groupContentPaddingTop==0){categoryContentElem=headerTR.nextSibling;_aspxSetElementDisplay(headerTR.nextSibling,false);}
else{_aspxSetElementDisplay(headerTR.nextSibling,false);categoryContentElem=headerTR.nextSibling.nextSibling;_aspxSetElementDisplay(headerTR.nextSibling.nextSibling,false);}
if(this.groupContentPaddingBottom!=0)
_aspxSetElementDisplay(categoryContentElem.nextSibling,false);if(this.showBackToTop){if(this.groupContentPaddingBottom!=0)
_aspxSetElementDisplay(categoryContentElem.nextSibling.nextSibling,false);else
_aspxSetElementDisplay(categoryContentElem.nextSibling,false);}},ShowEmptyResultCaption:function(){var elem=this.GetEmptyResultCaptionElement();if(this.rowCount>0&&(this.mainCellWidth>0))
elem.style.width=this.mainCellWidth+"px";_aspxSetElementDisplay(elem,true);},HideEmptyResultCaption:function(){var elem=this.GetEmptyResultCaptionElement();_aspxSetElementDisplay(elem,false);},ShowGroup:function(nodeElement){if(!_aspxGetElementDisplay(nodeElement))
_aspxSetElementDisplay(nodeElement,true);},HideGroup:function(nodeElement){_aspxSetElementDisplay(nodeElement,false);},SetColumnSeparatorDisplay:function(columnElem,value,columnIndex,rowIndex){if(columnIndex!=this.columnCount-1)
this.SetRightColumnSeparatorDisplay(columnElem,value);else{var prevColumn=this.GetColumnElement(columnIndex-1,rowIndex);if((prevColumn!=null)&&(_aspxGetElementDisplay(prevColumn))){this.SetLeftColumnSeparatorDisplay(columnElem,value);}}},SetLeftColumnSeparatorDisplay:function(columnElem,value){var curElem=columnElem.previousSibling;while((curElem!=null)&&(curElem.id=="")){_aspxSetElementVisibility(curElem,value);curElem=curElem.previousSibling;}},SetRightColumnSeparatorDisplay:function(columnElem,value){var curElem=columnElem.nextSibling;while((curElem!=null)&&(curElem.id=="")){_aspxSetElementVisibility(curElem,value);curElem=curElem.nextSibling;}},OnFilterInputBlur:function(evt){this.ClearPasteTimer();},OnFilterInputChange:function(evt){if(this.GetFilterInputElement().value!=""){if(this.IsFilterTimerActive())
this.ClearFilterTimer();this.DoFilter(this.GetFilterInputElement().value);}},OnFilterInputFocus:function(){this.SetPasteTimer();},OnFilterInputKeyUp:function(evt){if(this.IsAllowableKeyCode(evt.keyCode)){if(this.IsFilterTimerActive())
this.ClearFilterTimer();this.SetFilterTimer(this.GetFilterInputElement(),this.filterDelay);}},OnFilterInputKeyPress:function(evt){if(evt.keyCode==ASPxKey.Enter)
return false;}});ASPxClientTitleIndexItemEventArgs=_aspxCreateClass(ASPxClientProcessingModeEventArgs,{constructor:function(processOnServer,name,htmlElement,htmlEvent){this.constructor.prototype.constructor.call(this,processOnServer);this.name=name;this.htmlElement=htmlElement;this.htmlEvent=htmlEvent;}});function aspxSIFBlur(name){var si=aspxGetControlCollection().Get(name);if(si!=null)si.OnFilterInputBlur();return true;}
function aspxSIFChange(evt,name){var si=aspxGetControlCollection().Get(name);if(si!=null)si.OnFilterInputChange(evt);return true;}
function aspxSIFFocus(name){var si=aspxGetControlCollection().Get(name);if(si!=null)si.OnFilterInputFocus();return true;}
function aspxSIFKeyUp(evt,name){var si=aspxGetControlCollection().Get(name);if(si!=null)si.OnFilterInputKeyUp(evt);return true;}
function aspxSIFKeyPress(evt,name){var si=aspxGetControlCollection().Get(name);if(si!=null)return si.OnFilterInputKeyPress(evt);return true;}
function aspxSFilterTimer(name){var si=aspxGetControlCollection().Get(name);if(si!=null){si.DoFilter(si.GetFilterInputElement().value);si.ClearFilterTimer();}}
function aspxSPasteTimer(name){var si=aspxGetControlCollection().Get(name);if(si!=null)si.DoFilterInternal();}
function aspxIPItemClick(name,value){var ti=aspxGetControlCollection().Get(name);if(ti!=null)ti.DoIndexPanelItemClick(value);}
ASPxClientTimer=_aspxCreateClass(ASPxClientControl,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.interval=60000;this.clientEnabled=true;this.timerID=-1;this.Tick=new ASPxClientEvent();},Initialize:function(){if(this.clientEnabled)
this.Start();this.constructor.prototype.Initialize.call(this);},GetStateInputElement:function(index){return _aspxGetElementById(this.name+"S");},Start:function(){this.Stop();this.timerID=_aspxSetInterval("aspxTTick(\""+this.name+"\")",this.interval);},Stop:function(){if(this.timerID==-1)return;this.timerID=_aspxClearInterval(this.timerID);},DoTick:function(){var processOnServer=this.RaiseTick();if(processOnServer)
this.SendPostBack("TICK");},GetStateString:function(){return(this.clientEnabled?"1":"0")+";"+this.interval;},UpdateState:function(){var element=this.GetStateInputElement();if(element!=null)
element.value=this.GetStateString();},RaiseTick:function(){var processOnServer=this.IsServerEventAssigned("Tick");if(!this.Tick.IsEmpty()){var args=new ASPxClientProcessingModeEventArgs(processOnServer);this.Tick.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;},GetEnabled:function(){return this.clientEnabled;},SetEnabled:function(enabled){if(enabled==this.clientEnabled)return;if(enabled)
this.Start();else
this.Stop();this.clientEnabled=enabled;this.UpdateState();},GetInterval:function(){return this.interval;},SetInterval:function(interval){if(interval<1)return;this.interval=interval;if(this.clientEnabled){this.Stop();this.Start();}
this.UpdateState();}});function aspxTTick(name){var timer=aspxGetControlCollection().Get(name);if(timer!=null)timer.DoTick();}
ASPxClientDataView=_aspxCreateClass(ASPxClientControl,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.allowMultipleCallbacks=false;},GetPageIndexInputElement:function(){return _aspxGetElementById(this.name+"PI");},GetContentCell:function(){return this.GetChild("_CCell");},GetItemsCell:function(){return this.GetChild("_ICell");},DoPagerClick:function(value){var inputElement=this.GetPageIndexInputElement();if(inputElement!=null)
this.CreateCallback(inputElement.value+__aspxCallbackSeparator+value,"PAGERCLICK");},CustomCallback:function(args){if(!_aspxIsExists(this.callBack)){if(this.isInitialized)
this.SendPostBack(args);return;}
this.CreateCallback(args,"CUSTOMCALLBACK");},OnCallback:function(result){var inputElement=this.GetPageIndexInputElement();if(inputElement!=null)
inputElement.value=result.index;var element=this.GetContentCell();if(element!=null)
element.innerHTML=result.html;},DoBeginCallback:function(command){this.CreateLoadingPanelWithAbsolutePosition(this.GetItemsCell());ASPxClientControl.prototype.DoBeginCallback.call(this,command);},PerformCallback:function(parameter){this.CustomCallback(parameter);}});function aspxDVPagerClick(name,value){var dv=aspxGetControlCollection().Get(name);if(dv!=null)dv.DoPagerClick(value);}
ASPxClientCloudControl=_aspxCreateClass(ASPxClientControl,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.ItemClick=new ASPxClientEvent();},RaiseItemClick:function(itemElement,htmlEvent){var processOnServer=this.autoPostBack||this.IsServerEventAssigned("ItemClick");if(!this.ItemClick.IsEmpty()){var name=this.GetItemElementName(itemElement);var args=new ASPxClientCloudControlItemEventArgs(processOnServer,name,itemElement,htmlEvent);this.ItemClick.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;},OnControlClick:function(clickedElement,htmlEvent){var itemElement=_aspxGetParentByClassName(clickedElement,__aspxItemClassName);if(_aspxIsExists(itemElement)){var processOnServer=this.RaiseItemClick(itemElement,htmlEvent);var hasItemLink=this.GetLinkElement(itemElement)!=null;if(processOnServer&&!hasItemLink){var name=this.GetItemElementName(itemElement);this.SendPostBack("CLICK:"+name);}}}});ASPxClientCloudControlItemEventArgs=_aspxCreateClass(ASPxClientProcessingModeEventArgs,{constructor:function(processOnServer,name,htmlElement,htmlEvent){this.constructor.prototype.constructor.call(this,processOnServer);this.name=name;this.htmlElement=htmlElement;this.htmlEvent=htmlEvent;}});ASPxClientNewsControl=_aspxCreateClass(ASPxClientDataView,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.TailClick=new ASPxClientEvent();},DoTailClick:function(itemName,evt){var clickedElement=_aspxGetEventSource(evt);this.OnTailClick(clickedElement,itemName,evt);},OnTailClick:function(clickedElement,itemName,htmlEvent){var itemElement=clickedElement;if(_aspxIsExists(itemElement)){var processOnServer=this.RaiseTailClick(itemElement,itemName,htmlEvent);var hasItemLink=this.GetLinkElement(itemElement)!=null;if(processOnServer&&!hasItemLink){this.SendPostBack("CLICK:"+itemName);}}},RaiseTailClick:function(tailElement,itemName,htmlEvent){var processOnServer=this.autoPostBack||this.IsServerEventAssigned("TailClick");if(!this.TailClick.IsEmpty()){var args=new ASPxClientNewsControlItemEventArgs(processOnServer,itemName,tailElement,htmlEvent);this.TailClick.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;}});ASPxClientNewsControlItemEventArgs=_aspxCreateClass(ASPxClientProcessingModeEventArgs,{constructor:function(processOnServer,name,htmlElement,htmlEvent){this.constructor.prototype.constructor.call(this,processOnServer);this.name=name;this.htmlElement=htmlElement;this.htmlEvent=htmlEvent;}});function aspxHLTClick(evt,name,itemName){var control=aspxGetControlCollection().Get(name);if(control!=null)control.DoTailClick(itemName,evt);}
ASPxRelatedControlManager={storage:{},GetRelatedCollection:function(masterName){if(!_aspxIsExists(this.storage[masterName]))
this.storage[masterName]=[];return this.storage[masterName];},RegisterRelatedControl:function(masterName,name){this.GetRelatedCollection(masterName)[name]=name;},RegisterRelatedControls:function(masterName,names){var relatedCollection=this.GetRelatedCollection(masterName);var name;for(var i=0;i<names.length;i++){name=names[i];relatedCollection[name]=name;}},GetLinkedControls:function(masterControl){var result=[masterControl];for(var name in this.GetRelatedCollection(masterControl.name)){var control=aspxGetControlCollection().Get(name);if(_aspxIsExists(control))
result.push(control);}
return result;},coverCache:{},panelCache:{},timers:{},Shade:function(masterControl){this.ShadeCore(masterControl,true);var name=masterControl.name;this.timers[name]=_aspxSetTimeout("ASPxRelatedControlManager.ShadeTransition('"+name+"')",750);},ShadeCore:function(masterControl,isTransparent){if(!isTransparent){var panel=masterControl.CreateLoadingPanelWithAbsolutePosition(document.body,masterControl.GetMainElement());this.panelCache[masterControl.name]=panel;}
var controls=this.GetLinkedControls(masterControl);for(var i=0;i<controls.length;i++){var control=controls[i];var cover=control.CreateLoadingDiv(document.body,control.GetMainElement());if(_aspxIsExistsElement(cover)){if(isTransparent){cover.className="";cover.style.background="white";if(__aspxIE)
cover.style.filter="alpha(opacity=1)";else
cover.style.opacity="0.01";}
this.coverCache[control.name]=cover;}}},ShadeTransition:function(masterName){var obj=aspxGetControlCollection().Get(masterName);if(_aspxIsExists(obj)){this.Unshade(obj);this.ShadeCore(obj,false);}},Unshade:function(masterControl){var masterName=masterControl.name;_aspxClearTimer(this.timers[masterName]);delete this.timers[masterName];var panel=this.panelCache[masterName];if(_aspxIsExistsElement(panel))
_aspxRemoveElement(panel);delete this.panelCache[masterName];var controls=this.GetLinkedControls(masterControl);for(var i=0;i<controls.length;i++){var control=controls[i];var cover=this.coverCache[control.name];if(_aspxIsExistsElement(cover))
_aspxRemoveElement(cover);delete this.coverCache[control.name];}},CreateInfo:function(){return{clientObjectName:"",elementId:"",innerHtml:"",parameters:""};},ProcessInfo:function(info){var control=aspxGetControlCollection().Get(info.clientObjectName);if(!_aspxIsExists(control)||!_aspxIsFunction(control.ProcessCallbackResult))
this.ProcessCallbackResultDefault(info.elementId,info.innerHtml,info.parameters);else
control.ProcessCallbackResult(info.elementId,info.innerHtml,info.parameters);},ProcessCallbackResultDefault:function(elementId,innerHtml,parameters){var element=_aspxGetElementById(elementId);if(_aspxIsExistsElement(element))
element.innerHTML=innerHtml;},ParseResult:function(result){var prevIndex=0;var index;var lens;var info;while(true){var remm=result.substring(prevIndex);index=result.indexOf("|",prevIndex);if(index<0)
break;lens=result.substring(prevIndex,index).split(",");prevIndex=index+1;info=this.CreateInfo();info.clientObjectName=result.substr(prevIndex,lens[0]);prevIndex+=parseInt(lens[0]);info.elementId=result.substr(prevIndex,lens[1]);prevIndex+=parseInt(lens[1]);info.innerHtml=result.substr(prevIndex,lens[2]);prevIndex+=parseInt(lens[2]);info.parameters=result.substr(prevIndex,lens[3]);prevIndex+=parseInt(lens[3]);this.ProcessInfo(info);}}};function _aspxPGNav(evt){var element=_aspxGetEventSource(evt);if(element!=null){if(element.tagName!="A"){var linkElement=_aspxGetChildByTagName(element,"A",0);if(linkElement!=null)
_aspxNavigateUrl(linkElement.href,linkElement.target);}}
if(!__aspxNS)
evt.cancelBubble=true;}
ASPxClientCallbackPanel=_aspxCreateClass(ASPxClientControl,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.allowMultipleCallbacks=false;},GetContentElement:function(){var element=this.GetMainElement();return element.tagName=="TABLE"?element.rows[0].cells[0]:element;},OnCallback:function(result){_aspxSetInnerHtml(this.GetContentElement(),result);},DoBeginCallback:function(command){ASPxClientControl.prototype.DoBeginCallback.call(this,command);this.CreateLoadingPanel();},CreateLoadingPanel:function(){var element=this.GetContentElement();var mainElement=(element.tagName=="TD")?this.GetMainElement():element;var elementWidth=mainElement.style.width;var elementHeight=mainElement.style.height;var div=this.CreateLoadingDiv(element);if(div==null)
element.innerHTML="";if(div!=null){this.CreateLoadingPanelWithAbsolutePosition(element,mainElement);}else{if(elementWidth!=""&&elementHeight!="")
this.CreateLoadingPanelWithAbsolutePosition(element,mainElement);else
this.CreateLoadingPanelInsideContainer(element);}},PerformCallback:function(parameter){this.CreateCallback(parameter);}});ASPxClientUploadControlIDSuffix={FlagHiddenInput:"_dxeUpload",ErrorRow:"_ErrR_",ErrorRowTemplate:"_ErrR_RT",UploadIFrame:"_UploadIframe",FileInput:"_Input_",FileInputTemplate:"_Input_T",AddUploadButtonsSeparator:"_AddUploadR",AddUploadButtonsPanelRow:"_AddUploadPanelR",InputCountHidden:"_IC",AddButtonTextCell:"_Add",RemoveButtonTextCell:"_Remove",UploadButtonTextCell:"_Upload"};var __aspxErrorTextResponsePrefix="DXER:";var __aspxRemoveButtonCellClassName="dxRB";var __aspxSampleValue="DxFile";ASPxClientUploadControl=_aspxCreateClass(ASPxClientControl,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.generalErrorText="";this.invalidWindowsPathErrorText="";this.fileInputSpacing="";this.isInCallback=false;this.FileUploadComplete=new ASPxClientEvent();this.FilesUploadComplete=new ASPxClientEvent();this.FileUploadStart=new ASPxClientEvent();this.TextChanged=new ASPxClientEvent();this.FileInputCountChanged=new ASPxClientEvent();},Initialize:function(){ASPxClientControl.prototype.Initialize.call(this);this.CreateClearFileInput();if(__aspxOpera&&!_aspxIsExists(frames[this.GetFakeIframeName()]))
this.ReinitializeIFrame(this.GetFakeIframe());_aspxAttachEventToElement(__aspxIE?this.GetFakeIframeElement():this.GetFakeIframe(),"load",new Function("aspxFakeUploadIframeOnLoad('"+this.name+"');"));this.InitializeForm();this.InitializeTemplates();},InitializeTemplates:function(){this.fileInputRowTemplateNode=this.GetFileInputRowTemplate().cloneNode(true);this.errorRowTemplateNode=this.GetErrorRowTemplate().cloneNode(true);this.fileInputSeparatorTemplateNode=this.GetFileInputSeparatorRowTemplate().cloneNode(true);_aspxSetElementDisplay(this.fileInputRowTemplateNode,true);_aspxSetElementDisplay(this.fileInputSeparatorTemplateNode,true);},InitializeForm:function(){var form=_aspxGetParentByTagName(this.GetMainElement(),"FORM");form.enctype=form.encoding="multipart/form-data";},ReinitializeIFrame:function(iframe){var divElem=document.createElement("DIV");_aspxSetElementDisplay(divElem,false);document.body.appendChild(divElem);divElem.appendChild(iframe);divElem.appendChild(iframe);},CreateClearFileInput:function(){this.clearFileInputTempalteHtml=_aspxGetChildByTagName(this.GetFileInputRowTemplate(),"TD",0).innerHTML;},GetFileInputCountInternal:function(){var element=this.GetInputCountHiddenField();return parseInt(element.value,10);},SetFileInputCountInternal:function(value){this.GetInputCountHiddenField().value=value;},GetInputCountHiddenField:function(){if(!_aspxIsExists(this.inputCountHiddenField)){var id=this.name+ASPxClientUploadControlIDSuffix.InputCountHidden;this.inputCountHiddenField=_aspxGetElementById(id);}
return this.inputCountHiddenField;},GetErrorRow:function(index){return this.GetChild(ASPxClientUploadControlIDSuffix.ErrorRow+index);},GetErrorCell:function(index){return _aspxGetElementsByTagName(this.GetErrorRow(index),"td")[0];},GetErrorRowTemplate:function(){return this.GetChild(ASPxClientUploadControlIDSuffix.ErrorRowTemplate);},GetFakeIframe:function(){var name=this.GetFakeIframeName();return __aspxIE?frames[name]:_aspxGetElementById(name);},GetFakeIframeName:function(){return this.name+ASPxClientUploadControlIDSuffix.UploadIFrame;},GetFakeIframeElement:function(){return this.GetFakeIframe().frameElement;},GetFakeIframeDocument:function(){return __aspxIE?this.GetFakeIframe().document:this.GetFakeIframe().contentDocument;},GetFakeIframeResponseString:function(){return this.GetFakeIframeDocument().body.innerHTML;},GetFileInputElement:function(index){return this.GetChild(ASPxClientUploadControlIDSuffix.FileInput+index);},GetFileInputRow:function(index){return _aspxGetParentByTagName(this.GetFileInputElement(index),"TR");},GetFileInputRowTemplate:function(){var inputTemplate=this.GetChild(ASPxClientUploadControlIDSuffix.FileInputTemplate);return _aspxGetParentByTagName(inputTemplate,"TR");},GetFileInputsTBody:function(){if(!_aspxIsExists(this.tbody))
this.tbody=_aspxGetParentByTagName(this.GetFileInputRowTemplate(),"TBODY");return this.tbody;},GetRemoveButtonCell:function(index){return this.GetRemoveButtonCellByInput(this.GetFileInputElement(index));},GetRemoveButtonCellByInput:function(input){return _aspxGetChildsByClassName(_aspxGetParentByTagName(input,"TR"),__aspxRemoveButtonCellClassName)[0];},GetAddUploadButtonsSeparatorRow:function(){return this.GetChild(ASPxClientUploadControlIDSuffix.AddUploadButtonsSeparator);},GetAddUploadButtonsPanelRow:function(){return this.GetChild(ASPxClientUploadControlIDSuffix.AddUploadButtonsPanelRow);},GetFileInputSeparatorRow:function(index){if(this.fileInputSpacing==""||this.GetFileInputCountInternal()==1)
return null;if(!_aspxIsExists(index))
index=0;var ret=null;var firstErrorRow=this.GetErrorRow(index);if(_aspxIsExists(firstErrorRow)){var parent=firstErrorRow.parentNode;var rowIndex=_aspxArrayIndexOf(parent.childNodes,firstErrorRow);var element=parent.childNodes[rowIndex+1];if(!_aspxIsExists(element.id)||(element.id==""))
ret=parent.childNodes[rowIndex+1];}
return ret;},GetFileInputSeparatorRowTemplate:function(){if(this.fileInputSpacing=="")
return null;var errRowTemplate=this.GetErrorRowTemplate();var parent=errRowTemplate.parentNode;var errRowIndex=_aspxArrayIndexOf(parent.childNodes,errRowTemplate);return parent.childNodes[errRowIndex+1];},GetIsResponseValid:function(){var ret=false;try{this.GetFakeIframeResponseString();ret=true;}
catch(e){}
return ret;},GetValue:function(index){return this.GetFileInputElement(index).value;},SetEnabledInternal:function(enabled){for(var i=0;i<this.GetFileInputCountInternal();i++)
this.GetFileInputElement(i).disabled=!enabled;},AddFileInput:function(){var tBody=this.GetFileInputsTBody();var addUploadButtonsElement=this.GetAddUploadButtonsSeparatorRow();if(addUploadButtonsElement==null)
addUploadButtonsElement=this.GetAddUploadButtonsPanelRow();if(this.fileInputSpacing!=""&&this.GetFileInputCountInternal()!=0){var separatorRow=this.fileInputSeparatorTemplateNode.cloneNode(true);tBody.insertBefore(separatorRow,addUploadButtonsElement);}
tBody.insertBefore(this.CreateFileInputRow(this.GetFileInputCountInternal()),addUploadButtonsElement);tBody.insertBefore(this.CreateErrorRow(this.GetFileInputCountInternal()),addUploadButtonsElement);this.SetFileInputCountInternal(this.GetFileInputCountInternal()+1);var element=this.GetAddUploadButtonsSeparatorRow();if(_aspxIsExists(element)&&this.GetFileInputCountInternal()>0&&!_aspxGetElementDisplay(element))
_aspxSetElementDisplay(element,true);this.RaiseFileInputCountChanged();},RemoveFileInput:function(index){var tBody=this.GetFileInputsTBody();_aspxRemoveElement(this.GetFileInputSeparatorRow((index==0)?index:index-1));_aspxRemoveElement(this.GetFileInputRow(index));_aspxRemoveElement(this.GetErrorRow(index));this.RedefineAttributtes(index+1);this.SetFileInputCountInternal(this.GetFileInputCountInternal()-1);var element=this.GetAddUploadButtonsSeparatorRow();if(_aspxIsExists(element)&&this.GetFileInputCountInternal()==0&&_aspxGetElementDisplay(element))
_aspxSetElementDisplay(element,false);this.RaiseFileInputCountChanged();},RedefineAttributtes:function(startIndex){var tBody=this.GetFileInputsTBody();for(var index=startIndex;index<this.GetFileInputCountInternal();index++){var newIndex=index-1;var fileInput=this.GetFileInputElement(index);var removeButton=this.GetRemoveButtonCell(index);var errorRow=this.GetErrorRow(index);this.RedefineInputAttributes(fileInput,newIndex);if(_aspxIsExists(removeButton))
removeButton.onclick=new Function("aspxURemoveFileInputClick('"+this.name+"',"+newIndex+");");errorRow.id=this.name+ASPxClientUploadControlIDSuffix.ErrorRow+newIndex;}},RedefineInputAttributes:function(inputElement,index){inputElement.id=this.name+ASPxClientUploadControlIDSuffix.FileInput+index;inputElement.name=inputElement.id;inputElement.onchange=new Function("aspxUTextChanged('"+this.name+"',"+index+");");},GetAddButtonTextCell:function(){return this.GetChild(ASPxClientUploadControlIDSuffix.AddButtonTextCell);},GetUploadButtonTextCell:function(){return this.GetChild(ASPxClientUploadControlIDSuffix.UploadButtonTextCell);},SetAddButtonTextInternal:function(text){var cell=this.GetAddButtonTextCell();if(_aspxIsExists(cell))
cell.innerHTML=text;},SetUploadButtonTextInternal:function(text){var cell=this.GetUploadButtonTextCell();if(_aspxIsExists(cell))
cell.innerHTML=text;},GetAddButtonTextInternal:function(){var cell=this.GetAddButtonTextCell();if(_aspxIsExists(cell))
return cell.innerHTML;return null;},GetUploadButtonTextInternal:function(){var cell=this.GetUploadButtonTextCell();if(_aspxIsExists(cell))
return cell.innerHTML;return null;},CreateFileInputRow:function(index){var row=this.fileInputRowTemplateNode.cloneNode(true);var fileInput=_aspxGetChildByTagName(row,"INPUT",0);fileInput.id=this.name+ASPxClientUploadControlIDSuffix.FileInput+index;fileInput.name=fileInput.id;if(_aspxIsExists(fileInput.onchange))
fileInput.onchange=new Function("aspxUTextChanged('"+this.name+"',"+index+");");var removeButton=this.GetRemoveButtonCellByInput(fileInput);if(_aspxIsExists(removeButton))
removeButton.onclick=new Function("aspxURemoveFileInputClick('"+this.name+"',"+index+");");return row;},CreateErrorRow:function(index){var row=this.errorRowTemplateNode.cloneNode(true);row.id=this.name+ASPxClientUploadControlIDSuffix.ErrorRow+index;return row;},UploadFileFromUser:function(){if(!this.isInCallback&&!this.AreEmptyInputs()){if((__aspxIE&&!this.ValidateWindowsFileNames())||this.OnStartFileUpload())return;var form=_aspxGetParentByTagName(this.GetMainElement(),"form");var tempTarget=form.target;this.AddFlagHiddenInput(form);var isInternalErrorOccured=false;form.target=this.GetFakeIframe().name;try{form.submit();}
catch(e){isInternalErrorOccured=true;this.WriteResponseString(__aspxErrorTextResponsePrefix+this.generalErrorText);this.OnCompleteFileUpload();}
form.target=tempTarget;if(!isInternalErrorOccured)
this.SetEnabledInternal(false);this.DeleteFlagHiddenInput();}},AddFlagHiddenInput:function(form){var id=this.name+ASPxClientUploadControlIDSuffix.FlagHiddenInput;this.hiddenInputElement=this.CreateHiddenInputElement(id,id,__aspxSampleValue);form.appendChild(this.hiddenInputElement);},AreEmptyInputs:function(){for(var i=0;i<this.GetFileInputCountInternal();i++)
if(this.GetText(i)!="")return false;return true;},ClearInputText:function(){for(var i=0;i<this.GetFileInputCountInternal();i++){if(_aspxIsExistsElement(this.GetFileInputElement(i))){var parentNode=_aspxGetParentByTagName(this.GetFileInputElement(i),"TD");parentNode.removeChild(this.GetFileInputElement(i));parentNode.innerHTML=this.clearFileInputTempalteHtml;this.RedefineInputAttributes(_aspxGetChildByTagName(parentNode,"INPUT",0),i);}}},CreateHiddenInputElement:function(id,name,value){var ret=document.createElement('input');ret.type="hidden";ret.name=name;ret.id=id;ret.value=value;return ret;},DeleteFlagHiddenInput:function(){_aspxRemoveElement(this.hiddenInputElement);},ValidateWindowsFileNames:function(){for(var i=0;i<this.GetFileInputCountInternal();i++){var windowsRootDirectoryNameRegExp=/[a-zA-Z]\:/gi;var windowsFileNameRegExp=/^([a-zA-Z]\:|\\\\[^\/\\:*?\"<>|]+\\[^\/\\:*?\"<>|]+)(\\[^\/\\:*?\"<>|]+)+(\.[^\/\\:*?\"<>|]+)?$/gi;var fileName=_aspxTrim(this.GetText(i));if((fileName!=""&&!windowsFileNameRegExp.test(fileName))&&!(fileName.length==3&&windowsRootDirectoryNameRegExp.test(fileName))){alert(this.invalidWindowsPathErrorText.replace("{0}",this.GetText(i)));return false;}}
return true;},ProcessResponse:function(){try{return eval(this.GetFakeIframeResponseString());}
catch(e){}
return null;},UpdateErrorMessageCell:function(index,responseObj){if(_aspxIsExists(this.GetErrorRow(index))){var errCell=this.GetErrorCell(index);_aspxSetElementDisplay(this.GetErrorRow(index),!responseObj.isValidArray[index]);if(responseObj.errorTexts[index]!="")
errCell.innerHTML=responseObj.errorTexts[index];}},WriteResponseString:function(responseString){try{this.GetFakeIframeDocument().body.innerHTML=responseString;}
catch(e){}},OnCompleteFileUpload:function(){if(this.GetIsResponseValid()){var responseObj=this.ProcessResponse();for(var i=0;i<this.GetFileInputCountInternal();i++){this.UpdateErrorMessageCell(i,responseObj);if(this.GetText(i)!="")
this.RaiseFileUploadComplete(i,responseObj);}
this.RaiseFilesUploadComplete();}
this.isInCallback=false;this.ClearInputText();this.responseHashTable={};this.SetEnabledInternal(true);if(__aspxIE){try{this.GetFakeIframeDocument().write("");this.GetFakeIframeDocument().close();}
catch(e){}}},OnTextChanged:function(index){this.RaiseTextChanged(index);},OnStartFileUpload:function(){var isCancel=this.RaiseFileUploadStart();if(!isCancel)
this.isInCallback=true;return isCancel;},RaiseTextChanged:function(index){if(!this.TextChanged.IsEmpty()){var args=new ASPxClientUploadControlTextChangedEventArgs(index);this.TextChanged.FireEvent(this,args);}},RaiseFileUploadComplete:function(index,responseObj){if(!this.FileUploadComplete.IsEmpty()){var args=new ASPxClientUploadControlFileUploadCompleteEventArgs(index,responseObj.isValidArray[index],responseObj.errorTexts[index],responseObj.callbackDataArray[index]);this.FileUploadComplete.FireEvent(this,args);}},RaiseFilesUploadComplete:function(){var args=new ASPxClientEventArgs();this.FilesUploadComplete.FireEvent(this,args);},RaiseFileUploadStart:function(){var ret=false;if(!this.FileUploadStart.IsEmpty()){var args=new ASPxClientUploadControlFileUploadStartEventArgs(false);this.FileUploadStart.FireEvent(this,args);ret=args.cancel;}
return ret;},RaiseFileInputCountChanged:function(){if(!this.FileInputCountChanged.IsEmpty()){var args=new ASPxClientEventArgs();this.FileInputCountChanged.FireEvent(this,args);}},ClearText:function(){this.ClearInputText();},GetText:function(index){if(!_aspxIsExists(index))
index=0;var value=this.GetValue(index);return value!=null?value:"";},UploadFile:function(){this.UploadFileFromUser();},Upload:function(){this.UploadFileFromUser();},GetFileInputCount:function(){return this.GetFileInputCountInternal();},SetAddButtonText:function(text){this.SetAddButtonTextInternal(text);},SetUploadButtonText:function(text){this.SetUploadButtonTextInternal(text);},GetAddButtonText:function(){return this.GetAddButtonTextInternal();},GetUploadButtonText:function(){return this.GetUploadButtonTextInternal();}});ASPxClientUploadControlFileUploadStartEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(cancel){this.constructor.prototype.constructor.call(this);this.cancel=cancel;}});ASPxClientUploadControlFileUploadCompleteEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(inputIndex,isValid,errorText,callbackData){this.constructor.prototype.constructor.call(this);this.inputIndex=inputIndex;this.isValid=isValid;this.errorText=errorText;this.callbackData=callbackData;}});ASPxClientUploadControlTextChangedEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(inputIndex){this.constructor.prototype.constructor.call(this);this.inputIndex=inputIndex;}});function aspxUTextChanged(name,index){var uploader=aspxGetControlCollection().Get(name);if(uploader!=null)
uploader.OnTextChanged(index);}
function aspxUAddFileInputClick(name){var uploader=aspxGetControlCollection().Get(name);if(uploader!=null)
uploader.AddFileInput();}
function aspxURemoveFileInputClick(name,index){var uploader=aspxGetControlCollection().Get(name);if(uploader!=null)
uploader.RemoveFileInput(index);}
function aspxUUploadFileClick(name){var uploader=aspxGetControlCollection().Get(name);if(uploader!=null)
uploader.UploadFile();}
function aspxFakeUploadIframeOnLoad(name){var uploader=aspxGetControlCollection().Get(name);if((uploader!=null)&&uploader.isInCallback)
uploader.OnCompleteFileUpload();}
ASPxClientPanel=_aspxCreateClass(ASPxClientControl,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);},GetContentElement:function(){return this.GetMainElement();},GetContentHTML:function(){return this.GetContentHtml();},SetContentHTML:function(html){this.SetContentHtml(html);},GetContentHtml:function(){var contentElement=this.GetContentElement();return _aspxIsExistsElement(contentElement)?contentElement.innerHTML:null;},SetContentHtml:function(html){var contentElement=this.GetContentElement();if(_aspxIsExistsElement(contentElement))
contentElement.innerHTML=html;}});var __aspxRPHeaderTextContainerIDSuffix="_RPHT";var __aspxRPContentElementIDSuffix="_RPC";var __aspxRPGroupBoxCaptionIDSuffix="_GBC";var ASPxClientRoundPanel=_aspxCreateClass(ASPxClientPanel,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.headerTextContainer=null;this.headerTextEmpty=false;this.contentElement=null;this.isGroupBox=false;},GetContentElement:function(){if(this.contentElement==null)
this.contentElement=this.GetChild(__aspxRPContentElementIDSuffix);return this.contentElement;},GetGroupBoxCaptionElement:function(){if(this.groupBoxCaptionElement==null)
this.groupBoxCaptionElement=this.GetChild(__aspxRPGroupBoxCaptionIDSuffix);return this.groupBoxCaptionElement;},GetHeaderTextContainer:function(){if(this.headerTextContainer==null)
this.headerTextContainer=document.getElementById(this.name+__aspxRPHeaderTextContainerIDSuffix);return this.headerTextContainer;},GetHeaderText:function(){return!this.headerTextEmpty?this.GetHeaderTextInternal():"";},SetHeaderText:function(text){var textContainer=this.GetHeaderTextContainer();if(_aspxIsExistsElement(textContainer)){if(_aspxIsExists(text)&&_aspxTrim(text)==""){this.headerTextEmpty=true;textContainer.innerHTML="&nbsp;";}else{this.headerTextEmpty=false;textContainer.innerHTML=_aspxIsExists(text)?text:"";}}},GetHeaderTextInternal:function(){var textContainer=this.GetHeaderTextContainer();return _aspxIsExistsElement(textContainer)?textContainer.innerHTML:null;},GetContentHtml:function(){var contentElement=this.GetContentElement();if(_aspxIsExistsElement(contentElement)){if(this.isGroupBox)
var caption=this.RemoveGroupBoxCaptionElement();var contentHTML=contentElement.innerHTML;if(this.isGroupBox)
this.RestoreGroupBoxCaptionElement(caption);return contentHTML;}
return null;},SetContentHtml:function(html){var contentElement=this.GetContentElement();if(_aspxIsExistsElement(contentElement)){if(this.isGroupBox)
var caption=this.RemoveGroupBoxCaptionElement();contentElement.innerHTML=html;if(this.isGroupBox)
this.RestoreGroupBoxCaptionElement(caption);}},RemoveGroupBoxCaptionElement:function(){var captionElement=this.GetGroupBoxCaptionElement();return(_aspxIsExists(captionElement))?captionElement.parentNode.removeChild(captionElement):null;},RestoreGroupBoxCaptionElement:function(captionElement){var contentElement=this.GetContentElement();if(_aspxIsExists(contentElement)){if(contentElement.hasChildNodes())
contentElement.insertBefore(captionElement,contentElement.firstChild);else
contentElement.appendChild(captionElement);}}});var _aspxGlobalEvents=null;ASPxClientGlobalEvents=_aspxCreateClass(null,{constructor:function(){this.ControlsInitialized=new ASPxClientEvent();this.BeginCallback=new ASPxClientEvent();this.EndCallback=new ASPxClientEvent();this.CallbackError=new ASPxClientEvent();this.ValidationCompleted=new ASPxClientEvent();var collection=aspxGetControlCollection();collection.ControlsInitialized.AddHandler(aspxGEControlsInitialized);},OnControlsInitialized:function(){this.ControlsInitialized.FireEvent(this,new ASPxClientEventArgs());},OnBeginCallback:function(sender,command){var e=new ASPxClientBeginCallbackEventArgs(command);this.BeginCallback.FireEvent(sender,e);},OnEndCallback:function(sender){var e=new ASPxClientEndCallbackEventArgs();this.EndCallback.FireEvent(sender,e);},OnCallbackError:function(sender,e){this.CallbackError.FireEvent(sender,e);return e.handled;},OnValidationCompleted:function(container,validationGroup,invisibleControlsValidated,isValid,firstInvalidControl,firstVisibleInvalidControl){var e=new ASPxClientValidationCompletedEventArgs(container,validationGroup,invisibleControlsValidated,isValid,firstInvalidControl,firstVisibleInvalidControl);this.ValidationCompleted.FireEvent(null,e);return e.isValid;}});function aspxGetGlobalEvents(){if(_aspxGlobalEvents==null)
_aspxGlobalEvents=new ASPxClientGlobalEvents();return _aspxGlobalEvents;}
function aspxGEControlsInitialized(s,e){aspxGetGlobalEvents().OnControlsInitialized();}
ASPxClientValidationCompletedEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(container,validationGroup,invisibleControlsValidated,isValid,firstInvalidControl,firstVisibleInvalidControl){this.constructor.prototype.constructor.call();this.container=container;this.validationGroup=validationGroup;this.invisibleControlsValidated=invisibleControlsValidated;this.isValid=isValid;this.firstInvalidControl=firstInvalidControl;this.firstVisibleInvalidControl=firstVisibleInvalidControl;}});ASPxClientLoadingPanel=_aspxCreateClass(ASPxClientControl,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.containerElementID="";this.containerElement=null;this.horizontalOffset=0;this.verticalOffset=0;},Initialize:function(){if(this.containerElementID!="")
this.containerElement=_aspxGetElementById(this.containerElementID);this.constructor.prototype.Initialize.call(this);},ShowInternal:function(offsetElement,x,y){if(offsetElement==null)
offsetElement=this.containerElement;if(offsetElement==null)
offsetElement=document.body;var element=this.GetMainElement();_aspxSetElementDisplay(element,true);this.SetLoadingPanelLocation(offsetElement,element,x,y,this.horizontalOffset,this.verticalOffset);element=this.GetLoadingDiv();if(element!=null){_aspxSetElementDisplay(element,true);this.SetLoadingDivBounds(offsetElement,element);}},Show:function(){this.ShowInternal(null);},ShowInElement:function(htmlElement){if(_aspxIsExists(htmlElement))
this.ShowInternal(htmlElement);},ShowInElementByID:function(id){var htmlElement=_aspxGetElementById(id);this.ShowInElement(htmlElement);},ShowAtPos:function(x,y){this.ShowInternal(null,x,y);},Hide:function(){var element=this.GetMainElement();_aspxSetElementDisplay(element,false);element=this.GetLoadingDiv();if(element!=null)
_aspxSetElementDisplay(element,false);},GetVisible:function(){return _aspxGetElementDisplay(this.GetMainElement());},SetVisible:function(visible){if(visible&&!this.IsVisible())
this.Show();else if(!visible&&this.IsVisible())
this.Hide();}});var __aspxClientValidationStateNameSuffix="$CVS";ASPxClientEditBase=_aspxCreateClass(ASPxClientControl,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);},InlineInitialize:function(){this.InitializeEnabled();},InitializeEnabled:function(){this.SetEnabledInternal(this.clientEnabled,true);},GetValue:function(){var element=this.GetMainElement();if(_aspxIsExistsElement(element))
return element.innerHTML;return"";},GetValueString:function(){var value=this.GetValue();return(value==null)?null:value.toString();},SetValue:function(value){if(value==null)
value="";var element=this.GetMainElement();if(_aspxIsExistsElement(element))
element.innerHTML=value;},GetEnabled:function(){return this.enabled&&this.clientEnabled;},SetEnabled:function(enabled){if(this.clientEnabled!=enabled){this.clientEnabled=enabled;this.SetEnabledInternal(enabled,false);}},SetEnabledInternal:function(enabled,initialization){if(!this.enabled)return;if(!initialization||!enabled)
this.ChangeEnabledStateItems(enabled);this.ChangeEnabledAttributes(enabled);},ChangeEnabledAttributes:function(enabled){},ChangeEnabledStateItems:function(enabled){}});ASPxValidationPattern=_aspxCreateClass(null,{constructor:function(errorText){this.errorText=errorText;}});ASPxRequiredFieldValidationPattern=_aspxCreateClass(ASPxValidationPattern,{constructor:function(errorText){this.constructor.prototype.constructor.call(this,errorText);},EvaluateIsValid:function(value){if(typeof(value)=="boolean")
return value;else
return value!=null&&_aspxTrim(value.toString())!="";}});ASPxRegularExpressionValidationPattern=_aspxCreateClass(ASPxValidationPattern,{constructor:function(errorText,pattern){this.constructor.prototype.constructor.call(this,errorText);this.pattern=pattern;},EvaluateIsValid:function(value){if(value==null)
return true;var strValue=value.toString();if(_aspxTrim(strValue).length==0)
return true;var regEx=new RegExp(this.pattern);var matches=regEx.exec(strValue);return matches!=null&&strValue==matches[0];}});function _aspxIsEditorFocusable(inputElement){return _aspxIsFocusableCore(inputElement,function(container){return container.getAttribute("errorFrame")=="errorFrame";});}
var __aspxInvalidEditorToBeFocused=null;ASPxValidationType={PersonalOnValueChanged:"ValueChanged",PersonalViaScript:"CalledViaScript",MassValidation:"MassValidation"};ASPxErrorFrameDisplay={Static:"Static",Dynamic:"Dynamic"};ASPxEditElementSuffix={ExternalTable:"_ET",ControlCell:"_CC",ErrorCell:"_EC",ErrorTextCell:"_ETC",ErrorImage:"_EI"};ASPxClientEdit=_aspxCreateClass(ASPxClientEditBase,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.isASPxClientEdit=true;this.inputElement=null;this.elementCache={};this.convertEmptyStringToNull=true;this.readOnly=false;this.focused=false;this.focusEventsLocked=false;this.widthCorrectionRequired=false;this.heightCorrectionRequired=false;this.customValidationEnabled=false;this.display=ASPxErrorFrameDisplay.Static;this.initialErrorText="";this.causesValidation=false;this.validateOnLeave=true;this.validationGroup="";this.sendPostBackWithValidation=null;this.validationPatterns=null;this.setFocusOnError=false;this.errorDisplayMode="it";this.errorText="";this.isValid=true;this.errorImageIsAssigned=false;this.clientValidationStateElement=null;this.enterProcessed=false;this.keyDownHandlers={};this.keyPressHandlers={};this.keyUpHandlers={};this.specialKeyboardHandlingUsed=false;this.onKeyDownHandler=null;this.onKeyPressHandler=null;this.onKeyUpHandler=null;this.onGotFocusHandler=null;this.onLostFocusHandler=null;this.GotFocus=new ASPxClientEvent();this.LostFocus=new ASPxClientEvent();this.Validation=new ASPxClientEvent();this.ValueChanged=new ASPxClientEvent();this.KeyDown=new ASPxClientEvent();this.KeyPress=new ASPxClientEvent();this.KeyUp=new ASPxClientEvent();},Initialize:function(){this.initialErrorText=this.errorText;ASPxClientEditBase.prototype.Initialize.call(this);this.InitializeKeyHandlers();this.UpdateClientValidationState();},InitSpecialKeyboardHandling:function(){this.onKeyDownHandler=_aspxCreateEventHandlerFunction("aspxKBSIKeyDown",this.name,true);this.onKeyPressHandler=_aspxCreateEventHandlerFunction("aspxKBSIKeyPress",this.name,true);this.onKeyUpHandler=_aspxCreateEventHandlerFunction("aspxKBSIKeyUp",this.name,true);this.onGotFocusHandler=_aspxCreateEventHandlerFunction("aspxESGotFocus",this.name,false);this.onLostFocusHandler=_aspxCreateEventHandlerFunction("aspxESLostFocus",this.name,false);this.specialKeyboardHandlingUsed=true;},InitializeKeyHandlers:function(){},AddKeyDownHandler:function(key,handler){this.keyDownHandlers[key]=handler;},ChangeSpecialInputEnabledAttributes:function(element,method){element.autocomplete="off";if(this.onKeyDownHandler!=null)
method(element,"keydown",this.onKeyDownHandler);if(this.onKeyPressHandler!=null)
method(element,"keypress",this.onKeyPressHandler);if(this.onKeyUpHandler!=null)
method(element,"keyup",this.onKeyUpHandler);if(this.onGotFocusHandler!=null)
method(element,"focus",this.onGotFocusHandler);if(this.onLostFocusHandler!=null)
method(element,"blur",this.onLostFocusHandler);},UpdateClientValidationState:function(){var mainElement=this.GetMainElement();if(_aspxIsExists(mainElement)){var hiddenField=this.GetClientValidationStateHiddenField();if(_aspxIsExists(hiddenField))
hiddenField.value=!this.GetIsValid()?("-"+this.GetErrorText()):"";}},GetCachedElementByIdSuffix:function(idSuffix){var element=this.elementCache[idSuffix];if(!_aspxIsExistsElement(element)){element=_aspxGetElementById(this.name+idSuffix);this.elementCache[idSuffix]=element;}
return element;},FindInputElement:function(){return null;},GetInputElement:function(){if(!_aspxIsExistsElement(this.inputElement))
this.inputElement=this.FindInputElement();return this.inputElement;},GetErrorImage:function(){return this.GetCachedElementByIdSuffix(ASPxEditElementSuffix.ErrorImage);},GetExternalTable:function(){return this.GetCachedElementByIdSuffix(ASPxEditElementSuffix.ExternalTable);},GetControlCell:function(){return this.GetCachedElementByIdSuffix(ASPxEditElementSuffix.ControlCell);},GetErrorCell:function(){return this.GetCachedElementByIdSuffix(ASPxEditElementSuffix.ErrorCell);},GetErrorTextCell:function(){return this.GetCachedElementByIdSuffix(this.errorImageIsAssigned?ASPxEditElementSuffix.ErrorTextCell:ASPxEditElementSuffix.ErrorCell);},GetClientValidationStateHiddenField:function(){if(!_aspxIsExists(this.clientValidationStateElement))
this.clientValidationStateElement=this.CreateClientValidationStateHiddenField();return this.clientValidationStateElement;},CreateClientValidationStateHiddenField:function(){var mainElement=this.GetMainElement();var hiddenField=_aspxCreateHiddenField(this.uniqueID+__aspxClientValidationStateNameSuffix);mainElement.parentNode.appendChild(hiddenField);return hiddenField;},SetVisible:function(isVisible){if(this.clientVisible==isVisible)
return;if(this.customValidationEnabled){var errorFrame=this.GetExternalTable();if(_aspxIsExists(errorFrame)){if(isVisible){_aspxSetElementDisplay(errorFrame,true);this.UpdateErrorFrameAndFocus(false,true);}else{_aspxSetElementDisplay(errorFrame,false);}}}
ASPxClientControl.prototype.SetVisible.call(this,isVisible);},GetValueInputToValidate:function(){return this.GetInputElement();},IsVisible:function(){if(!this.clientVisible)
return false;var element=this.GetMainElement();while(_aspxIsExists(element)&&element.tagName!="BODY"){if(element.getAttribute("errorFrame")!="errorFrame"&&(!_aspxGetElementVisibility(element)||!_aspxGetElementDisplay(element)))
return false;element=element.parentNode;}
return true;},AdjustControlCore:function(){var mainElement=this.GetMainElement();var mainElementCurStyle=_aspxGetCurrentStyle(mainElement);this.CollapseControl();if(this.widthCorrectionRequired&&mainElementCurStyle.width!=""&&mainElementCurStyle.width!="auto")
this.CorrectEditorWidth();else
this.UnstretchInputElement();if(this.heightCorrectionRequired)
this.CorrectEditorHeight();},CorrectEditorWidth:function(){},CorrectEditorHeight:function(){},UnstretchInputElement:function(){},IsFocusEventsLocked:function(){return this.focusEventsLocked;},LockFocusEvents:function(){if(!this.focused)return;this.focusEventsLocked=true;},UnlockFocusEvents:function(){this.focusEventsLocked=false;},OnFocusCore:function(){if(!this.IsFocusEventsLocked()){this.focused=true;this.RaiseFocus();}
else
this.UnlockFocusEvents();},OnLostFocusCore:function(){if(!this.IsFocusEventsLocked()){this.focused=false;this.RaiseLostFocus();if(this.validateOnLeave)
this.SetFocusOnError();}},OnFocus:function(){if(this.isInitialized&&!this.specialKeyboardHandlingUsed)
this.OnFocusCore();},OnLostFocus:function(){if(this.isInitialized&&!this.specialKeyboardHandlingUsed)
this.OnLostFocusCore();},OnSpecialFocus:function(){if(this.isInitialized)
this.OnFocusCore();},OnSpecialLostFocus:function(){if(this.isInitialized)
this.OnLostFocusCore();},OnValidation:function(validationType){if(this.customValidationEnabled&&this.isInitialized&&_aspxIsExistsElement(this.GetExternalTable())){this.SetIsValid(true);this.SetErrorText(this.initialErrorText);if(this.validateOnLeave||validationType!=ASPxValidationType.PersonalOnValueChanged){this.ValidateWithPatterns();this.RaiseValidation();}
this.UpdateErrorFrameAndFocus(validationType==ASPxValidationType.PersonalOnValueChanged&&this.validateOnLeave&&!this.GetIsValid());}},OnValueChanged:function(){var processOnServer=this.RaiseValueChangedEvent();processOnServer=this.RaiseValidationInternal()&&processOnServer;if(processOnServer)
this.SendPostBackInternal("");},ParseValue:function(){},RaisePersonalStandardValidation:function(){if(_aspxIsFunction(window.ValidatorOnChange)){var inputElement=this.GetValueInputToValidate();if(_aspxIsExists(inputElement.Validators))
window.ValidatorOnChange({srcElement:inputElement});}},RaiseValidationInternal:function(){if(this.autoPostBack&&this.causesValidation&&this.validateOnLeave)
return ASPxClientEdit.ValidateGroup(this.validationGroup);else{this.OnValidation(ASPxValidationType.PersonalOnValueChanged);return this.GetIsValid();}},RaiseValueChangedEvent:function(){return this.RaiseValueChanged();},SendPostBackInternal:function(postBackArg){if(_aspxIsFunction(this.sendPostBackWithValidation))
this.sendPostBackWithValidation(postBackArg);else
this.SendPostBack(postBackArg);},SetElementToBeFocused:function(){if(this.IsVisible())
__aspxInvalidEditorToBeFocused=this;},SetFocus:function(){var inputElement=this.GetInputElement();if(_aspxGetActiveElement()!=inputElement&&_aspxIsEditorFocusable(inputElement))
_aspxSetFocus(inputElement);},SetFocusOnError:function(){if(__aspxInvalidEditorToBeFocused==this){this.SetFocus();__aspxInvalidEditorToBeFocused=null;}},UpdateErrorFrameAndFocus:function(setFocusOnError,ignoreVisibilityCheck){var externalTable=this.GetExternalTable();var isStaticDisplay=this.display==ASPxErrorFrameDisplay.Static;if(this.GetIsValid()){if(isStaticDisplay){externalTable.style.visibility="hidden";}else{this.HideErrorCell();this.SaveErrorFrameStyles();this.ClearErrorFrameElementsStyles();}}else{if(ignoreVisibilityCheck||this.IsVisible()){if(__aspxIE&&!isStaticDisplay)
this.CollapseControl();this.UpdateErrorCellContent();if(isStaticDisplay){externalTable.style.visibility="visible";}else{this.EnsureErrorFrameStylesLoaded();this.RestoreErrorFrameElementsStyles();this.ShowErrorCell();}
if(__aspxIE&&!isStaticDisplay)
this.AdjustControl();if(setFocusOnError&&this.setFocusOnError&&__aspxInvalidEditorToBeFocused==null)
this.SetElementToBeFocused();}}},ShowErrorCell:function(){var errorCell=this.GetErrorCell();if(_aspxIsExists(errorCell))
_aspxSetElementDisplay(errorCell,true);},HideErrorCell:function(){var errorCell=this.GetErrorCell();if(_aspxIsExists(errorCell))
_aspxSetElementDisplay(errorCell,false);},SaveErrorFrameStyles:function(){this.EnsureErrorFrameStylesLoaded();},EnsureErrorFrameStylesLoaded:function(){if(typeof(this.errorFrameStyles)=="undefined"){var externalTable=this.GetExternalTable();var controlCell=this.GetControlCell();this.errorFrameStyles={errorFrame:{cssClass:externalTable.className,style:this.ExtractElementStyleStringIgnoringVisibilityProps(externalTable)},controlCell:{cssClass:controlCell.className,style:this.ExtractElementStyleStringIgnoringVisibilityProps(controlCell)}};}},ClearErrorFrameElementsStyles:function(){this.ClearElementStyle(this.GetExternalTable());this.ClearElementStyle(this.GetControlCell());},RestoreErrorFrameElementsStyles:function(){var externalTable=this.GetExternalTable();externalTable.className=this.errorFrameStyles.errorFrame.cssClass;externalTable.style.cssText=this.errorFrameStyles.errorFrame.style;var controlCell=this.GetControlCell();controlCell.className=this.errorFrameStyles.controlCell.cssClass;controlCell.style.cssText=this.errorFrameStyles.controlCell.style;},ExtractElementStyleStringIgnoringVisibilityProps:function(element){var savedVisibility=element.style.visibility;var savedDisplay=element.style.display;element.style.visibility="";element.style.display="";var styleStr=element.style.cssText;element.style.visibility=savedVisibility;element.style.display=savedDisplay;return styleStr;},ClearElementStyle:function(element){if(!_aspxIsExists(element))
return;element.className="";var savedVisibility=element.style.visibility;var savedDisplay=element.style.display;var savedWidth=element.style.width;element.style.cssText="";element.style.visibility=savedVisibility;element.style.display=savedDisplay;element.style.width=savedWidth;},UpdateErrorCellContent:function(){if(this.errorDisplayMode.indexOf("t")>-1)
this.UpdateErrorText();if(this.errorDisplayMode=="i")
this.UpdateErrorImage();},UpdateErrorImage:function(){var image=this.GetErrorImage();if(_aspxIsExistsElement(image)){image.alt=this.errorText;image.title=this.errorText;}else{this.UpdateErrorText();}},UpdateErrorText:function(){var errorTextCell=this.GetErrorTextCell();if(_aspxIsExistsElement(errorTextCell)){if(_aspxIsExistsElement(errorTextCell.firstChild))
errorTextCell.replaceChild(document.createTextNode(this.errorText),errorTextCell.firstChild);else
errorTextCell.appendChild(document.createTextNode(this.errorText));}},ValidateWithPatterns:function(){if(this.validationPatterns!=null){var value=this.GetValue();for(var i=0;i<this.validationPatterns.length;i++){var validator=this.validationPatterns[i];if(!validator.EvaluateIsValid(value)){this.SetIsValid(false);this.SetErrorText(validator.errorText);return;}}}},OnSpecialKeyDown:function(evt){this.RaiseKeyDown(evt);var handler=this.keyDownHandlers[evt.keyCode];if(_aspxIsExists(handler))
return this[handler](evt);return false;},OnSpecialKeyPress:function(evt){this.RaiseKeyPress(evt);var handler=this.keyPressHandlers[evt.keyCode];if(_aspxIsExists(handler))
return this[handler](evt);if(__aspxNS||__aspxOpera){if(evt.keyCode==ASPxKey.Enter)
return this.enterProcessed;}
return false;},OnSpecialKeyUp:function(evt){this.RaiseKeyUp(evt);var handler=this.keyUpHandlers[evt.keyCode];if(_aspxIsExists(handler))
return this[handler](evt);return false;},OnKeyDown:function(evt){if(!this.specialKeyboardHandlingUsed)
this.RaiseKeyDown(evt);},OnKeyPress:function(evt){if(!this.specialKeyboardHandlingUsed)
this.RaiseKeyPress(evt);},OnKeyUp:function(evt){if(!this.specialKeyboardHandlingUsed)
this.RaiseKeyUp(evt);},RaiseKeyDown:function(evt){if(!this.KeyDown.IsEmpty()){var args=new ASPxClientEditKeyEventArgs(evt);this.KeyDown.FireEvent(this,args);}},RaiseKeyPress:function(evt){if(!this.KeyPress.IsEmpty()){var args=new ASPxClientEditKeyEventArgs(evt);this.KeyPress.FireEvent(this,args);}},RaiseKeyUp:function(evt){if(!this.KeyUp.IsEmpty()){var args=new ASPxClientEditKeyEventArgs(evt);this.KeyUp.FireEvent(this,args);}},RaiseFocus:function(){if(!this.GotFocus.IsEmpty()){var args=new ASPxClientEventArgs();this.GotFocus.FireEvent(this,args);}},RaiseLostFocus:function(){if(!this.LostFocus.IsEmpty()){var args=new ASPxClientEventArgs();this.LostFocus.FireEvent(this,args);}},RaiseValidation:function(){if(this.customValidationEnabled&&!this.Validation.IsEmpty()){var currentValue=this.GetValue();var args=new ASPxClientEditValidationEventArgs(currentValue,this.errorText,this.GetIsValid());this.Validation.FireEvent(this,args);this.SetErrorText(args.errorText);this.SetIsValid(args.isValid);if(args.value!=currentValue)
this.SetValue(args.value);}},RaiseValueChanged:function(){var processOnServer=this.autoPostBack;if(!this.ValueChanged.IsEmpty()){var args=new ASPxClientProcessingModeEventArgs(processOnServer);this.ValueChanged.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;},Focus:function(){this.SetFocus();},GetIsValid:function(){var externalTable=this.GetExternalTable();return _aspxIsExistsElement(externalTable)?this.isValid:true;},GetErrorText:function(){return this.errorText;},SetIsValid:function(isValid){if(this.customValidationEnabled){this.isValid=isValid;this.UpdateErrorFrameAndFocus(false);this.UpdateClientValidationState();}},SetErrorText:function(errorText){if(this.customValidationEnabled){this.errorText=errorText;this.UpdateErrorFrameAndFocus(false);this.UpdateClientValidationState();}},Validate:function(){this.ParseValue();this.OnValidation(ASPxValidationType.PersonalViaScript);}});ASPxClientEdit.ClearEditorsInContainer=function(container,validationGroup,clearInvisibleEditors){__aspxInvalidEditorToBeFocused=null;_aspxProcessEditorsInContainer(container,_aspxClearProcessingProc,_aspxClearChoiceCondition,validationGroup,clearInvisibleEditors);}
ASPxClientEdit.ClearEditorsInContainerById=function(containerId,validationGroup,clearInvisibleEditors){var container=document.getElementById(containerId);this.ClearEditorsInContainer(container,validationGroup,clearInvisibleEditors);}
ASPxClientEdit.ClearGroup=function(validationGroup,clearInvisibleEditors){return this.ClearEditorsInContainer(null,validationGroup,clearInvisibleEditors);}
ASPxClientEdit.ValidateEditorsInContainer=function(container,validationGroup,validateInvisibleEditors){var validationResult=_aspxProcessEditorsInContainer(container,_aspxValidateProcessingProc,_aspxValidateChoiceCondition,validationGroup,validateInvisibleEditors);if(_aspxIsExistsType(typeof(aspxGetGlobalEvents))){if(typeof(validateInvisibleEditors)=="undefined")
validateInvisibleEditors=false;if(typeof(validationGroup)=="undefined")
validationGroup=null;validationResult.isValid=aspxGetGlobalEvents().OnValidationCompleted(container,validationGroup,validateInvisibleEditors,validationResult.isValid,validationResult.firstInvalid,validationResult.firstVisibleInvalid);}
return validationResult.isValid;}
ASPxClientEdit.ValidateEditorsInContainerById=function(containerId,validationGroup,validateInvisibleEditors){var container=document.getElementById(containerId);return this.ValidateEditorsInContainer(container,validationGroup,validateInvisibleEditors);}
ASPxClientEdit.ValidateGroup=function(validationGroup,validateInvisibleEditors){return this.ValidateEditorsInContainer(null,validationGroup,validateInvisibleEditors);}
ASPxClientEditKeyEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(htmlEvent){this.constructor.prototype.constructor.call(this);this.htmlEvent=htmlEvent;}});ASPxClientEditValidationEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(value,errorText,isValid){this.constructor.prototype.constructor.call(this);this.errorText=errorText;this.isValid=isValid;this.value=value;}});function aspxEGotFocus(name){var edit=aspxGetControlCollection().Get(name);if(edit!=null)
edit.OnFocus();}
function aspxELostFocus(name){var edit=aspxGetControlCollection().Get(name);if(edit!=null)
edit.OnLostFocus();}
function aspxESGotFocus(name){var edit=aspxGetControlCollection().Get(name);if(edit!=null)
edit.OnSpecialFocus();}
function aspxESLostFocus(name){var edit=aspxGetControlCollection().Get(name);if(edit!=null)
edit.OnSpecialLostFocus();}
function aspxEValueChanged(name){var edit=aspxGetControlCollection().Get(name);if(edit!=null)
edit.OnValueChanged();}
function aspxKBSIKeyDown(name,evt){var control=aspxGetControlCollection().Get(name);if(control!=null){var isProcessed=control.OnSpecialKeyDown(evt);if(isProcessed)
return _aspxPreventEventAndBubble(evt);}}
function aspxKBSIKeyPress(name,evt){var control=aspxGetControlCollection().Get(name);if(control!=null){var isProcessed=control.OnSpecialKeyPress(evt);if(isProcessed)
return _aspxPreventEventAndBubble(evt);}}
function aspxKBSIKeyUp(name,evt){var control=aspxGetControlCollection().Get(name);if(control!=null){var isProcessed=control.OnSpecialKeyUp(evt);if(isProcessed)
return _aspxPreventEventAndBubble(evt);}}
function aspxEKeyDown(name,evt){var edit=aspxGetControlCollection().Get(name);if(edit!=null)
edit.OnKeyDown(evt);}
function aspxEKeyPress(name,evt){var edit=aspxGetControlCollection().Get(name);if(edit!=null)
edit.OnKeyPress(evt);}
function aspxEKeyUp(name,evt){var edit=aspxGetControlCollection().Get(name);if(edit!=null)
edit.OnKeyUp(evt);}
ASPxValidationResult=_aspxCreateClass(null,{constructor:function(isValid,firstInvalid,firstVisibleInvalid){this.isValid=isValid;this.firstInvalid=firstInvalid;this.firstVisibleInvalid=firstVisibleInvalid;}});function _aspxProcessEditorsInContainer(container,processingProc,choiceCondition,validationGroup,processInvisibleEditors){var allProcessedSuccessfull=true;var firstInvalid=null;var firstVisibleInvalid=null;var invalidEditorToBeFocused=null;var collection=aspxGetControlCollection();for(var key in collection.elements){var control=collection.elements[key];if(control!=null&&ASPxIdent.IsASPxClientEdit(control)){var mainElement=control.GetMainElement();if(_aspxIsExists(mainElement)&&(container==null||_aspxGetIsParent(container,mainElement))&&(processInvisibleEditors||control.IsVisible())&&choiceCondition(control,validationGroup)){var isSuccess=processingProc(control);if(!isSuccess){allProcessedSuccessfull=false;if(firstInvalid==null)
firstInvalid=control;var isVisible=control.IsVisible();if(isVisible&&firstVisibleInvalid==null)
firstVisibleInvalid=control;if(control.setFocusOnError&&invalidEditorToBeFocused==null&&isVisible)
invalidEditorToBeFocused=control;}}}}
if(invalidEditorToBeFocused!=null)
invalidEditorToBeFocused.SetFocus();return new ASPxValidationResult(allProcessedSuccessfull,firstInvalid,firstVisibleInvalid);}
function _aspxClearChoiceCondition(edit,validationGroup){return!_aspxIsExists(validationGroup)||(edit.validationGroup==validationGroup);}
function _aspxValidateChoiceCondition(edit,validationGroup){return _aspxClearChoiceCondition(edit,validationGroup)&&edit.customValidationEnabled;}
function _aspxClearProcessingProc(edit){edit.SetValue(null);edit.SetIsValid(true);return true;}
function _aspxValidateProcessingProc(edit){edit.OnValidation(ASPxValidationType.MassValidation);return edit.GetIsValid();}
function _aspxGetCaretPosition(inputElement){return _aspxGetSelection(inputElement).startPos;}
function _aspxSetSelectionCore(inputElement,startPos,endPos){if(__aspxIE){var range=inputElement.createTextRange();range.collapse(true);range.moveStart("character",startPos);range.moveEnd("character",endPos-startPos);range.select();}else
inputElement.setSelectionRange(startPos,endPos);}
function _aspxSetSelection(inputElement,startPos,endPos,scrollToSelection){var textLen=inputElement.value.length;if(endPos==-1||endPos>textLen)
endPos=textLen;if(startPos>textLen)
startPos=textLen;if(startPos>endPos)
return;_aspxSetSelectionCore(inputElement,startPos,endPos);if(scrollToSelection&&inputElement.tagName=='TEXTAREA'){var scrollHeight=inputElement.scrollHeight;var approxCaretPos=startPos;var scrollTop=Math.max(Math.round(approxCaretPos*scrollHeight/textLen-inputElement.clientHeight/2),0);inputElement.scrollTop=scrollTop;}}
function _aspxSetCaretPosition(inputElement,caretPos,scrollToSelection){if(!scrollToSelection)
scrollToSelection=true;if(caretPos==-1)
caretPos=inputElement.value.length;_aspxSetSelection(inputElement,caretPos,caretPos,scrollToSelection);}
var __aspxItemAttrsSeparator="::";var __aspxItemsSeparator=";;";var __aspxLoadRangeItemsCallbackPrefix="LBCRI";var __aspxLBIPostfixes=['I','T'];var __aspxLBIIdSuffix="LBI";var __aspxLBSIIdSuffix=__aspxLBIIdSuffix+"-1";var __aspxLBTSIdSuffix="_TS";var __aspxLBBSIdSuffix="_BS";var __aspxLTableIdSuffix="_LBT";var __aspxLEVISuffix="_VI";var __aspxLBDSuffix="_D";var __aspxEmptyItemsRange="0:-1";var __aspxNbsp="&nbsp;";var __aspxCachedHoverItemKind="cached"+__aspxHoverItemKind;var __aspxCachedSelectedItemKind="cached"+__aspxSelectedItemKind;ASPxClientListEdit=_aspxCreateClass(ASPxClientEdit,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.SelectedIndexChanged=new ASPxClientEvent();this.savedSelectedIndex=-1;},RaiseValueChangedEvent:function(){var processOnServer=ASPxClientEdit.prototype.RaiseValueChangedEvent.call(this);processOnServer=this.RaiseSelectedIndexChanged(processOnServer);return processOnServer;},FindInputElement:function(){return this.FindStateInputElement();},FindStateInputElement:function(){return document.getElementById(this.name+__aspxLEVISuffix);},GetItemValue:function(index){throw"Not implemented";},GetValue:function(){return this.GetItemValue(this.GetSelectedIndexInternal());},GetSelectedIndexInternal:function(){return this.savedSelectedIndex;},SetSelectedIndexInternal:function(index){this.savedSelectedIndex=index;},RaiseItemDoubleClick:function(){var processOnServer=this.autoPostBack;if(!this.ItemDoubleClick.IsEmpty()){var args=new ASPxClientProcessingModeEventArgs(processOnServer);this.ItemDoubleClick.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;},RaiseSelectedIndexChanged:function(processOnServer){if(!this.SelectedIndexChanged.IsEmpty()){var args=new ASPxClientProcessingModeEventArgs(processOnServer);this.SelectedIndexChanged.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;},UpdateHiddenInputs:function(index){var element=this.FindStateInputElement();if(_aspxIsExistsElement(element)){var value=this.GetItemValue(index);if(value==null)
value="";element.value=value;}},GetSelectedItem:function(){var index=this.GetSelectedIndexInternal();return this.GetItem(index);},GetSelectedIndex:function(){return this.GetSelectedIndexInternal();},SetSelectedItem:function(item){var index=(item!=null)?item.index:-1;this.SelectIndexSilent(index);},SetSelectedIndex:function(index){this.SelectIndexSilent(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;}});_aspxListBoxScrollCallbackHelperBase=_aspxCreateClass(null,{constructor:function(listBoxControl){this.listBoxControl=listBoxControl;this.itemsRange="";this.defaultItemsRange="0:"+(this.listBoxControl.callbackPageSize-1);},OnScroll:function(){},Reset:function(){},IsScrolledToTopSpacer:function(){return false;},IsScrolledToBottomSpacer:function(){return false;},GetIsNeedToHideTopSpacer:function(){return false;},GetIsNeedCallback:function(){return false;},GetItemsRangeForLoad:function(){return this.defaultItemsRange;},SetItemsRangeForLoad:function(){}});_aspxListBoxScrollCallbackHelper=_aspxCreateClass(_aspxListBoxScrollCallbackHelperBase,{constructor:function(listBoxControl){this.constructor.prototype.constructor.call(this,listBoxControl);this.isScrolledToTopSpacer=false;this.isScrolledToBottomSpacer=false;},OnScroll:function(){this.DetectScrollDirection();this.ResetItemsRange();if(this.GetIsAnySpacerVisible())
this.RecalcItemsRangeForLoad();},DetectScrollDirection:function(){var listBoxControl=this.listBoxControl;var divElement=listBoxControl.GetScrollDivElement();var listTable=listBoxControl.GetListTable();var scrollTop=divElement.scrollTop;var scrollBottom=divElement.scrollTop+divElement.clientHeight;var isTopSpacerVisible=listBoxControl.GetScrollSpacerVisibility(true);var isBottomSpacerVisible=listBoxControl.GetScrollSpacerVisibility(false);var topSpacerHeight=listBoxControl.isTopSpacerVisible?parseInt(listBoxControl.GetScrollSpacerElement(true).clientHeight):0;this.isScrolledToTopSpacer=(scrollTop<topSpacerHeight)&&isTopSpacerVisible;this.isScrolledToBottomSpacer=(scrollBottom>=topSpacerHeight+listTable.clientHeight)&&isBottomSpacerVisible;},Reset:function(){this.ResetItemsRange();this.isScrolledToTopSpacer=false;this.isScrolledToBottomSpacer=false;},ResetItemsRange:function(){this.itemsRange="";},RecalcItemsRangeForLoad:function(){if(this.listBoxControl.isCallbackMode){if(this.isScrolledToTopSpacer||this.isScrolledToBottomSpacer)
this.SetItemsRangeForLoad(this.isScrolledToTopSpacer);}},IsScrolledToTopSpacer:function(){return this.isScrolledToTopSpacer;},IsScrolledToBottomSpacer:function(){return this.isScrolledToBottomSpacer;},GetIsAnySpacerVisible:function(){return this.isScrolledToTopSpacer||this.isScrolledToBottomSpacer;},GetIsNeedCallback:function(){return!this.GetIsItemsRangeEmpty();},GetIsNeedToHideTopSpacer:function(){return this.isScrolledToTopSpacer&&this.GetIsItemsRangeEmpty();},GetItemsRangeForLoad:function(){return(!this.GetIsItemsRangeEmpty()?this.itemsRange:this.defaultItemsRange);},SetItemsRangeForLoad:function(isForTop){var listbox=this.listBoxControl;var beginIndex=isForTop?listbox.serverIndexOfFirstItem-listbox.callbackPageSize:listbox.serverIndexOfFirstItem+listbox.GetItemCount();beginIndex=beginIndex<0?0:beginIndex;var endIndex=isForTop?listbox.serverIndexOfFirstItem-1:beginIndex+listbox.callbackPageSize-1;this.itemsRange=beginIndex+":"+endIndex;this.isScrolledToTopSpacer=isForTop;this.isScrolledToBottomSpacer=!isForTop;},GetIsItemsRangeEmpty:function(){return(this.itemsRange==""||this.itemsRange==__aspxEmptyItemsRange);}});ASPxClientListBoxBase=_aspxCreateClass(ASPxClientListEdit,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.APILockCount=0;this.isComboBoxList=false;this.isSyncEnabled=true;this.ownerName="";this.deletedItems=[];this.insertedItems=[];this.itemsValue=[];this.ItemDoubleClick=new ASPxClientEvent();},GetItemCount:function(){return 0;},GetItemValue:function(index){if(0<=index&&index<this.GetItemCount())
return this.PrepareItemValue(this.itemsValue[index]);return null;},PrepareItemValue:function(value){return(typeof(value)=="string"&&value==""&&this.convertEmptyStringToNull)?null:value;},LoadItemsFromCallback:function(isToTop,itemStrings){},SetValue:function(value){var index=this.GetItemIndexByValue(value);this.SelectIndexSilent(index,false);},GetItemIndexByValue:function(value){for(var i=this.GetItemCount()-1;i>=0;i--){if(this.GetItemValue(i)==value)
break;}
return i;},SelectIndexSilent:function(index,initialize){},SelectIndex:function(index){if(this.SelectIndexSilent(index,false)){this.RaisePersonalStandardValidation();this.OnValueChanged();}},MakeItemVisible:function(index){},InitOnContainerMadeVisible:function(){},AddItem:function(text,value,imageUrl){var index=this.GetItemCount();this.InsertItemInternal(index,text,value,imageUrl);return index;},InsertItem:function(index,text,value,imageUrl){this.InsertItemInternal(index,text,value,imageUrl);},InsertItemInternal:function(index,text,value,imageUrl){},BeginUpdate:function(){this.APILockCount++;},EndUpdate:function(){this.APILockCount--;this.Synchronize();},ClearItems:function(){this.BeginUpdate();this.UpdateArraysItemsCleared();this.ClearItemsCore();this.EndUpdate();},ClearItemsCore:function(){},ClearItemsForPerformCallback:function(){this.itemsValue=[];this.ClearItemsCore();},RemoveItem:function(index){},GetItem:function(index){return null;},PerformCallback:function(arg){},GetCallbackArguments:function(){var args=this.GetCustomCallbackArg();args+=this.GetLoadItemsRangeCallbackArg();return args;},GetLoadItemsRangeCallbackArg:function(){return this.FormatCallbackArg(__aspxLoadRangeItemsCallbackPrefix,this.GetItemsRangeForLoad());},FormatCallbackArg:function(prefix,arg){arg=arg.toString();return(_aspxIsExists(arg)?prefix+"|"+arg.length+';'+arg+';':"");},GetItemsRangeForLoad:function(){return __aspxEmptyItemsRange;},GetCallbackOwnerControl:function(){if(this.ownerName!=""&&!_aspxIsExists(this.ownerControl))
this.ownerControl=aspxGetControlCollection().Get(this.ownerName);return this.ownerControl;},GetCustomCallbackArg:function(){return this.GetSyncHiddenInput("CustomCallback").value;},SetCustomCallbackArg:function(arg){this.GetSyncHiddenInput("CustomCallback").value=arg;},FormatAndSetCustomCallbackArg:function(arg){var formatArg=this.FormatCallbackArg("LECC",_aspxIsExists(arg)?arg:"");this.SetCustomCallbackArg(formatArg);},SendCallback:function(){},AddItemClass:function(index,text,value,imageUrl){_aspxArrayInsert(this.itemsValue,value,index);if(this.isSyncEnabled){this.RefreshSynchroArraysIndex(index,true);var item=new ASPxClientListEditItem(this,index,text,value,imageUrl);_aspxArrayPush(this.insertedItems,item);this.Synchronize();}},UpdateSyncArraysItemDeleted:function(item,isValueRemovingRequired){if(isValueRemovingRequired)
_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){this.RefreshSynchroArraysIndex(item.index,false);_aspxArrayPush(this.deletedItems,item);}else{this.RefreshSynchroArraysIndex(item.index,false);_aspxArrayRemoveAt(this.insertedItems,index);}
this.Synchronize();}},UpdateArraysItemsCleared:function(){if(this.isSyncEnabled){for(var i=this.GetItemCount()-1;i>=0;i--)
this.UpdateSyncArraysItemDeleted(this.GetItem(i),false);}
this.itemsValue=[];},RefreshSynchroArraysIndex:function(startIndex,isIncrease){this.RefreshSynchroArrayIndexIndex(this.deletedItems,startIndex,isIncrease);this.RefreshSynchroArrayIndexIndex(this.insertedItems,startIndex,isIncrease);},RefreshSynchroArrayIndexIndex:function(array,startIndex,isIncrease){var delta=isIncrease?1:-1;for(var i=0;i<array.length;i++){if(array[i].index>=startIndex)
array[i].index+=delta;}},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;},GetSyncHiddenInput:function(syncType){return _aspxGetElementById(this.name+syncType);},Synchronize:function(){if(this.APILockCount==0){if(this.isSyncEnabled){this.SynchronizeItems(this.deletedItems,"DeletedItems");this.SynchronizeItems(this.insertedItems,"InsertedItems");}
this.CorrectSizeByTimer();}},CorrectSizeByTimer:function(){},SynchronizeItems:function(items,syncType){var inputElement=this.GetSyncHiddenInput(syncType);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;}},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"";},GetCorrectString:function(str){return _aspxIsExists(str)?str:"";},OnCallback:function(result){}});ASPxClientListBox=_aspxCreateClass(ASPxClientListBoxBase,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.freeUniqIndex=-1;this.isHasFakeRow=false;this.listTable=null;this.sampleItemTextCell=null;this.width="";this.hasSampleItem=false;this.hoverClass="";this.hoverCss="";this.selectedClass="";this.selectedCss="";this.disabledClass="";this.disabledCss="";this.scrollHandlerLockCount=0;this.allowMultipleCallbacks=false;this.isCallbackMode=false;this.callbackPageSize=-1;this.isTopSpacerVisible=false;this.isBottomSpacerVisible=false;this.serverIndexOfFirstItem=0;this.scrollHelper=null;this.changeSelectAfterCallback=0;this.ownerControl=null;this.SampleItem=null;this.scrollDivElement=null;this.scrollPageSize=4;this.itemsValue=[];},Initialize:function(){this.LockScrollHandler();this.freeUniqIndex=this.GetItemCount();this.SelectIndexSilent(this.GetSelectedIndexInternal(),true);this.AdjustControl(false);this.scrollHelper=this.isCallbackMode?new _aspxListBoxScrollCallbackHelper(this):new _aspxListBoxScrollCallbackHelperBase(this);this.UnlockScrollHandler();ASPxClientEdit.prototype.Initialize.call(this);},InlineInitialize:function(){this.LockScrollHandler();this.InitializeItemsAttributes();this.InitSpecialKeyboardHandling();this.GenerateStateItems();this.UnlockScrollHandler();ASPxClientEditBase.prototype.InlineInitialize.call(this);},CallbackSpaceInit:function(){if(this.isCallbackMode){this.SetBottomScrollSpacerVisibility(this.isBottomSpacerVisible);this.SetTopScrollSpacerVisibility(this.isTopSpacerVisible);_aspxAttachEventToElement(this.GetScrollDivElement(),"scroll",aspxLBScroll);this.EnsureSelectedItemVisible();}},InitializeItemsAttributes:function(){var listTable=this.GetListTable();if(this.isHasFakeRow){var isSyncEnabled=this.isSyncEnabled;this.isSyncEnabled=false;this.ClearItems();this.isSyncEnabled=isSyncEnabled;}
listTable.ListBoxId=this.name;var rows=listTable.rows;var count=rows.length;var rowIdConst=this.name+"_";if(this.hasSampleItem)
this.InitializeItemAttributes(this.GetSampleItem(),rowIdConst+__aspxLBSIIdSuffix);rowIdConst+=__aspxLBIIdSuffix;for(var i=0;i<count;i++)
this.InitializeItemAttributes(rows[i],rowIdConst+i);},InitializeItemAttributes:function(row,rowId){var cells=row.cells;var textCellId=rowId+__aspxLBIPostfixes[1];if(cells.length==2){cells[0].id=rowId+__aspxLBIPostfixes[0];cells[1].id=textCellId;}else
cells[0].id=textCellId;},InitializePageSize:function(){var divElement=this.GetScrollDivElement();var listTable=this.GetListTable();var rows=listTable.rows;var count=rows.length;if(_aspxIsExists(divElement)&&count>0)
this.scrollPageSize=Math.round(divElement.clientHeight/rows[0].offsetHeight)-1;},GenerateStateItems:function(){var count=this.GetItemCount();var constName=this.name+"_"+__aspxLBIIdSuffix;var name="";var controller=aspxGetStateController();var i=this.hasSampleItem?-1:0;for(;i<count;i++){name=constName+i;controller.AddHoverItem(name,this.hoverClass,this.hoverCss,__aspxLBIPostfixes,null,null);controller.AddSelectedItem(name,this.selectedClass,this.selectedCss,__aspxLBIPostfixes,null,null);controller.AddDisabledItem(name,this.disabledClass,this.disabledCss,__aspxLBIPostfixes,null,null);}},IsVisibleWhenCorrectingSize:function(){return this.IsDisplayed();},AdjustControlCore:function(){ASPxClientEdit.prototype.AdjustControlCore.call(this);this.CorrectSizeInternal();this.InitializePageSize();this.EnsureSelectedItemVisible();this.CallbackSpaceInit();if(!this.isComboBoxList&&__aspxIE7)
this.CorrectWidth();},CorrectSizeInternal:function(){if(this.isComboBoxList)
return;this.CorrectHeight();this.CorrectWidth();},CorrectSizeInternalByTimer:function(){if(this.IsVisible())
this.CorrectSizeInternal();},CorrectHeight:function(){var mainElement=this.GetMainElement();var divElement=this.GetScrollDivElement();if(__aspxIE55)divElement.style.display="none";divElement.style.height="0px";var height=mainElement.offsetHeight;if(__aspxIE55)divElement.style.display="";divElement.style.height=height+"px";var extrudedeHeight=mainElement.offsetHeight;var heightCorrection=extrudedeHeight-height;if(heightCorrection>0){var divHeight=divElement.offsetHeight;divElement.style.height=(divHeight-heightCorrection)+"px";extrudedeHeight=mainElement.offsetHeight;var paddingsHeightCorrection=extrudedeHeight-height;if(paddingsHeightCorrection>0)
divElement.style.height=(divHeight-heightCorrection-paddingsHeightCorrection)+"px";}},CorrectWidth:function(){var divElement=this.GetScrollDivElement();if(__aspxIE){var mainElement=this.GetMainElement();var scrollBarWidth=this.GetVerticalScrollBarWidth();mainElement.style.width="";divElement.style.width="100%";if(!__aspxIE55)
divElement.style.paddingRight="0px";if(this.width!=""){mainElement.style.width=this.width;divElement.style.width="0px";var widthCorrectrion=__aspxIE55?0:scrollBarWidth;divElement.style.width=(mainElement.clientWidth-widthCorrectrion)+"px";}
else{var widthCorrectrion=__aspxIE55?scrollBarWidth:0;if(this.IsListBoxWidthLessThenList())
widthCorrectrion-=scrollBarWidth;divElement.style.width=(mainElement.clientWidth+widthCorrectrion)+"px";}
if(!__aspxIE55)
divElement.style.paddingRight=scrollBarWidth+"px";}else{if(this.width==""){var listTable=this.GetListTable();var mainElement=this.GetMainElement();if(listTable.offsetWidth!=0||!__aspxMozilla){divElement.style.width=(listTable.offsetWidth+this.GetVerticalScrollBarWidth())+"px";if(__aspxFirefox)
mainElement.style.width=divElement.offsetWidth+"px";}}}},EnsureSelectedItemVisible:function(){var index=this.GetSelectedIndexInternal();if(index!=-1)
this.MakeItemVisible(index);},MakeItemVisible:function(index){if(!this.IsItemVisible(index))
this.ScrollItemToTop(index);},IsItemVisible:function(index){var scrollDiv=this.GetScrollDivElement();var itemElement=this.GetItemElement(index);var topVisible=false;var bottomVisible=false;if(itemElement!=null){var itemOffsetTop=itemElement.offsetTop+this.GetTopScrollSpacerHeight();topVisible=itemOffsetTop>=scrollDiv.scrollTop;bottomVisible=itemOffsetTop+itemElement.offsetHeight<scrollDiv.scrollTop+scrollDiv.clientHeight;}
return(topVisible&&bottomVisible);},ScrollItemToTop:function(index){this.LockScrollHandler();var scrollDiv=this.GetScrollDivElement();if(_aspxIsExists(scrollDiv))
scrollDiv.scrollTop=this.GetItemTopOffset(index);this.UnlockScrollHandler();},ScrollToItemVisible:function(index){if(!this.IsItemVisible(index)){var scrollDiv=this.GetScrollDivElement();var scrollTop=scrollDiv.scrollTop;var scrollDivHeight=scrollDiv.clientHeight;var itemOffsetTop=this.GetItemTopOffset(index);var itemHeight=this.GetItemHeight(index);var itemAbove=scrollTop>itemOffsetTop;var itemBelow=scrollTop+scrollDivHeight<itemOffsetTop+itemHeight;if(itemAbove)
scrollDiv.scrollTop=itemOffsetTop;else if(itemBelow){var scrollPaddings=scrollDiv.scrollHeight-this.GetListTable().offsetHeight-
this.GetTopScrollSpacerHeight()-this.GetBottomScrollSpacerHeight();scrollDiv.scrollTop=itemOffsetTop+itemHeight-scrollDivHeight+scrollPaddings;}}},GetItemElement:function(index){var itemElement=this.GetItemRow(index);return __aspxSafariFamily?itemElement.cells[0]:itemElement;},GetItemTopOffset:function(index){var itemElement=this.GetItemElement(index);return(itemElement!=null)?itemElement.offsetTop+this.GetTopScrollSpacerHeight():0;},GetItemHeight:function(index){var itemElement=this.GetItemElement(index);return(itemElement!=null)?itemElement.offsetHeight:0;},IsListBoxWidthLessThenList:function(){var divElement=this.GetScrollDivElement();var listTable=this.GetListTable();var listTabelWidth=listTable.style.width;var isLess=false;listTable.style.width="";isLess=listTable.offsetWidth<divElement.offsetWidth;listTable.style.width=listTabelWidth;return isLess;},GetScrollDivElement:function(){if(!_aspxIsExistsElement(this.scrollDivElement))
this.scrollDivElement=document.getElementById(this.name+__aspxLBDSuffix);return this.scrollDivElement;},GetItemCount:function(){var lbt=this.GetListTable();if(_aspxIsExists(lbt))
return this.GetListTable().rows.length;return 0;},GetItemCell:function(index,isImageCell){var itemRow=this.GetItemRow(index);return(itemRow!=null?this.GetItemRowCell(itemRow,isImageCell):null);},GetItemImageCell:function(index){return this.GetItemCell(index,true);},GetItemTextCell:function(index){return this.GetItemCell(index,false);},GetItemRow:function(index){var listTable=this.GetListTable();if(_aspxIsExists(listTable)){if(0<=index&&index<listTable.rows.length)
return listTable.rows[index];}
return null;},GetItemRowCell:function(rowElement,isImageCell){var cells=__aspxIE?rowElement.childNodes:rowElement.cells;if(isImageCell)
return cells.length==2?cells[0]:null;return cells.length==1?cells[0]:cells[1];},GetListTable:function(){if(!_aspxIsExistsElement(this.listTable))
this.listTable=_aspxGetElementById(this.name+__aspxLTableIdSuffix);return this.listTable;},GetListTableHeight:function(){return this.GetListTable().offsetHeight;},SetValue:function(value){var index=this.GetItemIndexByValue(value);this.SelectIndexSilent(index,false);},GetVerticalScrollBarWidth:function(){var divElement=this.GetScrollDivElement();var overflowYReserv=this.GetVerticalOverflow(divElement);this.SetVerticalOverflow(divElement,"auto");var borderWidthWithScroll=divElement.offsetWidth-divElement.clientWidth;if(__aspxIE7)return borderWidthWithScroll;this.SetVerticalOverflow(divElement,"hidden");var borderWidthWithoutScroll=divElement.offsetWidth-divElement.clientWidth;this.SetVerticalOverflow(divElement,overflowYReserv);return borderWidthWithScroll-borderWidthWithoutScroll;},GetVerticalOverflow:function(element){if(__aspxIE||__aspxSafari3||__aspxChrome)
return element.style.overflowY;return element.style.overflow;},SetVerticalOverflow:function(element,value){if(__aspxIE||__aspxSafari3||__aspxChrome)
element.style.overflowY=value;else
element.style.overflow=value;},OnItemClick:function(index){this.SelectIndex(index);this.EnsureSelectedItemVisible();this.SetFocus();},OnItemDblClick:function(){this.RaiseItemDoubleClick();},SelectIndexSilent:function(index,initialize){var selectedIndex=this.GetSelectedIndexInternal();var isValidIndex=(-1<=index&&index<this.GetItemCount());if((selectedIndex!=index&&isValidIndex&&!this.readOnly)||initialize){if(!initialize)
this.SetHoverElement(null);var itemSelection=this.GetItemTextCell(index);var itemSelected=this.GetItemTextCell(selectedIndex);var controller=aspxGetStateController();controller.DeselectElementBySrcElement(itemSelected);controller.SelectElementBySrcElement(itemSelection);this.SetSelectedIndexInternal(index);this.UpdateHiddenInputs(index);if(!initialize)
this.SetHoverElement(itemSelection);return true;}
return false;},ShowLoadingPanel:function(){if(!this.isComboBoxList){var loadingParentElement=this.GetScrollDivElement().parentNode;this.CreateLoadingDiv(loadingParentElement);this.CreateLoadingPanelWithAbsolutePosition(loadingParentElement);}},ParseCallbackResult:function(result){var gottenEgdeOfCollection=false;var nothingToLoad=result=="";var isLoadindToTopByScroll=this.scrollHelper.IsScrolledToTopSpacer();if(!nothingToLoad){var itemStrings=result.split(__aspxItemsSeparator);this.LoadItemsFromCallback(isLoadindToTopByScroll,itemStrings);gottenEgdeOfCollection=itemStrings.length!=this.callbackPageSize;}
var noMoreItemsForLoadThisDirection=nothingToLoad||gottenEgdeOfCollection;this.SetScrollSpacerVisibility(isLoadindToTopByScroll,!noMoreItemsForLoadThisDirection);this.scrollHelper.Reset();},LoadItemsFromCallback:function(isToTop,itemStrings){this.BeginUpdate();if(isToTop){var scrollHeightCorrection=0;for(var i=itemStrings.length-1;i>=0;i--){var itemStringAttrs=itemStrings[i].split(__aspxItemAttrsSeparator);this.InsertItem(0,itemStringAttrs[1],itemStringAttrs[0],itemStringAttrs[2]);scrollHeightCorrection+=this.GetItemHeight(0);}
this.GetScrollDivElement().scrollTop+=scrollHeightCorrection;this.serverIndexOfFirstItem-=itemStrings.length;if(this.serverIndexOfFirstItem<0)this.serverIndexOfFirstItem=0;}else{for(var i=0;i<itemStrings.length;i++){var itemStringAttrs=itemStrings[i].split(__aspxItemAttrsSeparator);this.AddItem(itemStringAttrs[1],itemStringAttrs[0],itemStringAttrs[2]);}}
if(this.changeSelectAfterCallback!=0){var newIndex=this.GetSelectedIndexInternal()+this.changeSelectAfterCallback;newIndex=this.GetAdjustedIndex(newIndex);this.SelectIndexSilent(newIndex,false);if(this.scrollHelper.isScrolledToTopSpacer)
this.ScrollItemToTop(newIndex);else
this.ScrollToItemVisible(newIndex);}
this.EndUpdate();},InCallback:function(){var callbackOwner=this.GetCallbackOwnerControl();if(callbackOwner!=null)
return callbackOwner.InCallback();return ASPxClientListEdit.prototype.InCallback.call(this);},GetItemsRangeForLoad:function(){return this.scrollHelper.GetItemsRangeForLoad();},GetScrollSpacerElement:function(isTop){return document.getElementById(this.name+(isTop?__aspxLBTSIdSuffix:__aspxLBBSIdSuffix));},GetScrollSpacerVisibility:function(isTop){return isTop?this.isTopSpacerVisible:this.isBottomSpacerVisible;},SetScrollSpacerVisibility:function(isTop,visibility){var spacer=this.GetScrollSpacerElement(isTop);if(_aspxIsExists(spacer)){if(visibility)
spacer.style.height=this.GetScrollDivElement().clientHeight+"px";if(isTop)
this.isTopSpacerVisible=visibility;else
this.isBottomSpacerVisible=visibility;if(_aspxGetElementDisplay(spacer)!=visibility){_aspxSetElementDisplay(spacer,visibility);_aspxGetElementVisibility(spacer,visibility);}}},SetTopScrollSpacerVisibility:function(visibility){this.SetScrollSpacerVisibility(true,visibility);},SetBottomScrollSpacerVisibility:function(visibility){this.SetScrollSpacerVisibility(false,visibility);},GetTopScrollSpacerHeight:function(){return this.isTopSpacerVisible?this.GetScrollSpacerElement(true).clientHeight:0;},GetBottomScrollSpacerHeight:function(){return this.isBottomSpacerVisible?this.GetScrollSpacerElement(false).clientHeight:0;},SendCallback:function(){if(!this.InCallback()){this.ShowLoadingPanel();var callbackOwner=this.GetCallbackOwnerControl();if(callbackOwner!=null)
callbackOwner.SendCallback();else{var argument=this.GetCallbackArguments();this.CreateCallback(argument);}}},OnCallback:function(result){this.ParseCallbackResult(result);this.OnCallbackFinally();},OnCallbackError:function(result){ASPxClientListBoxBase.prototype.OnCallbackError.call(this,result);this.OnCallbackFinally();},OnCallbackFinally:function(){this.HideLoadingPanel();this.changeSelectAfterCallback=0;},LockScrollHandler:function(){this.scrollHandlerLockCount++;},UnlockScrollHandler:function(){this.scrollHandlerLockCount--;},IsScrollHandlerLocked:function(){return this.scrollHandlerLockCount>0;},OnScroll:function(){if(this.IsScrollHandlerLocked())return;if(!this.InCallback()&&(this.isTopSpacerVisible||this.isBottomSpacerVisible)){this.scrollHelper.OnScroll();if(this.scrollHelper.GetIsNeedToHideTopSpacer())
this.SetTopScrollSpacerVisibility(false);if(this.scrollHelper.GetIsNeedCallback())
this.SendCallback();}},InitializeKeyHandlers:function(){this.AddKeyDownHandler(ASPxKey.PageUp,"OnPageUp");this.AddKeyDownHandler(ASPxKey.PageDown,"OnPageDown");this.AddKeyDownHandler(ASPxKey.End,"OnEndKeyDown");this.AddKeyDownHandler(ASPxKey.Home,"OnHomeKeyDown");this.AddKeyDownHandler(ASPxKey.Up,"OnArrowUp");this.AddKeyDownHandler(ASPxKey.Down,"OnArrowDown");},OnArrowUp:function(evt){this.SelectNeighbour(-1);return true;},OnArrowDown:function(evt){this.SelectNeighbour(1);return true;},OnPageUp:function(evt){this.SelectNeighbour(-this.scrollPageSize);return true;},OnPageDown:function(evt){this.SelectNeighbour(this.scrollPageSize);return true;},OnHomeKeyDown:function(evt){this.SelectNeighbour(-this.GetItemCount());return true;},OnEndKeyDown:function(evt){this.SelectNeighbour(this.GetItemCount());return true;},GetAdjustedIndex:function(index){if(index<0)index=0;else{var itemCount=this.GetItemCount();if(index>=itemCount)index=itemCount-1;}
return index;},SelectNeighbour:function(step){var itemCount=this.GetItemCount();if(itemCount>0){this.changeSelectAfterCallback=0;var selectedIndex=this.GetSelectedIndexInternal();var isFirstPageDown=selectedIndex==-1&&step==this.scrollPageSize;selectedIndex=isFirstPageDown?step:selectedIndex+step;selectedIndex=this.GetAdjustedIndex(selectedIndex);this.SelectIndex(selectedIndex);if(this.GetIsNeedToCallbackLoadItemsToTop(selectedIndex,step,itemCount)){this.LoadItemsOnCallback(true,selectedIndex);}else if(this.GetIsNeedToCallbackLoadItemsToBottom(selectedIndex,step,itemCount)){this.LoadItemsOnCallback(false,selectedIndex);}
this.ScrollToItemVisible(selectedIndex);}},GetIsNeedToCallbackLoadItemsToTop:function(selectedIndex,step,itemCount){return this.isCallbackMode&&this.isTopSpacerVisible&&this.serverIndexOfFirstItem>0&&((step<0&&selectedIndex<=0)||step<=-itemCount);},GetIsNeedToCallbackLoadItemsToBottom:function(selectedIndex,step,itemCount){return this.isCallbackMode&&this.isBottomSpacerVisible&&((step>0&&selectedIndex>=itemCount-1)||step>=itemCount);},LoadItemsOnCallback:function(isToTop,index){this.changeSelectAfterCallback=index-this.GetSelectedIndexInternal();this.scrollHelper.SetItemsRangeForLoad(isToTop);this.SendCallback();},FindInputElement:function(){return document.getElementById(this.name+"_KBS");},SetHoverElement:function(element){aspxGetStateController().SetCurrentHoverElementBySrcElement(element);},InitOnContainerMadeVisible:function(){this.AdjustControl(false);},SetSelectedIndex:function(index){if(index!=this.GetSelectedIndexInternal())
this.SelectIndexSilent(index,false);},ClearItemsCore:function(){this.ClearListTableContent();this.SetSelectedIndexInternal(-1);this.SetValue(null);},RemoveItem:function(index){if(0<=index&&index<this.GetItemCount()){this.UpdateSyncArraysItemDeleted(this.GetItem(index),true);var row=this.GetItemRow(index);if(_aspxIsExistsElement(row))
row.parentNode.removeChild(row);var selectedIndex=this.GetSelectedIndexInternal();if(index<selectedIndex)
this.SetSelectedIndexInternal(selectedIndex-1);else if(index==selectedIndex)
this.SetSelectedIndexInternal(-1);}},GetItem:function(index){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 text=_aspxGetInnerText(textCell);text=text.replace(new RegExp(String.fromCharCode(160),"g")," ");var src=image==null?"":ASPxImageUtils.GetImageSrc(image);return new ASPxClientListEditItem(this,index,text,this.itemsValue[index],src);}}
return null;},PerformCallback:function(arg){this.SetScrollSpacerVisibility(true,false);this.SetScrollSpacerVisibility(false,false);this.ClearItemsForPerformCallback();this.serverIndexOfFirstItem=0;this.SetScrollSpacerVisibility(true,false);this.SetScrollSpacerVisibility(false,false);this.FormatAndSetCustomCallbackArg(arg);this.SendCallback();},GetTableRowParent:function(table){if(table.tBodies.length>0)
return table.tBodies[0];return table;},ProtectWhitespaceSerieses:function(text){if(_aspxIsExists(text)){if(text==""||text==" ")
text=__aspxNbsp;else{if(text.charAt(0)==' ')
text=__aspxNbsp+text.slice(1);if(text.charAt(text.length-1)==' ')
text=text.slice(0,-1)+__aspxNbsp;text=text.replace(new RegExp("  ","g")," &nbsp;");}}
return text;},InsertItemInternal:function(index,text,value,imageUrl){if(!_aspxIsExists(imageUrl))
imageUrl="";if(!_aspxIsExists(value))
value=text;var renderText=this.ProtectWhitespaceSerieses(text);var newItemRow=this.CreateNewItem();_aspxRemoveAttribute(newItemRow,"id");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));_aspxRemoveAttribute(sampleCellElement,__aspxCachedHoverItemKind);_aspxRemoveAttribute(sampleCellElement,__aspxCachedSelectedItemKind);this.PrepareItem(newItemRow,renderText,imageUrl);this.AddItemClass(index,text,value,imageUrl);var selectedIndex=this.GetSelectedIndexInternal();if(index<=selectedIndex&&selectedIndex!=-1){this.SetSelectedIndexInternal(selectedIndex+1);}},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);}
ASPxImageUtils.SetImageSrc(image,imageUrl);newItemRow.cells[1].innerHTML=text;}else
newItemRow.cells[0].innerHTML=text;},ClearListTableContent:function(){var tBody=this.GetTableRowParent(this.GetListTable());if(__aspxIE)
tBody.innerText="";else
tBody.innerHTML="";},CreateItemId:function(index){return __aspxLBIIdSuffix+index;},CreateItemClientId:function(index){return this.name+"_"+__aspxLBIIdSuffix+index;},CreateNewItem:function(){var newItemRow=this.GetSampleItem();if(_aspxIsExistsElement(newItemRow))
newItemRow=newItemRow.cloneNode(true);return newItemRow;},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;},CorrectSizeByTimer:function(){if(this.APILockCount==0&&this.IsDisplayed())
_aspxSetTimeout("aspxLBCorrectSizeByTimer(\""+this.name+"\");",0);},FindFreeIndex:function(){return this.freeUniqIndex++;},GetSampleItemID:function(){return this.name+"_"+__aspxLBSIIdSuffix;},GetSampleItem:function(){if(this.SampleItem==null)
this.SampleItem=_aspxGetElementById(this.GetSampleItemID());return this.SampleItem;},GetSampleItemTextCell:function(){if(!_aspxIsExistsElement(this.sampleItemTextCell))
this.sampleItemTextCell=_aspxGetElementById(this.GetSampleItemID()+__aspxLBIPostfixes[1]);return this.sampleItemTextCell;},ChangeEnabledAttributes:function(enabled){this.ChangeListTableEvents(this.GetListTable(),_aspxChangeEventsMethod(enabled));var inputElement=this.GetInputElement();if(_aspxIsExists(inputElement))
this.ChangeSpecialInputEnabledAttributes(inputElement,_aspxChangeEventsMethod(enabled));},ChangeEnabledStateItems:function(enabled){var controller=aspxGetStateController();controller.SetElementEnabled(this.GetMainElement(),enabled);var count=this.GetItemCount();var i=this.hasSampleItem?-1:0;for(;i<count;i++){var element=this.GetItemTextCell(i);if(_aspxIsExists(element))
controller.SetElementEnabled(element,enabled);}},ChangeListTableEvents:function(listTable,method){if(this.isComboBoxList){method(listTable,"mouseup",aspxLBIClick);if(__aspxFirefox)
method(listTable,"mousedown",_aspxPreventEvent);}
else{method(listTable,"click",aspxLBIClick);method(listTable,"dblclick",aspxLBIClick);}}});ASPxClientNativeListBox=_aspxCreateClass(ASPxClientListBoxBase,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);},SetMainElement:function(mainElement){this.mainElement=mainElement;},FindInputElement:function(){return this.GetMainElement();},GetOptionCount:function(){return this.GetMainElement().options.length;},GetOption:function(index){return this.GetMainElement().options[index];},GetItemCount:function(){return this.GetOptionCount();},SelectIndexSilent:function(index,initialize){var selectedIndex=this.GetSelectedIndexInternal();var isValidIndex=(-1<=index&&index<this.GetItemCount());if((selectedIndex!=index&&isValidIndex)||initialize){this.SetSelectedIndexInternal(index);return true;}
return false;},GetSelectedIndexInternal:function(){return this.GetMainElement().selectedIndex;},SetSelectedIndexInternal:function(index){this.GetMainElement().selectedIndex=index;},ClearItemsCore:function(){this.GetMainElement().innerHTML="";},RemoveItem:function(index){if(0<=index&&index<this.GetItemCount()){var oldSelectedIndex=this.GetSelectedIndexInternal();this.UpdateSyncArraysItemDeleted(this.GetItem(index),true);var option=this.GetOption(index);this.GetMainElement().removeChild(option);this.UpdateOptionValues();if(index==oldSelectedIndex)
this.SetSelectedIndexInternal(-1);}},GetItem:function(index){if(0<=index&&index<this.GetOptionCount()){var text=this.GetOption(index).text;if(_aspxIsExists(text))
return new ASPxClientListEditItem(this,index,text,this.itemsValue[index],"");}
return null;},PerformCallback:function(arg){this.ClearItemsForPerformCallback();this.FormatAndSetCustomCallbackArg(arg);this.SendCallback();},SendCallback:function(){if(!this.InCallback()){var callbackOwner=this.GetCallbackOwnerControl();if(callbackOwner!=null)
callbackOwner.SendCallback();else{var argument=this.GetCallbackArguments();this.CreateCallback(argument);}}},ParseCallbackResult:function(result){var itemStrings=result.split(__aspxItemsSeparator);this.LoadItemsFromCallback(true,itemStrings);},InsertItemInternal:function(index,text,value,imageUrl){if(!_aspxIsExists(value))
value=text;var oldSelectedIndex=this.GetSelectedIndexInternal();var isAdd=this.GetOptionCount()<=index;var newOption=document.createElement("OPTION");if(isAdd)
this.GetMainElement().appendChild(newOption);else
this.GetMainElement().insertBefore(newOption,this.GetOption(index));newOption.innerHTML=text;this.UpdateOptionValues();this.AddItemClass(index,text,value,imageUrl);if(index==oldSelectedIndex&&index!=-1)
this.SetSelectedIndex(index+1);},UpdateOptionValues:function(){for(var i=0;i<this.GetOptionCount();i++)
this.GetOption(i).value=i;},ChangeEnabledAttributes:function(enabled){if(!this.isComboBoxList)
this.GetMainElement().disabled=!enabled;},OnCallback:function(result){this.ParseCallbackResult(result);},LoadItemsFromCallback:function(isToTop,itemStrings){this.BeginUpdate();for(var i=itemStrings.length-1;i>=0;i--){var itemStringAttrs=itemStrings[i].split(__aspxItemAttrsSeparator);this.InsertItem(0,itemStringAttrs[1],itemStringAttrs[0],itemStringAttrs[2]);}
this.EndUpdate();}});ASPxClientRadioButtonList=_aspxCreateClass(ASPxClientListEdit,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.items=[];this.itemCount=0;},InlineInitialize:function(){var selectedIndex=this.GetSelectedIndex();this.UpdateHiddenInputs(selectedIndex);},SetFocus:function(){var index=this.GetSelectedIndexInternal();if(index==-1)
index=0;var itemElement=this.GetItemElement(index);if(itemElement!=null&&_aspxGetActiveElement()!=itemElement&&_aspxIsEditorFocusable(itemElement))
_aspxSetFocus(itemElement);},GetInputElement:function(){var index=this.GetSelectedIndexInternal();return this.GetItemElement(index);},GetValueInputElement:function(){if(this.valueInput==null){this.valueInput=_aspxCreateHiddenField(null,this.name+"_ValueInput");var stateInput=this.FindStateInputElement();stateInput.parentNode.insertBefore(this.valueInput,stateInput);}
return this.valueInput;},GetValueInputToValidate:function(){return this.GetValueInputElement();},GetItemElement:function(index){return this.GetChild("_RB"+index+"_I");},GetItemMainElement:function(index){return this.GetChild("_RB"+index);},GetItemCount:function(){return this.items.length;},OnItemClick:function(index){if(this.GetSelectedIndexInternal()!=index){this.SelectIndexSilent(index);this.RaisePersonalStandardValidation();this.OnValueChanged();}},OnItemClickReadonly:function(){var index=this.GetSelectedIndexInternal();this.SelectIndexSilent(index);},UpdateHiddenInputs:function(index){var stateInput=this.FindStateInputElement();if(_aspxIsExistsElement(stateInput))
stateInput.value=index;var valueInput=this.GetValueInputElement();if(_aspxIsExistsElement(valueInput)){var value=this.GetValue();valueInput.value=_aspxIsExists(value)?value:" ";}},SelectIndexSilent:function(index){var itemCount=(this.items.length>0)?this.items.length:this.itemCount;var isValidIndex=(-1<=index&&index<itemCount);if(isValidIndex){for(var i=0;i<itemCount;i++){if(_aspxIsExists(this.GetItemElement(i)))
this.GetItemElement(i).checked=(i==index);}
this.SetSelectedIndexInternal(index);this.UpdateHiddenInputs(index);}},GetItemValue:function(index){if(index>-1&&index<this.items.length){if(typeof(this.items[index].value)=="string"&&this.items[index].value==""&&this.convertEmptyStringToNull)
return null;else
return this.items[index].value;}
return null;},SetValue:function(value){for(var i=0;i<this.items.length;i++){if(this.GetItemValue(i)==value){this.SelectIndexSilent(i);return;}}
this.SelectIndexSilent(-1);},CreateItems:function(itemsProperties){for(var i=0;i<itemsProperties.length;i++)
this.CreateItem(i,itemsProperties[i][0],itemsProperties[i][1],itemsProperties[i][2]);},CreateItem:function(index,text,value,imageUrl){var item=new ASPxClientListEditItem(this,index,text,value,imageUrl);_aspxArrayPush(this.items,item);},GetItem:function(index){return(0<=index&&index<this.items.length)?this.items[index]:null;},ChangeEnabledAttributes:function(enabled){for(var i=0;i<this.GetItemCount();i++){var element=this.GetItemElement(i);if(_aspxIsExists(element)){this.ChangeItemEnabledAttributes(element,_aspxChangeAttributesMethod(enabled));element.disabled=!enabled;}}},ChangeEnabledStateItems:function(enabled){aspxGetStateController().SetElementEnabled(this.GetMainElement(),enabled);for(var i=0;i<this.GetItemCount();i++){var element=this.GetItemMainElement(i);if(_aspxIsExists(element))
aspxGetStateController().SetElementEnabled(element,enabled);}},ChangeItemEnabledAttributes:function(element,method){method(element,"onclick");}});function aspxLBIClick(evt){var element=_aspxGetEventSource(evt);while(element!=null&&element.tagName!="BODY"){if(element.tagName=="TR"){var table=element.offsetParent;if(_aspxIsExists(table)&&_aspxIsExists(table.ListBoxId)){var lb=aspxGetControlCollection().Get(table.ListBoxId);if(lb!=null){if(evt.type=="dblclick")lb.OnItemDblClick();else if(!lb.isComboBoxList||_aspxGetIsLeftButtonPressed(evt))
lb.OnItemClick(element.rowIndex);}
break;}}
element=element.parentNode;}}
function aspxLBScroll(evt){var sourceId=_aspxGetEventSource(evt).id;if(sourceId.slice(-__aspxLBDSuffix.length)==__aspxLBDSuffix){var name=sourceId.slice(0,-2);var lb=aspxGetControlCollection().Get(name);if(lb!=null)
lb.OnScroll();}}
function aspxLBCorrectSizeByTimer(name){var lb=aspxGetControlCollection().Get(name);if(lb!=null)
lb.CorrectSizeInternalByTimer();}
function aspxERBLIClick(name,index){var list=aspxGetControlCollection().Get(name);if(list!=null)
list.OnItemClick(index);}
function aspxERBLICancel(name){var list=aspxGetControlCollection().Get(name);if(list!=null)
list.OnItemClickReadonly();}
ASPxClientCheckBox=_aspxCreateClass(ASPxClientEdit,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.stateInput=null;this.valueChecked=true;this.valueUnchecked=false;this.CheckedChanged=new ASPxClientEvent();},Initialize:function(){ASPxClientEdit.prototype.Initialize.call(this);this.previousChecked=this.GetInputElement().checked;},FindInputElement:function(){var element=this.GetMainElement();if(_aspxIsExistsElement(element)&&element.tagName!="INPUT")
element=this.GetChild("_I");return element;},GetStateInput:function(){if(!_aspxIsExistsElement(this.stateInput))
this.stateInput=this.GetChild("_S");return this.stateInput;},RaiseValueChangedEvent:function(){var processOnServer=ASPxClientEdit.prototype.RaiseValueChangedEvent.call(this);processOnServer=this.RaiseCheckedChanged(processOnServer);return processOnServer;},OnClick:function(){var value=this.previousChecked?this.valueUnchecked:this.valueChecked;this.SetValue(value);this.OnValueChanged();},GetValue:function(){var value;switch(this.GetStateInput().value){case"N":return null;case"C":value=this.valueChecked;break;case"U":value=this.valueUnchecked;break;}
if(value===""&&this.convertEmptyStringToNull)
value=null;return value;},SetValue:function(value){var stateInput=this.GetStateInput();if(value==null)
stateInput.value="N";else
stateInput.value=value==this.valueChecked?"C":"U";this.GetInputElement().checked=this.previousChecked=value==this.valueChecked;},RaiseCheckedChanged:function(processOnServer){if(!this.CheckedChanged.IsEmpty()){var args=new ASPxClientProcessingModeEventArgs(processOnServer);this.CheckedChanged.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;},GetChecked:function(){return this.GetValue()==this.valueChecked;},SetChecked:function(isChecked){this.SetValue(isChecked?this.valueChecked:this.valueUnchecked);},ChangeEnabledAttributes:function(enabled){this.ChangeInputEnabledAttributes(this.GetInputElement(),_aspxChangeAttributesMethod(enabled));this.GetInputElement().disabled=!enabled;},ChangeEnabledStateItems:function(enabled){aspxGetStateController().SetElementEnabled(this.GetMainElement(),enabled);},ChangeInputEnabledAttributes:function(element,method){method(element,"onclick");}});ASPxClientRadioButton=_aspxCreateClass(ASPxClientCheckBox,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.isASPxClientRadioButton=true;},OnClick:function(){if(!this.previousChecked){var members=this.GetGroupMembers();for(var i=0;i<members.length;i++){var radioButton=members[i];if(radioButton!=this&&radioButton.GetValue()){radioButton.SetValue(false);radioButton.RaiseValueChangedEvent();}}
ASPxClientCheckBox.prototype.OnClick.call(this);}},OnReadonlyClick:function(){if(!this.previousChecked){var members=this.GetGroupMembers();for(var i=0;i<members.length;i++){var radioButton=members[i];radioButton.SetValue(radioButton.GetValue());}}},GetGroupName:function(){var inputElement=this.GetInputElement();if(!_aspxIsExistsElement(inputElement))
return null;var name=inputElement.name;if(!name.length)
name="";return name;},GetGroupMembers:function(){var result=[];var groupName=this.GetGroupName();if(groupName.length>0){var collection=aspxGetControlCollection();var control;for(var i in collection.elements){control=collection.elements[i];if(ASPxIdent.IsASPxClientRadioButton(control)){var controlGroupName=control.GetGroupName();if(controlGroupName!=null&&controlGroupName==groupName)
result.push(control);}}}else{result.push(this);}
return result;},GetChecked:function(){return this.GetValue()==true;},SetChecked:function(isChecked){this.SetValue(isChecked);}});ASPxIdent.IsASPxClientRadioButton=function(obj){return _aspxIsExists(obj.isASPxClientRadioButton)&&obj.isASPxClientRadioButton;};function aspxChkOnClick(name){var edit=aspxGetControlCollection().Get(name);if(_aspxIsExists(edit))
edit.OnClick();}
function aspxERBOnReadonlyClick(name){var rb=aspxGetControlCollection().Get(name);if(_aspxIsExists(rb))
rb.OnReadonlyClick();}
var __aspxTEInputSuffix="_I";ASPxClientTextEdit=_aspxCreateClass(ASPxClientEdit,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.raiseValueChangedOnEnter=true;this.savedValueChangedText="";this.TextChanged=new ASPxClientEvent();},Initialize:function(){ASPxClientEdit.prototype.Initialize.call(this);var element=this.GetInputElement();if(_aspxIsExists(element))
this.savedValueChangedText=element.value;},FindInputElement:function(){return this.isNative?this.GetMainElement():_aspxGetElementById(this.name+__aspxTEInputSuffix);},GetValue:function(){var input=this.GetInputElement();return(input.value==""&&this.convertEmptyStringToNull)?null:input.value;},SetValue:function(value){if(value==null)value="";var element=this.GetInputElement();if(_aspxIsExistsElement(element)){element.value=value;this.savedValueChangedText=value;}},CollapseControl:function(checkSizeCorrectedFlag){if(checkSizeCorrectedFlag&&this.sizeCorrectedOnce)
return;var mainElement=this.GetMainElement();if(!_aspxIsExistsElement(mainElement))
return;var mainElementCurStyle=_aspxGetCurrentStyle(mainElement);if(_aspxIsExistsElement(mainElement)&&this.widthCorrectionRequired&&mainElementCurStyle.width!=""&&mainElementCurStyle.width!="auto")
this.GetInputElement().style.width="0";},CorrectEditorWidth:function(){var inputElement=this.GetInputElement();_aspxSetOffsetWidth(inputElement,_aspxGetClearClientWidth(_aspxFindOffsetParent(inputElement)));},UnstretchInputElement:function(){var inputElement=this.GetInputElement();var mainElement=this.GetMainElement();var mainElementCurStyle=_aspxGetCurrentStyle(mainElement);if(_aspxIsExistsElement(mainElement)&&_aspxIsExistsElement(inputElement)&&inputElement.style.width=="100%"&&(mainElementCurStyle.width==""||mainElementCurStyle.width=="auto"))
inputElement.style.width="";},OnValueChanged:function(){var element=this.GetInputElement();if(_aspxIsExists(element)&&this.savedValueChangedText!=element.value){ASPxClientEdit.prototype.OnValueChanged.call(this);this.savedValueChangedText=element.value;}},RaiseValueChangedEvent:function(){var processOnServer=ASPxClientEdit.prototype.RaiseValueChangedEvent.call(this);processOnServer=this.RaiseTextChanged(processOnServer);return processOnServer;},OnKeyDown:function(evt){ASPxClientEdit.prototype.OnKeyDown.call(this,evt);if(!this.specialKeyboardHandlingUsed&&this.raiseValueChangedOnEnter&&evt.keyCode==ASPxKey.Enter){var element=this.GetInputElement();if(_aspxIsExists(element)&&_aspxIsExists(element.onchange)){element.onchange();return true;}}},RaiseTextChanged:function(processOnServer){if(!this.TextChanged.IsEmpty()){var args=new ASPxClientProcessingModeEventArgs(processOnServer);this.TextChanged.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;},GetText:function(){var value=this.GetValue();return value!=null?value:"";},SetText:function(value){this.SetValue(value);},SelectAll:function(){this.SetSelection(0,-1,false);},SetCaretPosition:function(pos){var inputElement=this.GetInputElement();_aspxSetCaretPosition(inputElement,pos);},SetSelection:function(startPos,endPos,scrollToSelection){var inputElement=this.GetInputElement();_aspxSetSelection(inputElement,startPos,endPos,scrollToSelection);},ChangeEnabledAttributes:function(enabled){if(this.isNative)
this.GetMainElement().disabled=!enabled;var inputElement=this.GetInputElement();if(_aspxIsExists(inputElement)){this.ChangeInputEnabledAttributes(inputElement,_aspxChangeAttributesMethod(enabled),enabled);if(this.specialKeyboardHandlingUsed)
this.ChangeSpecialInputEnabledAttributes(inputElement,_aspxChangeEventsMethod(enabled));if(!this.isNative)
this.ChangeReadOnlyAttribute(inputElement,enabled);}},ChangeEnabledStateItems:function(enabled){if(!this.isNative)
aspxGetStateController().SetElementEnabled(this.GetMainElement(),enabled);},ChangeReadOnlyAttribute:function(element,enabled){element.readOnly=!enabled||this.readOnly;},ChangeInputEnabledAttributes:function(element,method,enabled){method(element,"tabIndex");if(!enabled)element.tabIndex=-1;method(element,"onclick");method(element,"onfocus");method(element,"onblur");method(element,"onkeydown");method(element,"onkeypress");method(element,"onkeyup");}});ASPxClientTextBoxBase=_aspxCreateClass(ASPxClientTextEdit,{});ASPxClientTextBox=_aspxCreateClass(ASPxClientTextBoxBase,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.isASPxClientTextBox=true;}});ASPxIdent.IsASPxClientTextBox=function(obj){return _aspxIsExists(obj.isASPxClientTextBox)&&obj.isASPxClientTextBox;};var __aspxMMinHeight=34;ASPxClientMemo=_aspxCreateClass(ASPxClientTextEdit,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.isASPxClientMemo=true;this.raiseValueChangedOnEnter=false;},CollapseControl:function(checkSizeCorrectedFlag){if(checkSizeCorrectedFlag&&this.sizeCorrectedOnce)
return;var mainElement=this.GetMainElement();var inputElement=this.GetInputElement();if(!_aspxIsExistsElement(mainElement)||!_aspxIsExistsElement(inputElement))
return;ASPxClientTextEdit.prototype.CollapseControl.call(this,checkSizeCorrectedFlag);var mainElementCurStyle=_aspxGetCurrentStyle(mainElement);if(this.heightCorrectionRequired&&_aspxIsExists(mainElement)&&_aspxIsExists(inputElement)){if(mainElement.style.height=="100%"||mainElementCurStyle.height=="100%"){mainElement.style.height="0";mainElement.wasCollapsed=true;}
inputElement.style.height="0";}},CorrectEditorHeight:function(){var mainElement=this.GetMainElement();if(mainElement.wasCollapsed){mainElement.wasCollapsed=null;_aspxSetOffsetHeight(mainElement,_aspxGetClearClientHeight(_aspxFindOffsetParent(mainElement)));}
if(!this.isNative){var inputElement=this.GetInputElement();var inputClearClientHeight=_aspxGetClearClientHeight(_aspxFindOffsetParent(inputElement))-2;if(__aspxIE){var calculatedMainElementStyle=_aspxGetCurrentStyle(mainElement);inputClearClientHeight+=_aspxPxToInt(calculatedMainElementStyle.borderTopWidth)+_aspxPxToInt(calculatedMainElementStyle.borderBottomWidth);}
if(inputClearClientHeight<__aspxMMinHeight)
inputClearClientHeight=__aspxMMinHeight;_aspxSetOffsetHeight(inputElement,inputClearClientHeight);mainElement.style.height="100%";}}});ASPxIdent.IsASPxClientMemo=function(obj){return _aspxIsExists(obj.isASPxClientMemo)&&obj.isASPxClientMemo;};ASPxClientButtonEditBase=_aspxCreateClass(ASPxClientTextBoxBase,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.allowUserInput=true;this.buttonCount=0;this.ButtonClick=new ASPxClientEvent();},GetButton:function(number){return this.GetChild("_B"+number);},ProcessInternalButtonClick:function(number){return false;},OnButtonClick:function(number){var processOnServer=this.RaiseButtonClick(number);if(!this.ProcessInternalButtonClick(number)&&processOnServer)
this.SendPostBack('BC:'+number);},SelectInputElement:function(){var element=this.GetInputElement();if(_aspxIsExistsElement(element)){_aspxSetFocus(element);element.select();}},RaiseButtonClick:function(number){var processOnServer=this.autoPostBack||this.IsServerEventAssigned("ButtonClick");if(!this.ButtonClick.IsEmpty()){var args=new ASPxClientButtonEditClickEventArgs(processOnServer,number);this.ButtonClick.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;},ChangeEnabledAttributes:function(enabled){ASPxClientTextEdit.prototype.ChangeEnabledAttributes.call(this,enabled);for(var i=0;i<this.buttonCount;i++){var element=this.GetButton(i);if(_aspxIsExists(element))
this.ChangeButtonEnabledAttributes(element,_aspxChangeAttributesMethod(enabled));}},ChangeEnabledStateItems:function(enabled){ASPxClientTextEdit.prototype.ChangeEnabledStateItems.call(this,enabled);for(var i=0;i<this.buttonCount;i++){var element=this.GetButton(i);if(_aspxIsExists(element))
aspxGetStateController().SetElementEnabled(element,enabled);}},ChangeButtonEnabledAttributes:function(element,method){method(element,"onclick");method(element,"ondblclick");method(element,"onmousedown");method(element,"onmouseup");},ChangeReadOnlyAttribute:function(element,enabled){if(this.allowUserInput)
ASPxClientTextEdit.prototype.ChangeReadOnlyAttribute.call(this,element,enabled);}});ASPxClientButtonEdit=_aspxCreateClass(ASPxClientButtonEditBase,{});ASPxClientButtonEditClickEventArgs=_aspxCreateClass(ASPxClientProcessingModeEventArgs,{constructor:function(processOnServer,buttonIndex){this.constructor.prototype.constructor.call(this,processOnServer);this.buttonIndex=buttonIndex;}});function aspxETextChanged(name){var edit=aspxGetControlCollection().Get(name);if(edit!=null)edit.OnTextChanged();}
function aspxBEClick(name,number){var edit=aspxGetControlCollection().Get(name);if(edit!=null)edit.OnButtonClick(number);}
function _aspxSetFocusToTextEditWithDelay(name){_aspxSetTimeout("var edit = aspxGetControlCollection().Get('"+name+"'); __aspxIE ? edit.SetCaretPosition(0) : edit.SetFocus();",500);}
var __aspxLoadFilteredItemsCallbackPrefix="CBLF";var __aspxCorrectFilterCallbackPrefix="CBCF";var __aspxDropDownNameSuffix="_DDD";var __aspxCalendarNameSuffix="_C";var __aspxListBoxNameSuffix="_L";ASPxClientDropDownEdit=_aspxCreateClass(ASPxClientButtonEditBase,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.DropDown=new ASPxClientEvent();this.CloseUp=new ASPxClientEvent();this.ddHeightCache=__aspxInvalidDimension;this.ddWidthCache=__aspxInvalidDimension;this.mainElementWidthCache=__aspxInvalidDimension;this.dropDownButtonIndex=-1;this.droppedDown=false;this.ddButtonPushed=false;this.lastSuccessText="";aspxGetDropDownCollection().Add(this);},Initialize:function(){var pc=this.GetPopupControl();if(_aspxIsExists(pc))
pc.allowCorrectYOffsetPosition=false;this.AssignClientAttributes();this.InitLastSuccessText();ASPxClientEdit.prototype.Initialize.call(this);},InitLastSuccessText:function(){var input=this.GetInputElement();if(_aspxIsExistsElement(input))
this.SetLastSuccessTest(input.value);},IsRenderExists:function(){return _aspxIsExistsElement(this.GetMainElement());},AssignClientAttributes:function(){var element=this.GetDropDownButton();if(_aspxIsExistsElement(element))
_aspxPreventElementDragAndSelect(element,true);},GetDropDownButton:function(){return this.GetButton(this.dropDownButtonIndex);},GetPopupControl:function(){return aspxGetControlCollection().Get(this.name+__aspxDropDownNameSuffix);},GetDropDownInnerControlName:function(suffix){var pc=this.GetPopupControl();if(_aspxIsExists(pc))
return this.GetPopupControl().name+suffix;return"";},GetIsControlWidthWasChanged:function(){return this.mainElementWidthCache==__aspxInvalidDimension||this.mainElementWidthCache!=this.GetMainElement().clientWidth;},GetDropDownHeight:function(){return 0;},GetDropDownWidth:function(){return 0;},ShowDropDownArea:function(isRaiseEvent){aspxGetDropDownCollection().RegisterDroppedDownControl(this);this.lockListBoxClick=true;var pc=this.GetPopupControl();var element=this.GetMainElement();var pcwElement=pc.GetWindowElement(-1);_aspxSetElementDisplay(pcwElement,true);var height=this.GetDropDownHeight();var width=this.GetDropDownWidth();if(this.ddHeightCache!=height||this.ddWidthCache!=width){pc.SetSize(width,height);this.ddHeightCache=height;this.ddWidthCache=width;}
pc.popupVerticalOffset=-_aspxGetClientTop(element);pc.ShowAtElement(element);if(isRaiseEvent)
this.RaiseDropDown();this.droppedDown=true;},HideDropDownArea:function(isRaiseEvent){this.DropDownButtonPop();var pc=this.GetPopupControl();if(_aspxIsExists(pc)){pc.Hide();if(isRaiseEvent)
this.RaiseCloseUp();aspxGetDropDownCollection().UnregisterDroppedDownControl(this);this.droppedDown=false;}},ProcessInternalButtonClick:function(number){return this.dropDownButtonIndex==number;},ToggleDropDown:function(){this.OnApplyChanges();if(this.droppedDown)
this.HideDropDownArea(true);else
this.ShowDropDownArea(true);},SetTextInternal:function(text){if(!this.readOnly)
ASPxClientButtonEditBase.prototype.SetValue.call(this,text);},SetLastSuccessTest:function(text){if(text==null)text="";this.lastSuccessText=text;},OnValueChanged:function(){this.SetLastSuccessTest(this.GetInputElement().value);ASPxClientEdit.prototype.OnValueChanged.call(this);},OnApplyChanges:function(){},OnCancelChanges:function(){var isCancelProcessed=(this.GetInputElement().value!=this.lastSuccessText);this.SetTextInternal(this.lastSuccessText);return isCancelProcessed;},OnFocus:function(){this.OnSetFocus(true);ASPxClientButtonEditBase.prototype.OnFocus.call(this);},OnLostFocus:function(){this.OnSetFocus(false);ASPxClientButtonEditBase.prototype.OnLostFocus.call(this);},OnSetFocus:function(isFocused){aspxGetDropDownCollection().SetFocusedDropDownName(isFocused?this.name:"");},LockFocusEventsByMouseDown:function(srcElement){if(!__aspxNS&&srcElement!=this.GetInputElement()&&srcElement!=this.GetDropDownButton())
this.LockFocusEvents();},OnClick:function(){this.SetFocus();},IsCanToDropDown:function(){return true;},OnDropDown:function(evt){if(!this.IsCanToDropDown())return true;if(!__aspxNS)
this.LockFocusEvents();this.SetFocus();if(!this.droppedDown)
this.DropDownButtonPush();this.ToggleDropDown();return _aspxCancelBubble(evt);},DropDownButtonPush:function(){if(this.droppedDown||this.ddButtonPushed)return;this.ddButtonPushed=true;if(__aspxIE||__aspxOpera)
this.DropDownButtonPushPop(true);else
this.DropDownButtonPushMozilla();},DropDownButtonPop:function(){if(!this.droppedDown||!this.ddButtonPushed)return;this.ddButtonPushed=false;if(__aspxIE||__aspxOpera)
this.DropDownButtonPushPop(false);else
this.DropDownButtonPopMozilla();},DropDownButtonPushPop:function(isPush){var buttonElement=this.GetDropDownButton();if(_aspxIsExists(buttonElement)){var controller=aspxGetStateController();var element=controller.GetPressedElement(buttonElement);if(_aspxIsExists(element)){if(isPush){controller.SetCurrentHoverElement(null);controller.DoSetPressedState(element);}else{controller.DoClearPressedState(element);controller.SetCurrentPressedElement(null);controller.SetCurrentHoverElement(element);}}}},DropDownButtonPushMozilla:function(){this.DisableStyleControllerForDDButton();var controller=aspxGetStateController();controller.savedCurrentPressedElement=null;},DropDownButtonPopMozilla:function(){this.EnableStyleControllerForDDButton();var controller=aspxGetStateController();var buttonElement=this.GetDropDownButton();if(_aspxIsExists(buttonElement)){var element=controller.GetPressedElement(buttonElement);if(_aspxIsExists(element))
controller.DoClearPressedState(element);controller.currentPressedElement=null;element=controller.GetHoverElement(buttonElement);if(_aspxIsExists(element))
controller.SetCurrentHoverElement(element);}},EnableStyleControllerForDDButton:function(){var element=this.GetDropDownButton();if(_aspxIsExists(element)){var controller=aspxGetStateController();this.ReplaceElementControlStyleItem(controller.hoverItems,element,this.ddButtonHoverStyle);this.ReplaceElementControlStyleItem(controller.pressedItems,element,this.ddButtonPressedStyle);this.ReplaceElementControlStyleItem(controller.selectedItems,element,this.ddButtonSelectedStyle);}},DisableStyleControllerForDDButton:function(){var element=this.GetDropDownButton();if(_aspxIsExists(element)){var controller=aspxGetStateController();this.ddButtonHoverStyle=this.ReplaceElementControlStyleItem(controller.hoverItems,element,null);this.ddButtonPressedStyle=this.ReplaceElementControlStyleItem(controller.pressedItems,element,null);this.ddButtonSelectedStyle=this.ReplaceElementControlStyleItem(controller.selectedItems,element,null);}},ReplaceElementControlStyleItem:function(items,element,newStyleItem){var styleItem=items[element.id];items[element.id]=newStyleItem;return styleItem;},OnDocumentMouseDown:function(){this.HideDropDownArea(true);},OnDocumentMouseUp:function(){this.DropDownButtonPop();},OnDDButtonMouseMove:function(evt){},OnCloseUp:function(evt){this.HideDropDownArea(true);},OnOpenAnotherDropDown:function(){this.HideDropDownArea(true);},OnTextChanged:function(){this.ParseValue();},ChangeEnabledAttributes:function(enabled){ASPxClientButtonEditBase.prototype.ChangeEnabledAttributes.call(this,enabled);var btnElement=this.GetDropDownButton();if(_aspxIsExists(btnElement))
this.ChangeButtonEnabledAttributes(btnElement,_aspxChangeAttributesMethod(enabled));var inputElement=this.GetInputElement();if(_aspxIsExists(inputElement))
this.ChangeInputCellEnabledAttributes(inputElement.parentNode,_aspxChangeAttributesMethod(enabled));},ChangeEnabledStateItems:function(enabled){ASPxClientButtonEditBase.prototype.ChangeEnabledStateItems.call(this,enabled);var btnElement=this.GetDropDownButton();if(_aspxIsExists(btnElement))
aspxGetStateController().SetElementEnabled(btnElement,enabled);},ChangeInputCellEnabledAttributes:function(element,method){method(element,"onclick");method(element,"onkeyup");method(element,"onmousedown");method(element,"onmouseup");},InitializeKeyHandlers:function(){this.AddKeyDownHandler(ASPxKey.Enter,"OnEnter");this.AddKeyDownHandler(ASPxKey.Esc,"OnEscape");this.AddKeyDownHandler(ASPxKey.PageUp,"OnPageUp");this.AddKeyDownHandler(ASPxKey.PageDown,"OnPageDown");this.AddKeyDownHandler(ASPxKey.End,"OnEndKeyDown");this.AddKeyDownHandler(ASPxKey.Home,"OnHomeKeyDown");this.AddKeyDownHandler(ASPxKey.Left,"OnArrowLeft");this.AddKeyDownHandler(ASPxKey.Right,"OnArrowRight");this.AddKeyDownHandler(ASPxKey.Up,"OnArrowUp");this.AddKeyDownHandler(ASPxKey.Down,"OnArrowDown");this.AddKeyDownHandler(ASPxKey.Tab,"OnTab");},OnArrowUp:function(evt){if(evt.altKey){this.ToggleDropDown();return true;}
return false;},OnArrowDown:function(evt){if(evt.altKey){this.ToggleDropDown();return true;}
return false;},OnPageUp:function(evt){return false;},OnPageDown:function(evt){return false;},OnEndKeyDown:function(evt){return false;},OnHomeKeyDown:function(evt){return false;},OnArrowLeft:function(evt){return false;},OnArrowRight:function(evt){return false;},OnEscape:function(evt){var isCancelProcessed=this.OnCancelChanges()||this.droppedDown;this.HideDropDownArea(true);return isCancelProcessed;},OnEnter:function(evt){return false;},OnTab:function(evt){return false;},RaiseCloseUp:function(){if(!this.CloseUp.IsEmpty()){var args=new ASPxClientEventArgs();this.CloseUp.FireEvent(this,args);}},RaiseDropDown:function(){if(!this.DropDown.IsEmpty()){var args=new ASPxClientEventArgs();this.DropDown.FireEvent(this,args);}},ShowDropDown:function(){this.ShowDropDownArea(false);},HideDropDown:function(){this.HideDropDownArea(false);}});ASPxClientDropDownCollection=_aspxCreateClass(ASPxClientControlCollection,{constructor:function(){this.constructor.prototype.constructor.call(this);this.droppedControlName="";this.focusedControlName="";},SetFocusedDropDownName:function(name){this.focusedControlName=name;},ResetDroppedDownControl:function(){this.droppedControlName="";},ResetFocusedControl:function(){this.focusedControlName="";},GetFocusedDropDown:function(){var control=this.GetDropDownControlInternal(this.focusedControlName);if(control==null)this.ResetFocusedControl();return control;},GetDroppedDropDown:function(){var control=this.GetDropDownControlInternal(this.droppedControlName);if(control==null)this.ResetDroppedDownControl();return control;},GetDropDownControlInternal:function(name){var control=this.Get(name);var isControlExists=_aspxIsExists(control)&&control.IsRenderExists();if(!isControlExists)
control=null;return control;},OnDDButtonMouseMove:function(evt){var dropDownControl=this.GetDroppedDropDown();if(dropDownControl!=null)
dropDownControl.OnDDButtonMouseMove(evt);},OnDocumentMouseDown:function(evt){this.LockFocusEventsByDocumentEvent(evt);this.CloseDropDownByDocumentEvent(evt,false);this.ClearFocusedDropDownByDocumentEvent(evt);},OnDocumentMouseUp:function(evt){var dropDownControl=this.GetDroppedDropDown();if(dropDownControl!=null)
dropDownControl.OnDocumentMouseUp();},OnResize:function(evt){this.CloseDropDownByDocumentEvent(evt,true);this.AdjustControls();},LockFocusEventsByDocumentEvent:function(evt){var control=this.GetFocusedDropDown();if(control!=null&&!this.IsEventNotFromControlSelf(evt,control))
control.LockFocusEventsByMouseDown(_aspxGetEventSource(evt));},CloseDropDownByDocumentEvent:function(evt,isResize){var dropDownControl=this.GetDroppedDropDown();if(dropDownControl!=null&&(this.IsEventNotFromControlSelf(evt,dropDownControl)||isResize))
dropDownControl.OnDocumentMouseDown();},ClearFocusedDropDownByDocumentEvent:function(evt){var focusedDropDown=this.GetFocusedDropDown();if(focusedDropDown!=null&&this.IsEventNotFromControlSelf(evt,focusedDropDown))
this.SetFocusedDropDownName("");},AdjustControls:function(){for(var name in this.elements){this.elements[name].AdjustControl(false);}},IsEventNotFromControlSelf:function(evt,control){var srcElement=_aspxGetEventSource(evt);var mainElement=control.GetMainElement();var popupControl=control.GetPopupControl();if(srcElement==null||!_aspxIsExists(mainElement)||!_aspxIsExists(popupControl))return true;return(!_aspxGetIsParent(mainElement,srcElement)&&!_aspxGetIsParent(popupControl.GetWindowElement(-1),srcElement));},RegisterDroppedDownControl:function(dropDownControl){var previousDropDownControl=this.GetDroppedDropDown();if(previousDropDownControl!=null)
previousDropDownControl.OnOpenAnotherDropDown();this.droppedControlName=dropDownControl.name;},UnregisterDroppedDownControl:function(dropDownControl){if(this.droppedControlName==dropDownControl.name)
this.ResetDroppedDownControl();}});ASPxClientDateEdit=_aspxCreateClass(ASPxClientDropDownEdit,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.dateFormatter=new ASPxDateFormatter();this.calendarMainElementOnClick=null;this.date=null;this.dateOnError="u";this.allowNull=true;this.calendarOwnerName=null;this.DateChanged=new ASPxClientEvent();this.ParseDate=new ASPxClientEvent();},Initialize:function(){var calendar=this.GetCalendar();if(_aspxIsExists(calendar)){this.calendarMainElementOnClick=_aspxCreateEventHandlerFunction("aspxEdDECMainElementClick",this.name);if(__aspxNS)
calendar.GetMainElement().style.borderCollapse="separate";}
ASPxClientDropDownEdit.prototype.Initialize.call(this);},InlineInitialize:function(){this.InitSpecialKeyboardHandling();ASPxClientEditBase.prototype.InlineInitialize.call(this);},ShowDropDownArea:function(isRaiseEvent){var cal=this.GetCalendar();if(_aspxIsExists(cal))
cal.SetValue(this.date);cal.forceMouseDown=true;__aspxActiveCalendar=cal;cal.SelectionChanging.ClearHandlers();cal.SelectionChanging.AddHandler(ASPxClientDateEdit.CreateDelegate(this,this.OnCalendarSelectionChanging));cal.MainElementClick.ClearHandlers();cal.MainElementClick.AddHandler(this.calendarMainElementOnClick);ASPxClientDropDownEdit.prototype.ShowDropDownArea.call(this,isRaiseEvent);},GetPopupControl:function(){var calendarOwner=this.GetCalendarOwner();if(calendarOwner!=null)
return calendarOwner.GetPopupControl();return ASPxClientDropDownEdit.prototype.GetPopupControl.call(this);},GetCalendar:function(){var name=this.GetDropDownInnerControlName(__aspxCalendarNameSuffix);return aspxGetControlCollection().Get(name);},GetCalendarOwner:function(){if(!this.calendarOwnerName)
return null;return aspxGetControlCollection().Get(this.calendarOwnerName);},GetFormattedDate:function(){if(!this.date)
return"";return this.dateFormatter.Format(this.date);},RaiseValueChangedEvent:function(){var processOnServer=ASPxClientEdit.prototype.RaiseValueChangedEvent.call(this);processOnServer=this.RaiseDateChanged(processOnServer);return processOnServer;},OnApplyChanges:function(){this.OnTextChanged();},OnCalendarSelectionChanging:function(sender,e){if(!this.GetCalendar().isDateChangingByKeyboard){this.HideDropDownArea(true);var date=null;if(_aspxIsExists(e.selection))
date=e.selection.GetFirstDate();else
date=this.GetCalendar().GetValue();if(date!=null&&this.date!=null){date.setHours(this.date.getHours());date.setMinutes(this.date.getMinutes());date.setSeconds(this.date.getSeconds());date.setMilliseconds(this.date.getMilliseconds());}
this.ChangeDate(date);this.SelectInputElement();}},OnCalendarMainElementClick:function(){this.SetFocus();},OnArrowUp:function(evt){var isProcessed=ASPxClientDropDownEdit.prototype.OnArrowUp.call(this,evt);if(!isProcessed&&this.droppedDown)
this.GetCalendar().OnArrowUp(evt);return true;},OnArrowDown:function(evt){var isProcessed=ASPxClientDropDownEdit.prototype.OnArrowDown.call(this,evt);if(!isProcessed&&this.droppedDown)
this.GetCalendar().OnArrowDown(evt);return true;},OnArrowLeft:function(evt){if(this.droppedDown){this.GetCalendar().OnArrowLeft(evt);return true;}
return false;},OnArrowRight:function(evt){if(this.droppedDown){this.GetCalendar().OnArrowRight(evt);return true;}
return false;},OnPageUp:function(evt){if(this.droppedDown){this.GetCalendar().OnPageUp(evt);return true;}
return false;},OnPageDown:function(evt){if(this.droppedDown){this.GetCalendar().OnPageDown(evt);return true;}
return false;},OnEndKeyDown:function(evt){if(this.droppedDown){this.GetCalendar().OnEndKeyDown(evt);return true;}
return false;},OnHomeKeyDown:function(evt){if(this.droppedDown){this.GetCalendar().OnHomeKeyDown(evt);return true;}
return false;},OnEnter:function(){this.enterProcessed=false;if(this.droppedDown){var calendar=this.GetCalendar();if(calendar.IsFastNavigationActive()){calendar.GetFastNavigation().OnEnter();}else{var args=new ASPxClientCalendarSelectionEventArgs(false,null);this.OnCalendarSelectionChanging(this,args);}
this.enterProcessed=true;}
else
this.OnApplyChanges();return this.enterProcessed;},OnEscape:function(){if(this.droppedDown){if(this.GetCalendar().IsFastNavigationActive())
this.GetCalendar().OnEscape();else
ASPxClientDropDownEdit.prototype.OnEscape.call(this);}
return true;},OnTab:function(evt){if(!this.droppedDown)return;var calendar=this.GetCalendar();if(calendar.IsFastNavigationActive())
calendar.GetFastNavigation().Hide();var args=new ASPxClientCalendarSelectionEventArgs(false,null);this.OnCalendarSelectionChanging(this,args);},ParseValue:function(){var value=ASPxClientButtonEditBase.prototype.GetValue.call(this);if(!this.ParseDate.IsEmpty()){var args=new ASPxClientParseDateEventArgs(value);this.ParseDate.FireEvent(this,args);if(args.handled){this.ChangeDate(args.date);return;}}
if(value==null||value==""){this.allowNull?this.ChangeDate(null):this.UpdateDateEditInputs();}else{var date=this.dateFormatter.Parse(value);if(!date||!this.GetCalendar().IsDateInRange(date)){switch(this.dateOnError){case"n":this.allowNull?this.ChangeDate(null):this.UpdateDateEditInputs();break;case"t":this.ChangeDate(new Date());break;default:this.UpdateDateEditInputs();break;}}else
this.ChangeDate(date);}},GetValue:function(){return this.date;},GetValueString:function(){return this.date!=null?_aspxGetInvariantDateTimeString(this.date):null;},SetValue:function(date){this.date=date;this.UpdateDateEditInputs();},UpdateDateEditInputs:function(){ASPxClientButtonEditBase.prototype.SetValue.call(this,this.GetFormattedDate());var input=this.GetTimestampInput();if(input!=null)
input.value=this.date==null?"N":this.date.valueOf()-60000*this.date.getTimezoneOffset();},GetTimestampInput:function(){return _aspxGetElementById(this.name+"_TS");},ChangeDate:function(date){var oldDate=this.date;this.SetValue(date);if(!this.AreDatesEqualExact(oldDate,date)){this.RaisePersonalStandardValidation();this.OnValueChanged();}},AreDatesEqualExact:function(date1,date2){if(date1==null&&date2==null)
return true;if(date1==null||date2==null)
return false;return date1.getTime()==date2.getTime();},GetText:function(){return this.GetFormattedDate();},SetText:function(value){ASPxClientTextEdit.prototype.SetValue.call(this,value);this.ParseValue();},LockFocusEventsByMouseDown:function(srcElement){if(srcElement!=this.GetInputElement()&&srcElement!=this.GetDropDownButton())
this.LockFocusEvents();},RaiseDateChanged:function(processOnServer){if(!this.DateChanged.IsEmpty()){var args=new ASPxClientProcessingModeEventArgs(processOnServer);this.DateChanged.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;},SetDate:function(date){this.SetValue(date);},GetDate:function(){return this.date;}});ASPxClientDateEdit.CreateDelegate=function(object,method){function handler(sender,e){method.call(object,sender,e);}
return handler;}
ASPxClientParseDateEventArgs=_aspxCreateClass(ASPxClientEventArgs,{constructor:function(value){this.constructor.prototype.constructor.call(this);this.value=value;this.date=null;this.handled=false;}});__aspxCCValueInputSuffix="VI";ASPxClientComboBoxBase=_aspxCreateClass(ASPxClientDropDownEdit,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.lbEventLockCount=0;this.listBox=null;this.lastSuccessValue="";this.islastSuccessValueInit=false;this.SelectedIndexChanged=new ASPxClientEvent();},Initialize:function(){this.InitializeListBoxOwnerName();ASPxClientDropDownEdit.prototype.Initialize.call(this);},InitializeListBoxOwnerName:function(){var lb=this.GetListBoxControl();if(_aspxIsExists(lb))
lb.ownerName=this.name;},GetDropDownInnerControlName:function(suffix){return"";},GetListBoxControl:function(){if(!_aspxIsExistsElement(this.listBox)){var name=this.GetDropDownInnerControlName(__aspxListBoxNameSuffix);this.listBox=aspxGetControlCollection().Get(name);}
return this.listBox;},GetCallbackArguments:function(){return this.GetListBoxCallbackArguments();},GetListBoxCallbackArguments:function(){var lb=this.GetListBoxControl();return lb.GetCallbackArguments();},SendCallback:function(){this.CreateCallback(this.GetCallbackArguments());},SetText:function(text){var lb=this.GetListBoxControl();var index=this.FindItemIndexByText(lb,text);this.SelectIndex(index,false);this.SetTextInternal(text);this.SetLastSuccessTest(text);this.lastSuccessValue=index>=0?lb.GetValue():text;this.islastSuccessValueInit=true;},GetValue:function(){return this.islastSuccessValueInit?this.lastSuccessValue:this.GetValueInternal();},GetValueInternal:function(){var text=ASPxClientDropDownEdit.prototype.GetValue.call(this);var lb=this.GetListBoxControl();if(_aspxIsExists(lb)){var index=this.FindItemIndexByText(lb,text);lb.SelectIndexSilent(index,false);if(index!=-1)
return lb.GetValue();}
return text;},SetValue:function(value){var lb=this.GetListBoxControl();lb.SetValue(value);var item=lb.GetSelectedItem();var text=_aspxIsExists(item)?item.text:value;this.SetTextInternal(text);this.SetLastSuccessTest(text);this.lastSuccessValue=item!=null?item.value:text;this.islastSuccessValueInit=true;this.UpdateValueInput();},FindItemIndexByText:function(lb,text){if(!_aspxIsExists(lb))return;for(var i=0;i<lb.GetItemCount();i++){if(lb.GetItem(i).text==text)
return i;}
return-1;},CollectionChanged:function(){},SelectIndex:function(index,initialize){var lb=this.GetListBoxControl();var isSelectionChanged=lb.SelectIndexSilent(index,initialize);var item=lb.GetSelectedItem();var text=item!=null?item.text:"";if(isSelectionChanged){this.SetTextInternal(text);this.SetLastSuccessTest(text);this.lastSuccessValue=item!=null?item.value:text;this.islastSuccessValueInit=true;}
this.UpdateValueInput();return isSelectionChanged;},OnSelectChanged:function(){if(this.lbEventLockCount>0)return;var lb=this.GetListBoxControl();var item=lb.GetSelectedItem();var text=item!=null?item.text:"";this.SetLastSuccessTest(text);this.lastSuccessValue=item!=null?item.value:text;this.islastSuccessValueInit=true;this.SetTextInternal(text);this.OnChange();if(!this.isToolbarItem)
this.SelectInputElement();},OnCallback:function(result){},OnChange:function(){this.UpdateValueInput();this.RaisePersonalStandardValidation();this.OnValueChanged();},UpdateValueInput:function(){},RaiseValueChangedEvent:function(){var processOnServer=ASPxClientTextEdit.prototype.RaiseValueChangedEvent.call(this);processOnServer=this.RaiseSelectedIndexChanged(processOnServer);return processOnServer;},RaiseSelectedIndexChanged:function(processOnServer){if(!this.SelectedIndexChanged.IsEmpty()){var args=new ASPxClientProcessingModeEventArgs(processOnServer);this.SelectedIndexChanged.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;},AddItem:function(text,value,imageUrl){var index=this.GetListBoxControl().AddItem(text,value,imageUrl);this.CollectionChanged();return index;},InsertItem:function(index,text,value,imageUrl){this.GetListBoxControl().InsertItem(index,text,value,imageUrl);this.CollectionChanged();},RemoveItem:function(index){this.GetListBoxControl().RemoveItem(index);this.CollectionChanged();},ClearItems:function(){this.GetListBoxControl().ClearItems();this.ClearItemsInternal();},BeginUpdate:function(){this.GetListBoxControl().BeginUpdate();},EndUpdate:function(){this.GetListBoxControl().EndUpdate();this.CollectionChanged();},MakeItemVisible:function(index){},GetItem:function(index){return this.GetListBoxControl().GetItem(index);},GetItemCount:function(){return this.GetListBoxControl().GetItemCount();},GetSelectedIndex:function(){return this.GetListBoxControl().GetSelectedIndexInternal();},SetSelectedIndex:function(index){this.SelectIndex(index,false);},GetSelectedItem:function(){var lb=this.GetListBoxControl();var index=lb.GetSelectedIndexInternal();return lb.GetItem(index);},SetSelectedItem:function(item){var index=(item!=null)?item.index:-1;this.SelectIndex(index,false);},GetText:function(){return this.lastSuccessText;},PerformCallback:function(arg){},ClearItemsInternal:function(){this.SetValue(null);this.CollectionChanged();}});ASPxClientComboBox=_aspxCreateClass(ASPxClientComboBoxBase,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.filterTimerId=-1;this.allowMultipleCallbacks=false;this.isApplyAndCloseAfterCallback=false;this.isCallbackMode=false;this.isPerformCallback=false;this.changeSelectAfterCallback=0;this.isFilterEnabled=false;this.isEnterLocked=false;this.isLastFilteredKeyWasTab=false;this.filter="";this.filterTimer=100;this.isPostponedFiltration=false;this.isToolbarItem=false;this.isDropDownListStyle=true;this.dropDownHeight="";this.dropDownWidth="";},Initialize:function(){var lb=this.GetListBoxControl();this.InitializeListBoxOwnerName();var mainElement=this.GetMainElement();if(_aspxIsExists(mainElement))
_aspxAttachEventToElement(mainElement,__aspxNS?"DOMMouseScroll":"mousewheel",aspxCBMouseWheel);var input=this.GetInputElement();var ddbutton=this.GetDropDownButton();if(_aspxIsExists(ddbutton))
_aspxAttachEventToElement(ddbutton,"mousemove",aspxCBDDButtonMMove);if(this.isFilterEnabled)
_aspxAttachEventToElement(input,"keyup",aspxCBKeyUp);if(this.isDropDownListStyle&&__aspxIE){_aspxPreventElementDragAndSelect(mainElement,true);_aspxPreventElementDragAndSelect(input,true);if(_aspxIsExists(ddbutton))
_aspxPreventElementDragAndSelect(ddbutton,true);}
if(this.isToolbarItem){mainElement.unselectable="on";input.unselectable="on";if(_aspxIsExists(input.offsetParent))
input.offsetParent.unselectable="on";if(_aspxIsExists(ddbutton))
ddbutton.unselectable="on";if(_aspxIsExists(lb)){var table=lb.GetListTable();for(var i=0;i<table.rows.length;i++){for(var j=0;j<table.rows[i].cells.length;j++)
_aspxSetElementAsUnselectable(table.rows[i].cells[j],true);}}}
this.RemoveRaisePSValidationFromListBox();this.RedirectStandardValidators();this.UpdateValueInput();this.InitDropDownSize();this.InitListBoxScrollStyle();ASPxClientComboBoxBase.prototype.Initialize.call(this);},InlineInitialize:function(){this.InitSpecialKeyboardHandling();ASPxClientEditBase.prototype.InlineInitialize.call(this);},GetDropDownInnerControlName:function(suffix){return ASPxClientDropDownEdit.prototype.GetDropDownInnerControlName.call(this,suffix);},AdjustControlCore:function(){ASPxClientEdit.prototype.AdjustControlCore.call(this);this.ddHeightCache=__aspxInvalidDimension;this.ddWidthCache=__aspxInvalidDimension;},RemoveRaisePSValidationFromListBox:function(){var listBox=this.GetListBoxControl();if(_aspxIsExists(listBox))
listBox.RaisePersonalStandardValidation=function(){};},RedirectStandardValidators:function(){var valueInput=this.GetValueInput();if(_aspxIsExistsElement(valueInput)&&_aspxIsExists(valueInput.Validators)){for(var i=0;i<valueInput.Validators.length;i++)
valueInput.Validators[i].controltovalidate=valueInput.id;}},GetValueInputToValidate:function(){return this.GetValueInput();},GetValueInput:function(){return document.getElementById(this.name+"_"+__aspxCCValueInputSuffix);},GetListBoxScrollDivElement:function(){return this.GetListBoxControl().GetScrollDivElement();},GetDropDownHeight:function(){return(this.ddHeightCache!=__aspxInvalidDimension)?this.ddHeightCache:this.InitListBoxHeight();},GetDropDownWidth:function(){return(this.ddWidthCache!=__aspxInvalidDimension&&!this.GetIsControlWidthWasChanged())?this.ddWidthCache:this.InitListBoxWidth();},UpdateValueInput:function(){var inputElement=this.GetValueInput();if(_aspxIsExists(inputElement)){var value=this.GetValue();inputElement.value=value!=null?value:"";}},CollectionChanged:function(){if(this.GetListBoxControl().APILockCount==0)
this.InitDropDownSize();},InitDropDownSize:function(){var pc=this.GetPopupControl();if(_aspxIsExists(pc)&&this.IsDisplayed()){var pcwElement=pc.GetWindowElement(-1);if(_aspxIsExistsElement(pcwElement)){var isPcwDisplayad=_aspxGetElementDisplay(pcwElement);if(!isPcwDisplayad)
pc.SetWindowDisplay(-1,true);this.ddHeightCache=this.InitListBoxHeight();this.ddWidthCache=this.InitListBoxWidth();pc.SetSize(this.ddWidthCache,this.ddHeightCache);if(!isPcwDisplayad)
pc.SetWindowDisplay(-1,false);}}},InitMainElementCache:function(){this.mainElementWidthCache=this.GetMainElement().clientWidth;},InitListBoxHeight:function(){var lbScrollDiv=this.GetListBoxScrollDivElement();var height=this.dropDownHeight;var lb=this.GetListBoxControl();lb.GetMainElement().style.height="0px";var lbHeight=0;if(height==""){var listHeight=lb.GetListTableHeight();var count=lb.GetItemCount();if(count>7)
height=((listHeight/count)*7)+"px";else
height=count==0?"0px":listHeight+"px";lbScrollDiv.style.height=height;lbHeight=lbScrollDiv.offsetHeight;}else{var lbMainElement=lb.GetMainElement();lbMainElement.style.height="0px";lbScrollDiv.style.height="0px";lbMainElement.style.height=height;var trueLbOffsetHeight=lbMainElement.offsetHeight;var trueLbClientHeight=lbMainElement.clientHeight;lbScrollDiv.style.height=lbMainElement.clientHeight+"px";lbHeightCorrection=lbMainElement.offsetHeight-trueLbOffsetHeight;lbScrollDiv.style.height=(trueLbClientHeight-lbHeightCorrection)+"px";lbHeight=lbMainElement.offsetHeight;}
lb.InitializePageSize();return lbHeight;},InitListBoxWidth:function(){this.InitMainElementCache();var mainElement=this.GetMainElement();var lb=this.GetListBoxControl();var lbMainElement=lb.GetMainElement();var lbScrollDiv=this.GetListBoxScrollDivElement();var lbTable=lb.GetListTable();lbMainElement.style.width="";lbScrollDiv.style.width="100%";if(this.dropDownWidth!=""){lbMainElement.style.width=this.dropDownWidth;lbScrollDiv.style.width=lbMainElement.clientWidth+"px";var difference=lbTable.offsetWidth-lbScrollDiv.clientWidth;if(!__aspxIE&&difference>0){lbMainElement.style.width=(lbMainElement.offsetWidth+difference)+"px";lbScrollDiv.style.width=(lbMainElement.clientWidth)+"px";}}
else{var pc=this.GetPopupControl();var width=lbTable.offsetWidth;var scrollWidth=lb.GetVerticalScrollBarWidth();var isBrowserPutScrollOnContent=!__aspxIE||__aspxIE55;var isBrowserAbleAnimScroll=!__aspxMozilla||__aspxFirefox||!pc.enableAnimation;if(isBrowserPutScrollOnContent&&isBrowserAbleAnimScroll)
width+=scrollWidth;lbScrollDiv.style.width=width+"px";if(__aspxFirefox&&lbMainElement.offsetWidth<lbScrollDiv.offsetWidth)
lbMainElement.style.width="0%";var widthDifference=mainElement.offsetWidth-lbMainElement.offsetWidth;if(widthDifference>0){lbScrollDiv.style.width=(width+widthDifference)+"px";var twoBorderSize=(lbMainElement.offsetWidth-lbMainElement.clientWidth);lbMainElement.style.width=(width+widthDifference+twoBorderSize)+"px";}}
return lbScrollDiv.offsetWidth;},InitListBoxScrollStyle:function(){this.PreventScrollSpoilDDShowing();},SelectIndexSilent:function(lb,index){this.lbEventLockCount++;lb.SelectIndexSilent(index);this.lbEventLockCount--;},SelectInputText:function(){var input=this.GetInputElement();_aspxSetInputSelection(input,0,input.value.length);},ShowDropDownArea:function(isRaiseEvent){var lb=this.GetListBoxControl();if(!_aspxIsExists(lb)||lb.GetItemCount()==0)
return;var pc=this.GetPopupControl();ASPxClientDropDownEdit.prototype.ShowDropDownArea.call(this,isRaiseEvent);var text=ASPxClientDropDownEdit.prototype.GetValue.call(this);var lbItem=lb.GetSelectedItem();var lbText=lbItem!=null?lbItem.text:"";if(text!=lbText&&text!=null&&lbText!=""){var newSelectedIndex=this.FindItemIndexByText(lb,text);lb.SelectIndexSilent(newSelectedIndex,false);}
lb.EnsureSelectedItemVisible();lb.CallbackSpaceInit();},HideDropDownArea:function(isRaiseEvent){this.FilteringStop();ASPxClientDropDownEdit.prototype.HideDropDownArea.call(this,isRaiseEvent);this.PreventScrollSpoilDDShowing();},IsScrollSpoilDDShowing:function(){var pc=this.GetPopupControl();return((__aspxMozilla||__aspxFirefox)&&pc.enableAnimation);},EnableLBDivOverflow:function(){var divElement=this.GetListBoxScrollDivElement();divElement.style.overflow="auto";},DisableLBDivOverflow:function(){var divElement=this.GetListBoxScrollDivElement();divElement.style.overflow="hidden";},PreventScrollSpoilDDShowing:function(){if(this.IsScrollSpoilDDShowing())
this.DisableLBDivOverflow();},ChangeReadOnlyAttribute:function(element,enabled){if(!this.isDropDownListStyle||this.isFilterEnabled)
ASPxClientTextEdit.prototype.ChangeReadOnlyAttribute.call(this,element,enabled);},IsInputValueChangingEventKeyCode:function(evt){var keyCode=_aspxGetKeyCode(evt);var isSystemKey=ASPxKey.Windows<=keyCode&&keyCode<=ASPxKey.ContextMenu;var isFKey=ASPxKey.F1<=keyCode&&keyCode<=127;return ASPxKey.Delete<=keyCode&&!isSystemKey&&!isFKey||keyCode==ASPxKey.Backspace||keyCode==ASPxKey.Space;},OnFilteringKeyUp:function(evt){if(!this.isFilterEnabled||this.InCallback())return;if(this.IsInputValueChangingEventKeyCode(evt)){this.FilterStopTimer();var input=this.GetInputElement();var newFilter=input.value.toLowerCase();if(evt.keyCode==ASPxKey.Backspace&&_aspxHasInputSelection(input)&&newFilter==this.filter)
this.FilteringBackspace();else
this.FilterStartTimer();}},IsFilterTimerActive:function(){return(this.filterTimerId!=-1);},FilterStartTimer:function(){this.isEnterLocked=true;this.filterTimerId=_aspxSetTimeout("aspxCBFilterByTimer('"+this.name+"')",this.filterTimer);},FilterStopTimer:function(){this.filterTimerId=_aspxClearTimer(this.filterTimerId);},EnshureShowDropDownArea:function(){if(!this.droppedDown)
this.ShowDropDownArea(true);},Filtering:function(){this.FilterStopTimer();this.isPostponedFiltration=false;var input=this.GetInputElement();var newFilter=input.value.toLowerCase();if(this.filter!=newFilter){this.filter=newFilter;this.EnshureShowDropDownArea();if(this.isCallbackMode)
this.FilteringOnServer();else
this.FilteringOnClient(input);}else
this.isEnterLocked=false;},FilteringBackspace:function(){if(this.isFilterEnabled){var input=this.GetInputElement();input.value=input.value.slice(0,-1);this.FilterStartTimer();}},GetCallbackArguments:function(){var args=ASPxClientComboBoxBase.prototype.GetCallbackArguments.call(this);if(this.isCallbackMode)
args+=this.GetCallbackArgumentsInternal();return args;},GetCallbackArgumentsInternal:function(){var args="";if(this.filter!="")
args=this.GetCallbackArgumentFilter(this.filter);return args;},GetCallbackArgumentFilter:function(value){var callbackPrefix=this.isDropDownListStyle?__aspxCorrectFilterCallbackPrefix:__aspxLoadFilteredItemsCallbackPrefix;return this.FormatCallbackArg(callbackPrefix,value);},FilteringOnServer:function(){if(!this.InCallback()){var listBox=this.GetListBoxControl();listBox.ClearItems();listBox.serverIndexOfFirstItem=0;listBox.SetScrollSpacerVisibility(true,false);listBox.SetScrollSpacerVisibility(false,false);this.SendCallback();}},FilteringOnClient:function(input){var filter=this.filter.toLowerCase();var lb=this.GetListBoxControl();var listTable=lb.GetListTable();var count=lb.GetItemCount();var text="";var isSatisfy=false;var isFirstSatisfyItemFinded=false;if(this.isDropDownListStyle){var coincide=new Array(count);var maxCoincide=0;for(var i=count-1;i>=0;i--){coincide[i]=this.GetCoincideCharCount(lb.GetItem(i).text.toLowerCase(),filter);if(coincide[i]>maxCoincide)
maxCoincide=coincide[i];}
filter=filter.substr(0,maxCoincide);this.GetInputElement().value=filter;}
for(var i=0;i<count;i++){text=lb.GetItem(i).text;isSatisfy=this.isDropDownListStyle?(coincide[i]==maxCoincide):(text.toLowerCase().indexOf(filter)==0);_aspxSetElementDisplay(listTable.rows[i],isSatisfy);if(!isFirstSatisfyItemFinded&&isSatisfy){var isTextClearing=!this.isDropDownListStyle&&this.filter==""&&this.filter!=text;if(!isTextClearing)
this.FilteringHighlightComplitedText(text);this.SelectIndexSilent(lb,isTextClearing?-1:i);isFirstSatisfyItemFinded=true;}}
if(this.isDropDownListStyle)
this.filter=filter;if(!isFirstSatisfyItemFinded)
this.HideDropDownArea(true);this.isEnterLocked=false;},GetCoincideCharCount:function(text,filter){while(filter!=""&&text.indexOf(filter)!=0){filter=filter.slice(0,-1);}
return filter.length;},FilteringHighlightComplitedText:function(filterItemText){var lb=this.GetListBoxControl();var input=this.GetInputElement();var text=input.value;var valueLenght=text.length;var itemTextLenght=filterItemText.length;input.value=filterItemText;if(valueLenght<itemTextLenght)
_aspxSetInputSelection(input,valueLenght,itemTextLenght);},FilteringStop:function(){if(this.isFilterEnabled){this.isEnterLocked=false;if(!this.isCallbackMode)
this.FilteringStopClient();}},FilteringStopClient:function(){var lb=this.GetListBoxControl();var listTable=lb.GetListTable();var count=lb.GetItemCount();for(var i=0;i<count;i++)
_aspxSetElementDisplay(listTable.rows[i],true);},ShowLoadingPanel:function(){var lb=this.GetListBoxControl();var loadingParentElement=lb.GetScrollDivElement().parentNode;if(!_aspxIsExists(this.loadingDivElement))
this.CreateLoadingDiv(loadingParentElement);if(!_aspxIsExists(this.loadingPanelElement))
this.CreateLoadingPanelWithAbsolutePosition(loadingParentElement,loadingParentElement);},HideLoadingPanelOnCallback:function(){return false;},FormatCallbackArg:function(prefix,arg){return(_aspxIsExists(arg)?prefix+"|"+arg.length+';'+arg+';':"");},OnCallback:function(result){if(this.isPostponedFiltration){this.preventEndCallbackRising=true;_aspxSetTimeout("aspxCBFilterByTimer('"+this.name+"')",0);}else{this.OnCallbackBeforeListBox();this.GetListBoxControl().OnCallback(result);this.OnCallbackInternal(result);this.OnCallbackFinally(true);}},DoEndCallback:function(){if(this.preventEndCallbackRising)
this.preventEndCallbackRising=false;else
ASPxClientDropDownEdit.prototype.DoEndCallback.call(this);},OnCallbackError:function(result,data){this.GetListBoxControl().OnCallbackError(result);this.OnCallbackFinally(false);},OnCallbackFinally:function(isSuccessful){this.CollectionChanged();this.HideLoadingDiv();this.HideLoadingPanel();this.isPerformCallback=false;this.changeSelectAfterCallback=0;if(isSuccessful){if(this.isApplyAndCloseAfterCallback){this.OnApplyChangesAndCloseWithEvents();this.isApplyAndCloseAfterCallback=false;}}},OnCallbackBeforeListBox:function(){var lb=this.GetListBoxControl();this.changeSelectAfterCallback=lb.changeSelectAfterCallback;},OnCallbackCorrectSelectedIndex:function(){var lb=this.GetListBoxControl();if(this.changeSelectAfterCallback!=0)
this.SetTextInternal(lb.GetSelectedItem().text);},OnCallbackInternal:function(result){this.OnCallbackCorrectSelectedIndex();this.OnFilterCallback(result);},OnFilterCallback:function(result){var lb=this.GetListBoxControl();if(lb.GetItemCount()==0)
this.HideDropDownArea(true);else
this.OnFilterCallbackWithResult(lb);this.isEnterLocked=false;},OnFilterCallbackWithResult:function(lb){this.OnFilterCallbackHighlightAndSelect(lb);var isNeedToKeepDropDownVisible=!this.isPerformCallback&&!this.isLastFilteredKeyWasTab;if(isNeedToKeepDropDownVisible)
this.EnshureShowDropDownArea();},OnFilterCallbackHighlightAndSelect:function(lb){var firstItemText=lb.GetItem(0).text;var isTextClearing=!this.isDropDownListStyle&&this.filter==""&&this.filter!=firstItemText;if(!isTextClearing){var isFilterRollBack=this.CheckForFilterRollback(lb,firstItemText);var isNonFilterChangingCallback=(lb.GetSelectedItem()==null);if(isFilterRollBack||isNonFilterChangingCallback){if(this.isLastFilteredKeyWasTab){this.isLastFilteredKeyWasTab=false;this.SelectIndex(0);this.OnChange();}else{this.FilteringHighlightComplitedText(firstItemText);if(this.isPerformCallback)
this.SelectIndex(0);else
this.SelectIndexSilent(lb,0);}}}},CheckForFilterRollback:function(lb,firstItemText){var isHasCorrection=false;var filter=this.filter.toLowerCase();firstItemText=firstItemText.toLowerCase();while(firstItemText.substring(0,filter.length).toLowerCase()!=filter){filter=filter.slice(0,-1);isHasCorrection=true;}
if(isHasCorrection){this.filter=this.filter.substring(0,filter.length);this.GetInputElement().value=this.filter;}
return isHasCorrection;},SendCallback:function(){this.ShowLoadingPanel();ASPxClientComboBoxBase.prototype.SendCallback.call(this);},SelectNeighbour:function(step){if(this.isToolBarItem&&!this.droppedDown)return;var lb=this.GetListBoxControl();var step=this.GetStepForClientFiltrationEnabled(lb,step);this.SelectNeighbourInternal(lb,step);},SelectNeighbourInternal:function(lb,step){if(this.droppedDown)
this.lbEventLockCount++;lb.SelectNeighbour(step);if(this.droppedDown){this.SetTextInternal(lb.GetSelectedItem().text);this.lbEventLockCount--;}},GetStepForClientFiltrationEnabled:function(lb,step){var isClientFiltrationEnabled=this.isFilterEnabled&&!this.isCallbackMode;if(isClientFiltrationEnabled){var stepDirection=step>0?1:-1;var startIndex=this.GetSelectedIndex();var count=lb.GetItemCount();var listTable=lb.GetListTable();var needVisibleItemCount=Math.abs(step);var outermostVisibleIndex=startIndex;for(var index=startIndex+stepDirection;needVisibleItemCount>0;index+=stepDirection){if(index<0||count<=index)break;if(_aspxGetElementDisplay(listTable.rows[index])){outermostVisibleIndex=index;needVisibleItemCount--;}}
step=outermostVisibleIndex-this.GetSelectedIndex();}
return step;},OnSpecialKeyDown:function(evt){if(this.isFilterEnabled&&this.IsInputValueChangingEventKeyCode(evt)){this.FilterStopTimer();this.isPostponedFiltration=true;}
return ASPxClientEdit.prototype.OnSpecialKeyDown.call(this,evt);},OnArrowUp:function(evt){var isProcessed=ASPxClientDropDownEdit.prototype.OnArrowUp.call(this,evt);if(!isProcessed)
this.SelectNeighbour(-1);return true;},OnArrowDown:function(evt){var isProcessed=ASPxClientDropDownEdit.prototype.OnArrowDown.call(this,evt);if(!isProcessed)
this.SelectNeighbour(1);return true;},OnPageUp:function(){return this.OnPageButtonDown(false);},OnPageDown:function(){return this.OnPageButtonDown(true);},OnPageButtonDown:function(isDown){var lb=this.GetListBoxControl();if(_aspxIsExists(lb)){var direction=isDown?1:-1;this.SelectNeighbour(lb.scrollPageSize*direction);}
return true;},OnHomeKeyDown:function(evt){return this.OnHomeEndKeyDown(evt,true);},OnEndKeyDown:function(evt){return this.OnHomeEndKeyDown(evt,false);},OnHomeEndKeyDown:function(evt,isHome){var input=this.GetValueInput();if(input.readOnly||evt.ctrlKey){var lb=this.GetListBoxControl();var count=lb.GetItemCount();this.SelectNeighbour(isHome?-count:count);return true;}
return false;},OnEnter:function(){this.enterProcessed=this.droppedDown;if(!this.isEnterLocked)
this.OnApplyChangesAndCloseWithEvents();return this.enterProcessed;},OnTab:function(evt){if(this.IsFilterTimerActive()||this.isPostponedFiltration){this.isLastFilteredKeyWasTab=true;this.Filtering();}
if(this.InCallback())
this.isApplyAndCloseAfterCallback=true;else
this.OnApplyChangesAndCloseWithEvents();},OnApplyChanges:function(){if(this.isDropDownListStyle&&!this.isFilterEnabled)return;this.OnApplyChangesInternal();},OnApplyChangesAndCloseWithEvents:function(){this.OnApplyChangesInternal();this.HideDropDownArea(true);},OnApplyChangesInternal:function(){var text=this.GetInputElement().value;var isChanged=this.lastSuccessText!=text;if(isChanged){var lb=this.GetListBoxControl();if(this.isDropDownListStyle&&this.FindItemIndexByText(lb,text)<0){var lbItem=lb.GetSelectedItem();text=lbItem!=null?lbItem.text:this.lastSuccessText;}}
this.SetText(text);if(isChanged)
this.OnChange();},OnButtonClick:function(number){if(number!=this.dropDownButtonIndex){this.HideDropDownArea(true);}
ASPxClientButtonEditBase.prototype.OnButtonClick.call(this,number);},OnCancelChanges:function(){var isCancelProcessed=ASPxClientDropDownEdit.prototype.OnCancelChanges.call(this);var lb=this.GetListBoxControl();var index=this.FindItemIndexByText(lb,this.lastSuccessText);this.SelectIndexSilent(lb,index);return isCancelProcessed;},OnCloseUp:function(evt){var evt=_aspxGetEvent(evt);var scrollDiv=this.GetListBoxControl().GetScrollDivElement();var scrollDivID=_aspxIsExists(scrollDiv)?scrollDiv.id:"";if(__aspxFirefox&&evt.type=="mouseup"&&(_aspxGetEventSource(evt).tagName=="DIV"&&scrollDivID==_aspxGetEventSource(evt).id))
return;ASPxClientDropDownEdit.prototype.OnCloseUp.call(this,evt);},OnDDButtonMouseMove:function(evt){return(this.droppedDown?_aspxCancelBubble(evt):true);},OnDocumentMouseDown:function(){this.OnApplyChangesInternal();ASPxClientDropDownEdit.prototype.OnDocumentMouseDown.call(this);},IsCanToDropDown:function(){return(this.GetListBoxControl().GetItemCount()>0);},OnPopupControlShown:function(){if(this.IsScrollSpoilDDShowing())
_aspxSetTimeout("aspxCBMozillaOverflowOn(\""+this.name+"\")",100);if(this.lockListBoxClick)
delete this.lockListBoxClick;},OnItemClick:function(){if(!this.lockListBoxClick){this.OnSelectChanged();this.OnClick();}},OnListBoxClick:function(evt){if(!this.lockListBoxClick&&!this.InCallback()&&_aspxGetIsLeftButtonPressed(evt)){this.OnApplyChangesInternal();this.OnCloseUp(evt);}},OnMouseWheel:function(evt){if(!this.droppedDown){var wheelDelta=_aspxGetWheelDelta(evt);if(wheelDelta>0)
this.SelectNeighbour(-1);else if(wheelDelta<0)
this.SelectNeighbour(1);return _aspxPreventEvent(evt);}},OnSetFocus:function(isFocused){if(isFocused&&this.isFilterEnabled&&!this.isToolbarItem)
this.SelectInputText();ASPxClientDropDownEdit.prototype.OnSetFocus.call(this,isFocused);},OnOpenAnotherDropDown:function(){this.OnApplyChangesAndCloseWithEvents();},OnClick:function(){if(!this.isToolbarItem)
ASPxClientDropDownEdit.prototype.OnClick.call(this);},ParseValue:function(){var newText=ASPxClientButtonEditBase.prototype.GetValue.call(this);var oldText=this.GetText();if(oldText!=newText){this.SetText(newText);this.OnChange();}},MakeItemVisible:function(index){var lb=this.GetListBoxControl();lb.MakeItemVisible(index);},PerformCallback:function(arg){this.isPerformCallback=true;this.filter="";this.ClearItemsInternal();this.GetListBoxControl().PerformCallback(arg);},ClearItemsInternal:function(){ASPxClientComboBoxBase.prototype.ClearItemsInternal.call(this);var lbScrollDiv=this.GetListBoxScrollDivElement();if(_aspxIsExists(lbScrollDiv))
lbScrollDiv.scrollTop="0px";}});ASPxClientNativeComboBox=_aspxCreateClass(ASPxClientComboBoxBase,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.initSelectedIndex=-1;this.raiseValueChangedOnEnter=false;},Initialize:function(){var lb=this.GetListBoxControl();if(lb!=null)lb.SetMainElement(this.GetMainElement());ASPxClientComboBoxBase.prototype.Initialize.call(this);},InitLastSuccessText:function(){this.SelectIndex(this.initSelectedIndex,true);},FindInputElement:function(){return this.GetMainElement();},GetDropDownInnerControlName:function(suffix){return this.name+suffix;},PerformCallback:function(arg){this.GetListBoxControl().PerformCallback(arg);},SetText:function(text){var lb=this.GetListBoxControl();var index=this.FindItemIndexByText(lb,text);this.SelectIndex(index,false);this.SetLastSuccessTest((index>-1)?text:"");this.lastSuccessValue=(index>-1)?lb.GetValue():null;this.islastSuccessValueInit=true;},GetValue:function(){var selectedItem=this.GetSelectedItem();return(selectedItem!=null)?selectedItem.value:null;},SetValue:function(value){var lb=this.GetListBoxControl();lb.SetValue(value);var item=lb.GetSelectedItem();var text=_aspxIsExists(item)?item.text:value;this.SetLastSuccessTest((item!=null)?text:"");this.lastSuccessValue=(item!=null)?item.value:null;this.islastSuccessValueInit=true;},OnCallback:function(result){this.GetListBoxControl().OnCallback(result);if(this.GetItemCount()>0)
this.SetSelectedIndex(0);},OnTextChanged:function(){this.OnChange();},SetTextInternal:function(text){},ChangeEnabledAttributes:function(enabled){this.GetMainElement().disabled=!enabled;}});var __aspxDropDownCollection=null;function aspxGetDropDownCollection(){if(__aspxDropDownCollection==null)
__aspxDropDownCollection=new ASPxClientDropDownCollection();return __aspxDropDownCollection;}
_aspxAttachEventToDocument("mousedown",aspxDropDownDocumentMouseDown);function aspxDropDownDocumentMouseDown(evt){return aspxGetDropDownCollection().OnDocumentMouseDown(evt);}
_aspxAttachEventToDocument("mouseup",aspxDropDownDocumentMouseUp);function aspxDropDownDocumentMouseUp(evt){return aspxGetDropDownCollection().OnDocumentMouseUp(evt);}
_aspxAttachEventToElement(window,"resize",aspxCBWindowResize);function aspxCBWindowResize(evt){aspxGetDropDownCollection().OnResize(evt);}
function aspxDDDropDown(name,evt){if(_aspxGetIsLeftButtonPressed(evt)){var dd=aspxGetControlCollection().Get(name);if(_aspxIsExists(dd))
return dd.OnDropDown(evt);}}
function aspxDDCloseUp(name,evt){var dd=aspxGetControlCollection().Get(name);dd.OnCloseUp(evt);}
function aspxEdDECMainElementClick(name){var dateEdit=aspxGetControlCollection().Get(name);if(dateEdit)
dateEdit.OnCalendarMainElementClick();}
function aspxDDMainElementClick(name,evt){var dd=aspxGetControlCollection().Get(name);if(dd!=null)dd.OnClick();}
function aspxCBPCShown(name,evt){var cb=aspxGetControlCollection().Get(name);if(cb!=null)cb.OnPopupControlShown();}
function aspxCBIClick(name,evt){var cb=aspxGetControlCollection().Get(name);if(cb!=null)cb.OnItemClick();}
function aspxCBLBClick(name,evt){var cb=aspxGetControlCollection().Get(name);if(cb!=null)cb.OnListBoxClick(evt);}
function aspxCBMozillaOverflowOn(name){var cb=aspxGetControlCollection().Get(name);cb.EnableLBDivOverflow();}
function aspxCBDDButtonMMove(evt){return aspxGetDropDownCollection().OnDDButtonMouseMove(evt);}
function aspxCBMouseWheel(evt){var cb=aspxGetDropDownCollection().GetFocusedDropDown();if(cb!=null)
return cb.OnMouseWheel(evt);}
function aspxCBKeyUp(evt){var cb=aspxGetDropDownCollection().GetFocusedDropDown();if(cb!=null)
cb.OnFilteringKeyUp(evt);}
function aspxCBFilterByTimer(name){var cb=aspxGetControlCollection().Get(name);if(cb!=null)cb.Filtering();}
var __aspxCalendarWeekCount=6;var __aspxCalendarMsPerDay=86400000;var __aspxActiveCalendar=null;ASPxClientCalendar=_aspxCreateClass(ASPxClientEdit,{constructor:function(name){this.constructor.prototype.constructor.call(this,name);this.SelectionChanging=new ASPxClientEvent();this.SelectionChanged=new ASPxClientEvent();this.VisibleMonthChanged=new ASPxClientEvent();this.isMouseDown=false;this.forceMouseDown=false;this.selection=new ASPxClientCalendarSelection();this.selectionTransaction=null;this.selectionStartDate=null;this.selectionPrevStartDate=null;this.lastSelectedDate=null;this.selectionCtrl=false;this.selectionByWeeks=false;this.nodeCache={};this.visibleDate=new Date();this.firstDayOfWeek=0;this.columns=1;this.rows=1;this.enableFast=true;this.enableMulti=false;this.minDate=null;this.maxDate=null;this.customDraw=false;this.showWeekNumbers=true;this.showDayHeaders=true;this.isDateEditCalendar=false;this.isDateChangingByKeyboard=false;this.MainElementClick=new ASPxClientEvent();},Initialize:function(){if(this.enableFast)
this.fastNavigation=new ASPxClientCalendarFastNavigation(this);this.selectionTransaction=new ASPxClientCalendarSelectionTransaction(this);this.selectionPrevStartDate=this.selection.GetFirstDate();this.SaveClientState();ASPxClientEdit.prototype.Initialize.call(this);},InlineInitialize:function(){this.CreateViews();this.InitSpecialKeyboardHandling();this.MakeDisabledStateItems();ASPxClientEditBase.prototype.InlineInitialize.call(this);},MakeDisabledStateItems:function(){for(var key in this.views){var view=this.views[key];if(view.constructor!=ASPxClientCalendarView)continue;view.MakeDisabledStateItems();}},FindInputElement:function(){return this.GetChild("_KBS");},FindStateInputElement:function(){return _aspxGetElementById(this.name+"_STATE");},GetClearButton:function(){return this.GetChild("_BC");},GetTodayButton:function(){return this.GetChild("_BT");},GetValue:function(){return this.selection.GetFirstDate();},GetValueString:function(){var value=this.GetValue();return value==null?null:_aspxGetInvariantDateString(value);},SetValue:function(date){if(date!=null)
this.SetVisibleDate(date);this.SetSelectedDate(date);},GetFastNavigation:function(){return this.fastNavigation;},GetViewKey:function(row,column){return row+"x"+column;},GetView:function(row,column){var key=this.GetViewKey(row,column);return this.views[key];},CreateViews:function(){this.views={};var key;for(var row=0;row<this.rows;row++){for(var col=0;col<this.columns;col++){key=this.GetViewKey(row,col);var view=new ASPxClientCalendarView(this,row,col);view.Initialize();this.views[key]=view;}}},IsFastNavigationActive:function(){if(_aspxIsExists(this.fastNavigation))
return this.fastNavigation.GetPopup().IsVisible();return false;},IsDateSelected:function(date){return this.selection.Contains(date);},IsDateVisible:function(date){var startDate=ASPxClientCalendar.CloneDate(this.GetView(0,0).visibleDate);startDate.setDate(1);var endDate=ASPxClientCalendar.CloneDate(this.GetView(this.rows-1,this.columns-1).visibleDate);endDate.setDate(ASPxClientCalendar.GetDaysInMonth(endDate.getMonth(),endDate.getFullYear()));return(date>=startDate)&&(date<endDate);},IsDateWeekend:function(date){var day=date.getDay();return day==0||day==6;},IsMultiView:function(){return this.columns>1||this.rows>1;},IsDateInRange:function(date){return date==null||((this.minDate==null||date>=this.minDate)&&(this.maxDate==null||date<=this.maxDate));},GetCachedElementById:function(id){if(!_aspxIsExistsElement(this.nodeCache[id]))
this.nodeCache[id]=_aspxGetElementById(id);return this.nodeCache[id];},Update:function(){if(this.customDraw)
this.SendPostBack("");else
this.UpdateInternal();},UpdateInternal:function(){for(var key in this.views){var view=this.views[key];if(view.constructor!=ASPxClientCalendarView)continue;view.Update();}},ApplySelectionByDiff:function(selection,save){var toShow=[];var toHide=[];var dates=selection.GetDates();var oldDates=this.selection.GetDates();var date;for(var i=0;i<dates.length;i++){date=dates[i];if(!this.selection.Contains(date))
toShow.push(date);}
for(var i=0;i<oldDates.length;i++){date=oldDates[i];if(!selection.Contains(date))
toHide.push(date);}
for(var key in this.views){var view=this.views[key];if(view.constructor!=ASPxClientCalendarView)continue;view.UpdateSelection(toHide,false);view.UpdateSelection(toShow,true);}
this.selection.Assign(selection);if(save)
this.SaveClientState();},ImportEtalonStyle:function(info,suffix){var cell=this.GetEtalonStyleCell(suffix);if(_aspxIsExistsElement(cell))
info.Import(cell);},GetEtalonStyleCell:function(name){return this.GetCachedElementById(this.name+"_EC_"+name);},SaveClientState:function(){var element=this.FindStateInputElement();if(element!=null){var state=_aspxGetInvariantDateString(this.visibleDate);if(this.selection.count>0)
state+=":"+this.FormatDates(this.selection.GetDates(),":");element.value=state;}},FormatDates:function(dates,separator){var result="";for(var i=0;i<dates.length;i++){if(result.length>0)
result+=separator;result+=_aspxGetInvariantDateString(dates[i]);}
return result;},InitializeKeyHandlers:function(){this.AddKeyDownHandler(ASPxKey.Enter,"OnEnter");this.AddKeyDownHandler(ASPxKey.Esc,"OnEscape");this.AddKeyDownHandler(ASPxKey.PageUp,"OnPageUp");this.AddKeyDownHandler(ASPxKey.PageDown,"OnPageDown");this.AddKeyDownHandler(ASPxKey.End,"OnEndKeyDown");this.AddKeyDownHandler(ASPxKey.Home,"OnHomeKeyDown");this.AddKeyDownHandler(ASPxKey.Left,"OnArrowLeft");this.AddKeyDownHandler(ASPxKey.Right,"OnArrowRight");this.AddKeyDownHandler(ASPxKey.Up,"OnArrowUp");this.AddKeyDownHandler(ASPxKey.Down,"OnArrowDown");},OnArrowUp:function(evt){if(this.IsFastNavigationActive())
this.GetFastNavigation().OnArrowUp(evt);else if(!this.readOnly){var newDate=this.GetNearestDayForToday();if(_aspxIsExists(this.lastSelectedDate))
newDate=ASPxClientCalendar.GetPrevWeekDate(this.lastSelectedDate);this.CorrectVisibleMonth(newDate,false);this.DoKeyboardSelection(newDate,evt.shiftKey);}
return true;},OnArrowDown:function(evt){if(this.IsFastNavigationActive())
this.GetFastNavigation().OnArrowDown(evt);else if(!this.readOnly){var newDate=this.GetNearestDayForToday();if(_aspxIsExists(this.lastSelectedDate))
newDate=ASPxClientCalendar.GetNextWeekDate(this.lastSelectedDate);this.CorrectVisibleMonth(newDate,true);this.DoKeyboardSelection(newDate,evt.shiftKey);}
return true;},OnArrowLeft:function(evt){if(this.IsFastNavigationActive())
this.GetFastNavigation().OnArrowLeft(evt);else if(!this.readOnly){var newDate=this.GetNearestDayForToday();if(_aspxIsExists(this.lastSelectedDate))
newDate=ASPxClientCalendar.GetTomorrowDate(this.lastSelectedDate);this.CorrectVisibleMonth(newDate,false);this.DoKeyboardSelection(newDate,evt.shiftKey);}
return true;},OnArrowRight:function(evt){if(this.IsFastNavigationActive())
this.GetFastNavigation().OnArrowRight(evt);else if(!this.readOnly){var newDate=this.GetNearestDayForToday();if(_aspxIsExists(this.lastSelectedDate))
newDate=ASPxClientCalendar.GetYesterDate(this.lastSelectedDate);this.CorrectVisibleMonth(newDate,true);this.DoKeyboardSelection(newDate,evt.shiftKey);}
return true;},OnPageUp:function(evt){if(this.IsFastNavigationActive())
this.GetFastNavigation().OnPageUp(evt);else if(!this.readOnly){var newDate=this.GetNearestDayForToday();if(_aspxIsExists(this.lastSelectedDate)){if(evt.ctrlKey)
newDate=ASPxClientCalendar.GetPrevYearDate(this.lastSelectedDate);else
newDate=ASPxClientCalendar.GetPrevMonthDate(this.lastSelectedDate);}
this.CorrectVisibleMonth(newDate,false);this.DoKeyboardSelection(newDate);}
return true;},OnPageDown:function(evt){if(this.IsFastNavigationActive())
this.GetFastNavigation().OnPageDown(evt);else if(!this.readOnly){var newDate=this.GetNearestDayForToday();if(_aspxIsExists(this.lastSelectedDate)){if(evt.ctrlKey)
newDate=ASPxClientCalendar.GetNextYearDate(this.lastSelectedDate);else
newDate=ASPxClientCalendar.GetNextMonthDate(this.lastSelectedDate);}
this.CorrectVisibleMonth(newDate,true);this.DoKeyboardSelection(newDate);}
return true;},OnEndKeyDown:function(evt){if(!this.readOnly&&!this.IsFastNavigationActive()){var newDate=this.GetNearestDayForToday();if(_aspxIsExists(this.lastSelectedDate))
newDate=ASPxClientCalendar.CloneDate(this.lastSelectedDate);newDate=ASPxClientCalendar.GetLastDayInMonthDate(newDate);this.CorrectVisibleMonth(newDate,false);this.DoKeyboardSelection(newDate,evt.shiftKey);}
return true;},OnHomeKeyDown:function(evt){if(!this.readOnly&&!this.IsFastNavigationActive()){var newDate=this.GetNearestDayForToday();if(_aspxIsExists(this.lastSelectedDate))
newDate=ASPxClientCalendar.CloneDate(this.lastSelectedDate);newDate=ASPxClientCalendar.GetFirstDayInMonthDate(newDate);this.CorrectVisibleMonth(newDate,false);this.DoKeyboardSelection(newDate,evt.shiftKey);}
return true;},OnEnter:function(){if(this.IsFastNavigationActive())
this.GetFastNavigation().OnEnter();return true;},OnEscape:function(){if(this.IsFastNavigationActive())
this.GetFastNavigation().OnEscape();return true;},OnShiftMonth:function(offset){if(offset){var date=ASPxClientCalendar.AddMonths(this.visibleDate,offset);this.OnVisibleMonthChanged(date);}},OnDayMouseDown:function(date,shift,ctrl,byWeeks){this.isMouseDown=true;this.selectionByWeeks=byWeeks;this.selectionTransaction.Start();if(this.enableMulti){if(ctrl){this.selectionCtrl=true;this.selectionTransaction.CopyFromBackup();}else
this.selectionCtrl=false;if(shift&&_aspxIsExists(this.selectionPrevStartDate)){this.selectionStartDate=this.selectionPrevStartDate;this.selectionTransaction.selection.AddRange(this.selectionStartDate,date);if(byWeeks)
this.selectionTransaction.selection.AddWeek(date);}else{this.selectionStartDate=date;this.selectionPrevStartDate=date;if(byWeeks)
this.selectionTransaction.selection.AddWeek(date);else
this.selectionTransaction.selection.Add(date);}}else
this.selectionTransaction.selection.Add(date);this.ApplySelectionByDiff(this.selectionTransaction.selection,false);},OnDayMouseOver:function(date){if(this.enableMulti){if(this.selectionCtrl)
this.selectionTransaction.CopyFromBackup();else
this.selectionTransaction.selection.Clear();this.selectionTransaction.selection.AddRange(this.selectionStartDate,date);if(this.selectionByWeeks){this.selectionTransaction.selection.AddWeek(date);this.selectionTransaction.selection.AddWeek(this.selectionStartDate);}}else{this.selectionTransaction.selection.Clear();this.selectionTransaction.selection.Add(date);}
this.ApplySelectionByDiff(this.selectionTransaction.selection,false);},OnDayMouseUp:function(date){if(!__aspxIE&&this.isMouseDown)
this.OnMainElementClick();this.isMouseDown=false;if(this.enableMulti&&this.selectionCtrl&&this.selectionTransaction.backup.Contains(date)&&ASPxClientCalendar.AreDatesEqual(date,this.selectionStartDate)){if(this.selectionByWeeks)
this.selectionTransaction.selection.RemoveWeek(date);else
this.selectionTransaction.selection.Remove(date);}
this.lastSelectedDate=ASPxClientCalendar.CloneDate(date);this.OnSelectionChanging();},OnTodayClick:function(){var now=new Date();var date=new Date(now.getFullYear(),now.getMonth(),now.getDate());if(this.IsDateInRange(date)){this.selectionTransaction.Start();this.selectionTransaction.selection.Add(date);this.OnSelectionChanging();if(!ASPxClientCalendar.AreDatesOfSameMonth(date,this.visibleDate))
this.OnVisibleMonthChanged(date);}},OnClearClick:function(){this.selectionTransaction.Start();this.OnSelectionChanging();this.selectionStartDate=null;this.selectionPrevStartDate=null;this.lastSelectedDate=null;},OnSelectMonth:function(row,column){var txn=this.selectionTransaction;txn.Start();var date=ASPxClientCalendar.CloneDate(this.GetView(row,column).visibleDate);date.setDate(1);do{if(this.IsDateInRange(date))
txn.selection.Add(date);date=ASPxClientCalendar.AddDays(date,1);}while(date.getDate()>1);this.OnSelectionChanging();},OnTitleClick:function(row,column){this.fastNavigation.activeView=this.GetView(row,column);this.fastNavigation.Prepare();this.fastNavigation.Show();},OnMainElementClick:function(){this.SetFocus();this.MainElementClick.FireEvent(this);},OnSelectionChanging:function(){if(!this.SelectionChanging.IsEmpty()){var args=new ASPxClientCalendarSelectionEventArgs(false,this.selectionTransaction.selection);this.SelectionChanging.FireEvent(this,args);}
var changed=this.selectionTransaction.IsChanged();this.selectionTransaction.Commit();if(changed)
this.OnValueChanged();},OnVisibleMonthChanged:function(date){var offsetInternal=ASPxClientCalendar.GetOffsetInMonths(this.visibleDate,date);this.SetVisibleDate(date);var processOnServer=this.RaiseVisibleMonthChanged(offsetInternal);if(processOnServer)
this.SendPostBackInternal("");},OnSelectionCancelled:function(){this.isMouseDown=false;this.selectionTransaction.Rollback();},RaiseValueChangedEvent:function(){var processOnServer=ASPxClientEdit.prototype.RaiseValueChangedEvent.call(this);processOnServer=this.RaiseSelectionChanged(processOnServer);return processOnServer;},SetVisibleDate:function(date){var old=this.visibleDate;this.visibleDate=date;this.SaveClientState();if(!ASPxClientCalendar.AreDatesOfSameMonth(date,old))
this.Update();},SetSelectedDate:function(date){if(this.IsDateInRange(date)){var selection=new ASPxClientCalendarSelection();if(date!=null){selection.Add(date);this.lastSelectedDate=ASPxClientCalendar.CloneDate(date);}
this.ApplySelectionByDiff(selection,true);}},CorrectVisibleMonth:function(newDate,isForwardDirection){var offset=ASPxClientCalendar.GetOffsetInMonths(this.visibleDate,newDate);if(this.IsMultiView()&&offset!=0){var view=isForwardDirection?this.GetView(this.rows-1,this.columns-1):this.GetView(0,0);offset=this.IsDateVisible(newDate)?0:ASPxClientCalendar.GetOffsetInMonths(view.visibleDate,newDate);}
if(!this.IsDateInRange(newDate))
offset=0;if(offset!=0)
this.OnShiftMonth(offset);},DoKeyboardSelection:function(date,shift){if(this.IsDateInRange(date)){this.isDateChangingByKeyboard=true;this.selectionTransaction.Start();if(this.enableMulti&&shift&&_aspxIsExists(this.selectionStartDate))
this.selectionTransaction.selection.AddRange(this.selectionStartDate,date);else{this.selectionTransaction.selection.Add(date);this.selectionStartDate=date;}
this.lastSelectedDate=ASPxClientCalendar.CloneDate(date);this.OnSelectionChanging();this.isDateChangingByKeyboard=false;}},GetNearestDayForToday:function(){var now=new Date();var ret=new Date(now.getFullYear(),now.getMonth(),now.getDate());if(_aspxIsExists(this.minDate)&&!this.IsDateInRange(ret))
ret=ASPxClientCalendar.CloneDate(this.minDate);return ret;},GetSelectedDate:function(){return this.GetValue();},GetVisibleDate:function(){return this.visibleDate;},SelectDate:function(date){if(_aspxIsExists(date)){this.selection.Add(date);this.Update();}},SelectRange:function(start,end){if(_aspxIsExists(start)&&_aspxIsExists(end)){this.selection.AddRange(start,end);this.Update();}},DeselectDate:function(date){if(_aspxIsExists(date)){this.selection.Remove(date);this.Update();}},DeselectRange:function(start,end){if(_aspxIsExists(start)&&_aspxIsExists(end)){this.selection.RemoveRange(start,end);this.Update();}},ClearSelection:function(){this.selection.Clear();this.Update();},GetSelectedDates:function(){return this.selection.GetDates();},RaiseSelectionChanged:function(processOnServer){if(!this.SelectionChanged.IsEmpty()){var args=new ASPxClientProcessingModeEventArgs(processOnServer);this.SelectionChanged.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;},RaiseVisibleMonthChanged:function(offsetInternal){var processOnServer=this.autoPostBack;if(!this.VisibleMonthChanged.IsEmpty()){var args=new ASPxClientProcessingModeEventArgs(processOnServer);args.offsetInternal=offsetInternal;this.VisibleMonthChanged.FireEvent(this,args);processOnServer=args.processOnServer;}
return processOnServer;},ChangeEnabledAttributes:function(enabled){_aspxChangeDocumentEventsMethod(enabled)("mouseup",aspxCalDocMouseUp);_aspxChangeEventsMethod(enabled)(this.GetMainElement(),"click",new Function("aspxCalMainElemClick('"+this.name+"');"));var inputElement=this.GetInputElement();if(_aspxIsExists(inputElement))
this.ChangeSpecialInputEnabledAttributes(inputElement,_aspxChangeEventsMethod(enabled));var btnElement=this.GetTodayButton();if(_aspxIsExists(btnElement))
this.ChangeButtonEnabledAttributes(btnElement,_aspxChangeAttributesMethod(enabled));btnElement=this.GetClearButton();if(_aspxIsExists(btnElement))
this.ChangeButtonEnabledAttributes(btnElement,_aspxChangeAttributesMethod(enabled));for(var key in this.views){var view=this.views[key];if(view.constructor!=ASPxClientCalendarView)continue;view.ChangeEnabledAttributes(enabled);}},ChangeEnabledStateItems:function(enabled){aspxGetStateController().SetElementEnabled(this.GetMainElement(),enabled);var btnElement=this.GetTodayButton();if(_aspxIsExists(btnElement))
aspxGetStateController().SetElementEnabled(btnElement,enabled);btnElement=this.GetClearButton();if(_aspxIsExists(btnElement))
aspxGetStateController().SetElementEnabled(btnElement,enabled);for(var key in this.views){var view=this.views[key];if(view.constructor!=ASPxClientCalendarView)continue;view.ChangeEnabledStateItems(enabled);}
this.UpdateInternal();},ChangeButtonEnabledAttributes:function(element,method){method(element,"onclick");method(element,"ondblclick");}});ASPxClientCalendar.AreDatesEqual=function(date1,date2){if(date1==date2)
return true;if(!date1||!date2)
return false;return date1.getFullYear()==date2.getFullYear()&&date1.getMonth()==date2.getMonth()&&date1.getDate()==date2.getDate();}
ASPxClientCalendar.AreDatesOfSameMonth=function(date1,date2){if(!date1||!date2)
return false;return date1.getFullYear()==date2.getFullYear()&&date1.getMonth()==date2.getMonth();}
ASPxClientCalendar.GetUTCTime=function(date){return Date.UTC(date.getFullYear(),date.getMonth(),date.getDate());}
ASPxClientCalendar.GetFirstDayOfYear=function(date){return new Date(date.getFullYear(),0,1);}
ASPxClientCalendar.GetDayOfYear=function(date){var ms=ASPxClientCalendar.GetUTCTime(date)-
ASPxClientCalendar.GetUTCTime(ASPxClientCalendar.GetFirstDayOfYear(date));return 1+Math.floor(ms/__aspxCalendarMsPerDay);}
ASPxClientCalendar.GetISO8601WeekOfYear=function(date){var firstDate=new Date(date.getFullYear(),0,1);var firstDayOfWeek=firstDate.getDay();if(firstDayOfWeek==0)
firstDayOfWeek=7;var daysInFirstWeek=8-firstDayOfWeek;var lastDate=new Date(date.getFullYear(),11,31);var lastDayOfWeek=lastDate.getDay();if(lastDayOfWeek==0)
lastDayOfWeek=7;var daysInLastWeek=8-lastDayOfWeek;var fullWeeks=Math.ceil((ASPxClientCalendar.GetDayOfYear(date)-daysInFirstWeek)/7);var result=fullWeeks;if(daysInFirstWeek>3)
result++;var isThursday=firstDayOfWeek==4||lastDayOfWeek==4;if(result>52&&!isThursday)
result=1;if(result==0)
return ASPxClientCalendar.GetISO8601WeekOfYear(new Date(date.getFullYear()-1,11,31));return result;}
ASPxClientCalendar.GetNextWeekDate=function(date){var ret=new Date(date.getTime());var newDay=date.getDate()+7;ret.setDate(newDay);return ret;}
ASPxClientCalendar.GetPrevWeekDate=function(date){var ret=new Date(date.getTime());var newDay=date.getDate()-7;ret.setDate(newDay);return ret;}
ASPxClientCalendar.GetTomorrowDate=function(date){var ret=new Date(date.getTime());ret.setDate(ret.getDate()-1);return ret;}
ASPxClientCalendar.GetYesterDate=function(date){var ret=new Date(date.getTime());ret.setDate(ret.getDate()+1);return ret;}
ASPxClientCalendar.GetNextMonthDate=function(date){var ret=new Date(date.getTime());var maxDateInNextMonth=ASPxClientCalendar.GetDaysInMonth(ret.getMonth()+1,ret.getFullYear());if(ret.getDate()>maxDateInNextMonth)
ret.setDate(maxDateInNextMonth);ret.setMonth(ret.getMonth()+1);return ret;}
ASPxClientCalendar.GetNextYearDate=function(date){var ret=new Date(date.getTime());var maxDateInPrevYearMonth=ASPxClientCalendar.GetDaysInMonth(ret.getMonth(),ret.getFullYear()+1);if(ret.getDate()>maxDateInPrevYearMonth)
ret.setDate(maxDateInPrevYearMonth);ret.setFullYear(ret.getFullYear()+1);return ret;}
ASPxClientCalendar.GetPrevMonthDate=function(date){var ret=new Date(date.getTime());var maxDateInPrevMonth=ASPxClientCalendar.GetDaysInMonth(ret.getMonth()-1,ret.getFullYear());if(ret.getDate()>maxDateInPrevMonth)
ret.setDate(maxDateInPrevMonth);ret.setMonth(ret.getMonth()-1);return ret;}
ASPxClientCalendar.GetPrevYearDate=function(date){var ret=new Date(date.getTime());var maxDateInPrevYearMonth=ASPxClientCalendar.GetDaysInMonth(ret.getMonth(),ret.getFullYear()-1);if(ret.getDate()>maxDateInPrevYearMonth)
ret.setDate(maxDateInPrevYearMonth);ret.setFullYear(ret.getFullYear()-1);return ret;}
ASPxClientCalendar.GetFirstDayInMonthDate=function(date){var ret=new Date(date.getTime());ret.setDate(1);return ret;}
ASPxClientCalendar.GetLastDayInMonthDate=function(date){var ret=new Date(date.getTime());var maxDateInYearMonth=ASPxClientCalendar.GetDaysInMonth(ret.getMonth(),ret.getFullYear());ret.setDate(maxDateInYearMonth);return ret;}
ASPxClientCalendar.AddDays=function(date,count){var newDate=ASPxClientCalendar.CloneDate(date);newDate.setUTCDate(count+newDate.getUTCDate());var offset=newDate.getTimezoneOffset()-date.getTimezoneOffset();if(offset>0)
newDate.setMinutes(newDate.getMinutes()+offset);return newDate;}
ASPxClientCalendar.AddMonths=function(date,count){var newDate=ASPxClientCalendar.CloneDate(date);newDate.setMonth(count+newDate.getMonth());if(newDate.getDate()<date.getDate())
newDate=ASPxClientCalendar.AddDays(newDate,-newDate.getDate());return newDate;}
ASPxClientCalendar.CloneDate=function(date){var cloned=new Date();cloned.setTime(date.getTime());return cloned;}
ASPxClientCalendar.GetDecadeStartYear=function(year){return 10*Math.floor(year/10);}
ASPxClientCalendar.GetDaysInRange=function(start,end){return 1+(ASPxClientCalendar.GetUTCTime(end)-ASPxClientCalendar.GetUTCTime(start))/__aspxCalendarMsPerDay;};ASPxClientCalendar.GetDaysInMonth=function(month,year){var d=new Date(year,month+1,0);return d.getDate();};ASPxClientCalendar.GetOffsetInMonths=function(start,end){return end.getMonth()-start.getMonth()+12*(end.getFullYear()-start.getFullYear());};ASPxClientCalendarSelection=_aspxCreateClass(null,{constructor:function(){this.dates={};this.count=0;},Assign:function(source){this.Clear();for(var key in source.dates){var item=source.dates[key];if(item.constructor!=Date)continue;this.Add(item);}},Clear:function(){if(this.count>0){this.dates={};this.count=0;}},Equals:function(selection){if(this.count!=selection.count)
return false;for(var key in this.dates){if(this.dates[key].constructor!=Date)continue;if(!selection.ContainsKey(key))
return false;}
return true;},Contains:function(date){var key=this.GetKey(date);return this.ContainsKey(key);},ContainsKey:function(key){return _aspxIsExists(this.dates[key]);},Add:function(date){var key=this.GetKey(date);if(!this.ContainsKey(key)){this.dates[key]=ASPxClientCalendar.CloneDate(date);this.count++;}},AddArray:function(dates){for(var i=0;i<dates.length;i++)
this.Add(dates[i]);},AddRange:function(start,end){if(end<start){this.AddRange(end,start);return;}
var count=ASPxClientCalendar.GetDaysInRange(start,end);var date=ASPxClientCalendar.CloneDate(start);for(var i=0;i<count;i++){this.Add(date);date=ASPxClientCalendar.AddDays(date,1);}},AddWeek:function(startDate){this.AddRange(startDate,ASPxClientCalendar.AddDays(startDate,6));},Remove:function(date){var key=this.GetKey(date);if(this.ContainsKey(key)){delete this.dates[key];this.count--;}},RemoveArray:function(dates){for(var i=0;i<dates.length;i++)
this.Remove(dates[i]);},RemoveRange:function(start,end){if(end<start){this.RemoveRange(end,start);return;}
var count=ASPxClientCalendar.GetDaysInRange(start,end);var date=ASPxClientCalendar.CloneDate(start);for(var i=0;i<count;i++){this.Remove(date);date=ASPxClientCalendar.AddDays(date,1);}},RemoveWeek:function(startDate){this.RemoveRange(startDate,ASPxClientCalendar.AddDays(startDate,6));},GetDates:function(){var result=[];for(var key in this.dates){var item=this.dates[key];if(item.constructor!=Date)continue;result.push(ASPxClientCalendar.CloneDate(item));}
return result;},GetFirstDate:function(){if(this.count==0)
return null;for(var key in this.dates){var item=this.dates[key];if(item.constructor!=Date)continue;return ASPxClientCalendar.CloneDate(item);}
return null;},GetKey:function(date){return _aspxGetInvariantDateString(date);}});ASPxClientCalendarSelectionTransaction=_aspxCreateClass(null,{constructor:function(calendar){this.calendar=calendar;this.isActive=false;this.backup=new ASPxClientCalendarSelection();this.selection=new ASPxClientCalendarSelection;},Start:function(){if(this.isActive)
this.Rollback();this.backup.Assign(this.calendar.selection);this.selection.Clear();this.isActive=true;__aspxActiveCalendar=this.calendar;},Commit:function(){this.calendar.ApplySelectionByDiff(this.selection,true);this.Reset();},Rollback:function(){this.calendar.ApplySelectionByDiff(this.backup);this.Reset();},Reset:function(){this.backup.Clear();this.selection.Clear();this.isActive=false;__aspxActiveCalendar=null;},CopyFromBackup:function(){this.selection.Assign(this.backup);},IsChanged:function(){return!this.backup.Equals(this.selection);}});ASPxClientCalendarView=_aspxCreateClass(null,{constructor:function(calendar,row,column){this.row=row;this.column=column;this.calendar=calendar;var temp=column+row;this.isLowBoundary=temp==0;this.isHighBoundary=temp==calendar.rows+calendar.columns-2;this.visibleDate=null;this.startDate=null;this.dayFunctions={};this.dayFunctionsWithWeekSelection={};},Initialize:function(){this.dayCellCache={};this.dayStyleCache={};this.UpdateDate();this.UpdateSelection(this.calendar.selection.GetDates(),true);var cell=this.GetMonthCell();if(_aspxIsExistsElement(cell))
_aspxPreventElementDragAndSelect(cell,false);},AttachMouseEvents:function(eventMethod,styleMethod){var index;var cell;if(this.calendar.showDayHeaders){var headCells=this.GetMonthTable().rows[0].cells;var dayNameIndex=0;if(this.calendar.showWeekNumbers){dayNameIndex++;cell=headCells[0];if(this.calendar.enableMulti){eventMethod(cell,"click",new Function("aspxCalSelectMonth('"+this.calendar.name+"', "+this.row+", "+this.column+")"));styleMethod(cell,"cursor",_aspxGetPointerCursor());}
this.AttachCancelSelect(eventMethod,cell);}
for(var j=0;j<7;j++)
this.AttachCancelSelect(eventMethod,headCells[dayNameIndex++]);}
for(var i=0;i<__aspxCalendarWeekCount;i++){if(this.calendar.showWeekNumbers){cell=this.GetWeekNumberCell(i);if(this.calendar.enableMulti)
this.AttachDayMouseEvents(eventMethod,cell,this.GetDayMouseEventFunction(7*i,true));else
this.AttachCancelSelect(eventMethod,cell);}
var date;for(var j=0;j<7;j++){index=i*7+j;cell=this.GetDayCell(index);date=this.GetDateByIndex(index);if(!this.calendar.enableMulti&&this.IsDa
