PageSourceSearch

https://school120nn.ru/.s/src/uwnd.min.js

js school120nn.ru collected 2026-09-30 11:29:45 UTC 213,693 bytes, 1 lines download raw bytes

1function _uFocus(t){t||(t={}),this.constructor=_uFocus,this._tp=t.type||0,this._thispar=t.thispar||null,this._param=t.param||null,this._parent=t.parent||null,delete t.type,delete t.thispar,delete t.param,delete t.parent,this.owner=null,$.extend(this,t||{}),this.destroyed=0,_uFocus.globalset||(_uFocus.globalset=!0,$(document).on("keydown keyup keypress",_uFocus._onkey)),2==this._tp&&_uFocus.glisteners.push(this)}function _uGetOffset(t){if(!t)return{left:0,top:0};var e=t.offsetLeft,s=t.offsetTop;if(e||s||null!=t.offsetParent)for(;null!=(t=t.offsetParent);)e+=t.offsetLeft,s+=t.offsetTop;else e=parseInt(t.style.left),s=parseInt(t.style.top);return{left:e,top:s}}function _uMenu(t,e,s){this.init(t,e,s)}function _uMENU(t,e={},s={},i=[],o){this.constructor=_uMENU,this.name=t,this.pos=Object.assign({pos:null,alignObj:null,align:"d",parent:null,parentfocus:null,dx:0,dy:0,childdy:0,childdx:0},e),this.props=Object.assign({parentnode:s.wnd?s.wnd.top:null,design:_uMENU.defdesign||"std",hidden:s.statical&&i&&i.length>0?0:1,shadow:1,addclass:"",withmarks:null,highlight:1,statical:s.horiz?1:0,hidetimer:0,horiz:0,noabs:0,width:0,onshow:s.onshow?s.onshow:null,onhide:s.onhide?s.onhide:null,ondestroy:null,onitem:null,onldown:null,onrdown:null,thispar:null,onreadycreate:null,wnd:null,rtl:0,flatStructure:0},s),this.state={visible:!1,init:!1,destroyed:!1},this.design=_uMENU.designs[this.props.design]||_uMENU.designs.std,this.idx=_uMENU.nextidx++,_uMENU.all[this.idx]=this,this.pos.parent?this.zpos=this.pos.parent.zpos+5:this.zpos=_uMENU.defz,this.xpos=this.ypos=0,this.width=10,this.height=10,this.elems=[],this.add_elems=i&&i.length>0?[i]:[],this.del_elems=[],this.pend_show=null,this.appendtimer=null,this.decor={w:0,h:0},this.frame=null,this.childtimer=null,this.sh=null,this.hidetimer=null,this.hlitem=-1,this.have_active=null,this._focus=new _uFocus({type:1,thispar:this,owner:this,parent:this.pos.parentfocus?this.pos.parentfocus:this.pos.parent?this.pos.parent._focus:this.props.wnd?this.props.wnd._focus:null,onkeydown:this.onkeydown,ondeactivate:this.onfocusdeactivate});var a=document.createElement("div");a.id="_umenu"+this.idx,this.props.parentnode?this.props.parentnode.appendChild(a):$($("body")[0]).prepend(a),this.top=a,$(a).addClass("x-unselectable").css({visibility:"hidden",display:"block"});var n=document.createElement("div");a.appendChild(n),this.menu=n,this.havefixed=1,this.props.noabs||($(a).css({position:"absolute",zIndex:this.zpos}),$(n).css({position:"absolute",zIndex:2,left:0})),$(n).css("width","50px").on("mousedown",this,_uMENU._onmenumousedown),this.parts=this.design.menu_init(n,this.props.horiz?10:50,this.props,this.pos.parent),_uMENU.globalset||(_uMENU.globalset=!0,$(document).on("mousedown",_uMENU.hideallmenus),$(window).on("resize",_uMENU.hideallmenus)),this.toinit=[],this.tocalcsize=[],this.createsubmenus(),this.props.hidden||this.show(),o||setTimeout("var _um=_uMENU.all["+this.idx+"]; if (_um)_um.init1();",10)}function _uComboBox(t,e,s,i,o){if(this.constructor=_uComboBox,this.name=t,this.obj=e&&e.tagName?e:$("#"+e)[0],!this.obj)return null;var a;(this.obj._ucombobox=this,this.props=$.extend({design:"std",readonly:!1,haveicons:-1,deficon:null,listwidth:"auto",maxlistheight:"auto",colwidth:null,filter:0,nomatchtext:"",prompt:"",nodropdown:0,emptyprompt:"",filtertype:0,filtermax:0,haveotherprompt:"",translit:0,filtermarkclass:"",onchange:null,wnd:null,parentnode:s.wnd?s.wnd.top:null,app:s.wnd&&s.wnd.app?s.wnd.app:this,rtl:window._rtl},s||{}),this.props.readonly||(this.props.nodropdown=0),this.props.parentnode)?(this.parent=this.props.parentnode,(a=_uTabCtrl.findparentcontent(this.obj))?$(a).on("scroll",this,function(t){t.data.destroyed||t.data.hidelist()}):this.props.wnd&&$(this.props.wnd.parts.wndcont).on("scroll",this,function(t){t.data.destroyed||t.data.hidelist()})):(a=_uTabCtrl.findparentcontent(this.obj))?this.parent=a:(a=_uWnd.findparent(this.obj))?(this.parent=a.top,$(a.parts.wndcont).on("scroll",this,function(t){t.data.destroyed||t.data.hidelist()})):this.parent=this.obj.parentNode;this.havemaxheight=0;var n=this.obj.ownerDocument?this.obj.ownerDocument.defaultView:null;n&&n.getComputedStyle?("static"===n.getComputedStyle(this.parent,null).position&&(this.parent.style.position="relative"),null!=n.getComputedStyle(this.parent,null).maxHeight&&(this.havemaxheight=1)):("static"===this.parent.currentStyle.position&&(this.parent.style.position="relative"),null!=this.parent.currentStyle.maxHeight&&(this.havemaxheight=1),this.parent.style.zoom=1),this.app=this.props.app,this.tablecols=i<=0?1:i,this.colwidth=this.props.colwidth||[],this.destroyed=!1,this.design=this.props.design&&_uComboBox.designs[this.props.design]?_uComboBox.designs[this.props.design]:_uComboBox.designs.std,this.idx=_uComboBox.nextidx++,_uComboBox.all[this.idx]=this,this.tablemode=this.tablecols>1||!this.props.filter?1:0,this.data=[],this.numdata=0,this.dataindex=0,this.prevfilter=-1,this.prevfilteridx=-2,o||(o=[]);for(var r=-1,l=0;l<o.length;l++)r<0&&o[l][2]&&(r=l);if(this.isprompt=0,this.prompttxt="",this.userInput=this.prevInput=this.obj.value,this.props.readonly?(this.prompttxt=this.props.prompt,this.props.filter?this.obj.readOnly=!1:this.obj.readOnly=!0,this.valobj=$('<input type="hidden" name="'+this.obj.name+'" value="">')[0],this.obj.removeAttribute("name"),(r<0||r>=o.length)&&(this.props.filter||this.prompttxt||(r=0),r=-1)):(this.obj.readOnly=!1,this.valobj=this.obj,(r<0||r>=o.length)&&(r=-1)),this.selected=this.userIdx=r,this.changetimer=null,this.haveicons=this.props.haveicons>0,this.props.haveicons<0)for(l=0;l<o.length;l++)if(o[l][1]){this.haveicons=!0;break}this.frame=null,this.opened=!1,this.updated=!0,this.showtimer=null,this.blurtimer=null,this.cancelblur=!1,this.combo=null;var h=document.createElement("div");
1h.id="_ucombolist"+this.idx,this.toplist=h,$(h).css({position:"absolute",zIndex:5,display:"none"}),this.parts=this.design.combo_init(this),this.focused=0,$(this.obj).attr("autocomplete","off").blur().on("focus",this,_uComboBox._onobjfocus).on("blur",this,_uComboBox._onobjblur).on("beforedeactivate",this,_uComboBox._onobjdeact).on("keydown",this,function(t){return t.data.onkeydown(t)}).on("keyup",this,function(t){return t.data.onkeyup(t)}),$(this.combo).on("mousedown",this,_uComboBox._oncombomousedown),$(this.toplist).on("mousedown",this,_uComboBox._onlistmousedown);for(l=0;l<o.length;l++)this.appendItem(o[l]);_uComboBox.globalset||(_uComboBox.globalset=!0,$(window).on("resize",_uComboBox.hideall)),this.props.filter&&"_auto_"==this.userInput&&(this.userInput=this.prevInput=r<0?"":this.data[r][2]),this.updatelist(),this.select(r),this.to_unHL=[]}function _uSuggestList(t,e,s,i){if(this.constructor=_uSuggestList,this.name=t,this.obj="string"==typeof e?$("#"+e)[0]:e,!this.obj)return null;this.obj._uSuggestList=this,this.props=$.extend({design:"std",cachegroup:"def",minlen:2,url:null,separator:null,compareFunc:null,preserveonout:0,showalways:0,emptyprompt:"...",dataType:"text",useDataObj:null,haveDataId:0,emptyDataId:0,onchange:null,onselect:null,wnd:null,parentnode:s.wnd?s.wnd.top:null,app:s.wnd&&s.wnd.app?s.wnd.app:null},s||{}),this.destroyed=!1,this.design=this.props.design&&_uSuggestList.designs[this.props.design]?_uSuggestList.designs[this.props.design]:_uSuggestList.designs.std,this.idx=_uSuggestList.nextidx++,_uSuggestList.all[this.idx]=this,this.cacheGroup=this.props.cachegroup,this.queryCache[this.cacheGroup]||(this.queryCache[this.cacheGroup]=[]),i&&(this.queryCache[this.cacheGroup]=i),this.props.haveDataId?this.dataobj="string"==typeof this.props.useDataObj?$("#"+this.props.useDataObj)[0]:this.props.useDataObj:this.dataobj=null,this.dataid=this.props.emptyDataId,this.visible=!0,this.hlIndex=-1,this.saIndex=-1,this.hlRow=null,this.blockMouseOver=!1,this.previousInput=this.obj.value,this.resultInput="",this.requestedInput="",this.ignoreInput="",this.sep_pos=-1,this.userInput=this._getvalue_sep(),this.remoteReqTimer=null,this.hideTimer=null,this.AJAXretries=0,this.AJAXTimer=null,this.frame=null;var o,a=document.createElement("div");(a.id="_usuggest"+this.idx,this.top=a,this.props.parentnode)?(this.parent=this.props.parentnode,this.parent.appendChild(a),(o=_uTabCtrl.findparentcontent(this.obj))?$(o).on("scroll",this,function(t){t.data.destroyed||t.data.onblur(null)}):this.props.wnd&&$(this.props.wnd.parts.wndcont).on("scroll",this,function(t){t.data.destroyed||t.data.onblur(null)})):(o=_uTabCtrl.findparentcontent(this.obj))?(this.parent=o,this.parent.appendChild(a)):(o=_uWnd.findparent(this.obj))?(this.parent=o.top,this.parent.appendChild(a),$(o.parts.wndcont).on("scroll",this,function(t){t.data.destroyed||t.data.onblur(null)})):(this.parent=this.obj.parentNode,this.parent.insertBefore(a,this.obj));var n=this.obj.ownerDocument?this.obj.ownerDocument.defaultView:null;n&&n.getComputedStyle?"static"===n.getComputedStyle(this.parent,null).position&&(this.parent.style.position="relative"):"static"===this.parent.currentStyle.position&&(this.parent.style.position="relative"),$(a).css({position:"absolute",zIndex:5,display:"none",zoom:1}),this.parts=this.design.suggest_init(this),$(this.obj).attr("autocomplete","disabled").css("position","relative").on("focus",this,function(t){return t.data.onfocus(t)}).on("blur",this,function(t){return t.data.onblur(t)}).on("keydown",this,function(t){return t.data.onkeydown(t)}).on("mousedown",this,function(t){_uSuggestList.ignoreclick=t.data}).on("keyup",this,function(t){return t.data.onkeyup(t)}),_uSuggestList.globalset||(_uSuggestList.globalset=!0,$(window).on("resize",_uSuggestList.hideall)),this.hide(),this.obj.form&&$(this.obj.form).on("submit."+this.idx,this,function(t){return t.data.onsubmitform(t)})}function _uDraggable(t,e,s,i,o){this.par=t,this.x=this.y=this.w=this.h=this.m=0,this.moved=!1,this.active=!1,this.onmove=e||_uDraggable.dummy,this.oninitdrag=s||_uDraggable.dummy,this.onstartdrag=i||_uDraggable.dummy,this.onstopdrag=o||_uDraggable.dummy,_uDraggable.globalset||(_uDraggable.globalset=!0,$(document).on("mouseup",_uDraggable.onmouseup),$(document).on("mousemove",_uDraggable.onmousemove))}function _uSlider(t,e,s,i,o){if(s!=i&&(this.slider="object"!=typeof t?$("#"+t)[0]:t,this.slider)){if(this.slider._uslider=this,this.type="v"==e.substr(0,1).toLowerCase()?"v":"h",this.props=$.extend({step:0,initval:(s+i)/2,disabled:0,minpos:0,maxpos:null,hotspot:null,thispar:null,onchange:null,param:null},o||{}),this.disabled=!!this.props.disabled,this.min_value=s,this.max_value=i,this.step=Math.abs(this.props.step),this.value=0,this.min_pos=this.props.minpos,null!=this.props.maxpos)this.max_pos=this.props.maxpos;else{var a=this.slider.parentNode;this.max_pos=a?"h"==this.type?a.offsetWidth-this.slider.offsetWidth:a.offsetHeight-this.slider.offsetHeight:1}null!=this.props.hotspot?this.hotoff=this.props.hotspot:this.hotoff="h"==this.type?Math.floor(this.slider.offsetWidth/2):Math.floor(this.slider.offsetHeight/2),this.min_pos==this.max_pos&&(this.max_pos=this.min_pos+1),this.pos=0,this.setValue(this.props.initval),this.drag=new _uDraggable(this,this._ondrag,null,null,this._ondragstop),$(this.slider).off("onmousemove mousedown").on("onmousemove",_uSlider._onmousemove).on("mousedown",this,_uSlider._onmousedown),this.slider.parentNode&&$(this.slider.parentNode).off("mousedown").on("mousedown",this,_uSlider._onmousedownparent)}}function _uTabCtrl(t,e,s,i,o,a){this.constructor=_uTabCtrl,this.name=t,this.ntabs=e,this.props=$.extend({parentnode:null,wnd:null,app:s&&s.wnd&&s.wnd.app||null,width:"auto",height:"auto",min_height:50,active_tab:-1,align:"left",close:0,design:"std",noinit:!1,notabs:!1,markload:'<div align="left"><div class="myWinLoad"></div></div>',emptycontent:"",onload:null,onshow:null,onhide:null,onerror:null,onbeforechange:null,onchange:null,onbeforeclose:null,onclose:null,ondestroy:null,onresize:null,rtl:0},s||{}),this.app=this.props.app,this.state={init:!1,destroyed:!1},this.design=this.props.design&&_uTabCtrl.designs[this.props.design]?_uTabCtrl.designs[this.props.design]:_uTabCtrl.designs.std,this.idx=_uTabCtrl.nextidx++,_uTabCtrl.all[this.idx]=this,this.width=parseInt(this.props.width)||0,this.height=parseInt(this.props.height)||0,this.data=[],this.pend_show=null,this.decor={cdw:0,cdh:0,pdw:0,pdh:0,ph:0},this.maxid=0,this.wnd=null,this.scrollpos={tabswidth:0,havewidth:0,pos:null};for(var n=0;n<e;n++){var r=a&&a[n]||{},l=r.id||"";l&&0!=l.length||(l="_tc"+this.idx+"tb"+this.maxid++),this.data[n]={id:l,title:i&&i[n]||".",dat:o&&o[n]||"",footer:r.footerc||null,footerh:r.footerh&&r.footerh>0?r.footerh:0,header:r.headerc||null,headerh:r.headerh&&r.headerh>0?r.headerh:0,footercont:null,headercont:null,cont:null,ismarkload:0,iserrorload:0,markloadcont:null,obj:null,ishidden:r.hidden,clbut:null,link:null,href:r.href,target:r.target,label:null,align:null==r.align?this.props.align:r.align,close:null==r.close?this.props.close:r.close,icon:r.icon,iconstyle:r.iconstyle,markload:r.markload,firstload:0,firstshow:0,xmlobj:null,xmlobj_ignoreabort:0,onload:null==r.onload?this.props.onload:r.onload,onerror:null==r.onerror?this.props.onerror:r.onerror,onshow:null==r.onshow?this.props.onshow:r.onshow,onhide:null==r.onhide?this.props.onhide:r.onhide,onbeforechange:null==r.onbeforechange?this.props.onbeforechange:r.onbeforechange,onchange:null==r.onchange?this.props.onchange:r.onchange,onbeforeclose:null==r.onbeforeclose?this.props.onbeforeclose:r.onbeforeclose,onclose:null==r.onclose?this.props.onclose:r.onclose}}this.active_tab="auto"==this.props.active_tab?"auto":this.idxbyid(this.props.active_tab),this.sesupdate=0,_uTabCtrl.globalset||(_uTabCtrl.globalset=!0),this.butdown=new _uDraggable(this,null,null,null,function(t,e){this.design._onbuttonup(this,t,e)}),this.props.noinit||this.init()}function _uWnd(t,e,s,i,o,a,n,r){if(t&&t.length>0){var l=_uWnd.getbyname(t);if(l)return o&&o.attachobj&&l.attachTo(o.attachobj,o.attachtype,o.attachdx,o.attachdy),l.props.reloadonnew?l.reload(a):l.show(),!1}if(this.constructor=_uWnd,this.desktop=this.opts&&this.opts.desktop||_uWnd.defde
1sktop,this.props=$.extend({parent:null,popup:0,alert:0,closeonesc:o.popup?1:0,nohide:0,reloadonnew:o.attachobj?0:1,x:"auto",y:"auto",attachobj:null,attachdx:0,attachdy:0,attachtype:null,initstate:null,headerh:0,headerc:null,hideheader:1,footerh:0,footerc:null,hidefooter:1,contentsizeprio:o.footerh>0||o.headerh>0?1:0,nomove:o.attachobj?1:0,hideonmove:1,center:o.modal?1:0,session:null,hidden:0,modal:0,toolwindow:0,resize:o.toolwindow||o.attachobj?0:1,fixed:_uWnd.defdesktop||o.desktop?0:1,minh:50,minw:0,maxh:0,maxw:0,autosize:o.toolwindow||o.attachobj?0:1,autosizestep:o.autosizestep>=1?o.autosizestep:10,autosizestepmult:o.autosizestepmult>0?o.autosizestepmult:1,autosizestepmultmult:1,autosizewidth:0,autosizeonimages:0,waitimages:0,hideonresize:0,hidehonresize:o.hideonresize,hidefonresize:o.hideonresize,havesysmenu:_uWnd.havesysmenu,attachicon:null,attachicontype:"",attachicondelta:2,attachiconact:"hide",icon:"",incostyle:null,header:e?1:0,min:this.desktop&&!(o.notaskbar||o.parent||o.toolwindow||o.alert||o.modal||o.attachobj)?1:0,max:!this.desktop||o.modal||o.attachobj?0:1,close:1,customButtons:null,notaskbar:o.parent||o.toolwindow||o.alert||o.modal||o.attachobj?1:0,align:"start",shadow:o.toolwindow?0:1,design:"std",topclass:null,gridclass:"myWinGrid",gridblur:null,fadetype:o.toolwindow||o.modal||o.attachobj?0:1,fadespeed:800,fadeclosetype:o.toolwindow||o.modal||o.attachobj?0:1,fadeclosespeed:250,havemenu:n?1:0,menuopts:null,trayicon:null,traymenu:null,actlayer:0,markload:'<div align="left"><div class="wait-loader"></div></div>',havegrid:0,markwaitcont:'<div class="myWinLoad"></div>',markwaitclass:"myWinGrid",oninit:null,oncontent:null,onafterimgload:null,onposchange:null,onactivate:null,ondeactivate:null,onerror:null,onbeforeclose:null,onclose:null,desktop:null,notabdestroy:0,fitToViewport:0,noscale:!1},o||{}),this.props.modal){const t=window.innerWidth-document.documentElement.clientWidth;document.documentElement.style.setProperty("--ucoz-scrollbar-width",`${t}px`)}(this.props.modal||this.props.toolwindow)&&(this.props.min=0),this.props.toolwindow&&(this.props.max=0),this.props.session&&(this.props.x=this.props.session.x,this.props.y=this.props.session.y),this.modalparent=this.props.parent&&(this.props.parent.props.modal&&!this.props.parent.props.parent||this.props.parent.modalparent)?1:0;const h=_uWnd.getdims(),d=s&&Math.abs(s)>10?o.noscale||"undefined"==typeof uwnd_scale?s:Math.ceil(s*uwnd_scale.w):-300;$.extend(this,{name:t,title:e||"",letsize:1,width:this.props.fitToViewport&&h.clientW<d?h.clientW-16:d,height:i&&Math.abs(i)>10?!o.noscale&&o.alert&&"undefined"!=typeof uwnd_scale?Math.ceil(i*uwnd_scale.h):i:-200,headerh:this.props.headerc&&this.props.headerh>=0?this.props.headerh:0,footerh:this.props.footerc&&(this.props.footerh>=0||"auto"==this.props.footerh)?this.props.footerh:0,decor:{w:0,h:0,th:0},_content:a,state:{visible:!1,prevvisible:!1,minimized:!1,maximized:!1,loaded:!1,init:!1,disabled:!1,grided:!1,nosh
1adow:!1,resizing:!1,destroyed:!1,focused:!1},xmlobj:null,xmlobj_ignoreabort:0,grid:null,frame:null,sh:null,sh_sz:[4,2],xpos:0,ypos:0,zpos:this.props.modal||this.props.alert||this.modalparent?_uWnd.getModalTopZ():_uWnd.getTopZ(),_drag:new _uDraggable(this,this._ondragmousemove,null,this.onstartdrag,this.onstopdrag),_resize:new _uDraggable(this,this._onrsmousemove,null,this.onstartrs,this.onstoprs),restRect:null,minheight:this.props.minh,minwidth:this.props.minw,maxheight:this.props.maxh,maxwidth:this.props.maxw,pend_show:null,autosz:{active:!1},imgloader:{timer:null,active:!1},menu:null,app:r||null,savedfocus:null,childs:[],nchilds:0,tabctrl:null,attachicon:"",sesupdate:0}),this.design=this.props.design&&_uWnd.designs[this.props.design]||_uWnd.designs.std,this.idx=_uWnd.nextidx++,_uWnd.all[this.idx]=this,this._focus=new _uFocus({type:0,owner:this,thispar:this,parent:this.props.parent&&this.props.toolwindow?this.props.parent._focus:this.app&&this.app._focus?this.app._focus:null,onkeydown:this._onkeydown,onkeypress:this._onkeypress,onactivate:this._onactivate,ondeactivate:this._ondeactivate,canactivate:this._canactivate}),this.havefixed=1,_uWnd.globalset||(_uWnd.globalset=!0,$(document).on("mousedown",_uWnd.closepopup),$(window).on("scroll",_uWnd._onscroll),$(window).on("resize",_uWnd._onresize),_uWnd.sysmenu=new _uMENU("",{align:"D"},{hidden:1,withmarks:1,onitem:_uWnd._onsysmenuitem},_uWnd.sysmenuitems)),this.init(n)}function _txt(sign){var lng=window._uDeflang,a,p=arguments;if(lng){var db=window._uSigns;a=db&&db[lng]&&sign in db[lng]?db[lng][sign]:sign}else a=sign;if("%eval:"==a.substr(0,6))try{return eval(a.substr(6))}catch(t){return"ERROR "+t}function _txtproc(t,e){return p[e]}return p.length>1&&(a=a.replace(/%([1-9])/g,_txtproc)),a}function _uColorBox(t,e,s){for(var i,o=new Array("00","33","66","99","CC","FF"),a=new Array("00","33","66","99","CC","FF"),n=new Array("00","33","66","99","CC","FF"),r=new Array("909090","939393","969696","999999","9C9C9C","9F9F9F","C0C0C0","C3C3C3","C6C6C6","C9C9C9","CCCCCC","E0E0E0","F0F0F0","F3F3F3","F6F6F6","F9F9F9","FCFCFC","FFFFFF"),l="00",h="00",d=0,u=0,p=0,c=0,m=0,f=0,_=0,b='<table border="0" cellpadding="0" cellspacing="1" bgcolor="#000000">';m<6;){b+="<tr>";for(c=0,h=n[p];c<6;){for(f=0,l=a[u];f<6;){var g=""+o[d]+l+h;b+='<td style="width:8px;height:8px;cursor:pointer;background-color:#'+g+';" onclick="'+(i=null!=s?s+"('"+t+"','"+e+"','"+g+"')":"$('#"+t+"').hide(); $('#"+e+"').val('"+g+"');")+'"></td>',f++,6==++d&&(d=0)}c++,6==++u&&(u=0),3==++_&&(b+="</tr>",_=0)}m++,6==++p&&(p=0)}for(var v=0;v<r.length;v++)i=null!=s?s+"('"+t+"','"+e+"','"+r[v]+"')":"$('#"+t+"').hide(); $('#"+e+"').val('"+r[v]+"');",b+='<td style="width:8px;height:8px;cursor:pointer;background-color:#'+r[v]+';" onclick="'+i+'"></td>';b+="</table>",$("#"+t).html(b)}function _uParseXML(xml,wnd,tabid,papp){xml=xml.documentElement;var tabctrl=null,app=null,_uParse_footers={};null==wnd&&(wnd=_uWnd?.findactive?.()),wnd&&wnd.constructor==_uTabCtrl?(tabctrl=wnd,wnd=tabctrl.wnd||null,app=papp||tabctrl.app||null):wnd&&wnd.constructor==_uWnd?app=papp||wnd.app||null:(app=papp||null,wnd=null),!xml&&alert("Server connection Error. Sorry."),xml.querySelectorAll("cmd").forEach(item=>{let cmd="",target="",data,height=null;[...item.attributes].forEach(t=>{switch(t.name){case"h":height=parseInt(t.value);break;case"p":cmd=t.value;break;case"t":target=t.value}}),data=item.firstChild?item.firstChild.data.trim():"","innerHTML"==cmd&&(target.match(/^layerContent(.+)/)&&_uWnd.content(RegExp.$1,data),target.match(/^layerTitle(.+)/)&&_uWnd.setTitle(RegExp.$1,data));let targetElement=target?window[target]||document.getElementById(target)||document.querySelector(target):null;if("innerHTML"==cmd)$(targetElement).html(data);else if("+innerHTML"==cmd)targetElement&&targetElement.insertAdjacentHTML("afterbegin",data);else if("innerHTML+"==cmd)targetElement&&targetElement.insertAdjacentHTML("beforeend",data);else if("innerHTMLspanAll"==cmd)$(`span.${target}`).html(data);else if("innerHTMLdivAll"==cmd)$(`div.${target}`).html(data);else if("value"==cmd)targetElement&&(targetElement.value=data);else if("jsa"==cmd)includeJSfile(data,target);else if("js"==cmd)eval(data);else if("content"==cmd&&target.length>
10){var r=target.match(/^([^:]+):(.+)/);r?("number"==typeof _uParse_footers["_uhh"+r]&&NaN!=_uParse_footers["_uhh"+r]&&_uTabCtrl.headerheight(r[1],r[2],_uParse_footers["_uhh"+r]),"number"==typeof _uParse_footers["_ufh"+r]&&NaN!=_uParse_footers["_ufh"+r]&&_uTabCtrl.footerheight(r[1],r[2],_uParse_footers["_ufh"+r]),_uTabCtrl.content(r[1],r[2],data,_uParse_footers["_uhc"+r],_uParse_footers["_ufc"+r])):_uWnd.content(target,data)}else if("header"==cmd&&target.length>0){var r=target.match(/^([^:]+):(.+)/);r?(_uParse_footers["_uhc"+r]=data,_uParse_footers["_uhh"+r]=height):(NaN!=height&&_uWnd.headerheight(target,height),_uWnd.header(target,data))}else if("footer"==cmd&&target.length>0){var r=target.match(/^([^:]+):(.+)/);r?(_uParse_footers["_ufc"+r]=data,_uParse_footers["_ufh"+r]=height):(NaN!=height&&_uWnd.footerheight(target,height),_uWnd.footer(target,data))}else if("title"==cmd&&target.length>0){var r=target.match(/^([^:]+):(.+)/);r?_uTabCtrl.setTitle(r[1],r[2],data):_uWnd.setTitle(target,data)}else if("close"==cmd&&target.length>0){var r=target.match(/^([^:]+):(.+)/);r?!data||isNaN(parseInt(data))?_uTabCtrl.closeTab(r[1],r[2]):setTimeout(`_uTabCtrl.closeTab('${r[1]}', '${r[2]}');`,parseInt(data)):!data||isNaN(parseInt(data))?_uWnd.close(target):setTimeout(`_uWnd.close('${target}');`,parseInt(data))}else tabctrl&&tabid?"content"==cmd?("number"==typeof _uParse_footers._uhh&&NaN!=_uParse_footers._uhh&&tabctrl.headerheight(tabid,_uParse_footers._uhh),"number"==typeof _uParse_footers._ufh&&NaN!=_uParse_footers._ufh&&tabctrl.footerheight(tabid,_uParse_footers._ufh),tabctrl.content(tabid,data,_uParse_footers._uhc,_uParse_footers._ufc)):"header"==cmd?(_uParse_footers._uhc=data,_uParse_footers._uhh=height):"footer"==cmd?(_uParse_footers._ufc=data,_uParse_footers._ufh=height):"title"==cmd?tabctrl.setTitle(tabid,data):"close"==cmd&&(!data||isNaN(parseInt(data))?tabctrl.closeTab(tabid):setTimeout(`var _utc=_uTabCtrl.all[ ${tabctrl.idx} ]; if (_utc)_utc.closeTab('${tabid}');`,parseInt(data))):wnd&&!tabctrl&&("content"==cmd?wnd.content(data):"header"==cmd?(NaN!=height&&wnd.headerheight(height),wnd.header(data)):"footer"==cmd?(NaN!=height&&wnd.footerheight(height),wnd.footer(data)):"title"==cmd?wnd.setTitle(data):"close"==cmd&&(!data||isNaN(parseInt(data))?wnd.close():setTimeout(`var _uw=_uWnd.all[ ${wnd.idx} ]; if (_uw)_uw.close();`,parseInt(data))))})}!function(t){t.render||(t.render=function(t={}){let e=this;if(/\?\?(.+?)\?\?/.test(e)){e=e.replace(/\?\?(.+?)=(.+?)\?\?/g,function(e,s,i){return t[s]?i:""})}if(/\[\[(.+?)\]\]/.test(e)){e=e.replace(/\[\[(.+?)\]\]/g,function(e,s){return t.sign&&t.sign[s]?t.sign[s]:`Sign [[${s}]] is undefined!`})}return e.replace(/\{\{(.+?)\}\}/g,(e,s)=>void 0!==t[s]?t[s]:"")})}(String.prototype),function(t){t.insertAtCursor||(t.insertAtCursor=function(t=""){if(document.selection){this.focus(),document.selection.createRange().text=t}else if(this.selectionStart||"0"==this.selectionStart){let e=this.selectionStart,s=this.selectionEnd;this.value=this.value.substring(0,e)+t+this.value.substring(s,this.value.length)}else this.value+=t})}(HTMLTextAreaElement.prototype),["Arguments","Function","String","Array","Object","Number","Date","RegExp","NodeList","Blob"].forEach(t=>window[`is${t}`]=e=>toString.call(e)===`[object ${t}]`),function(t){function e(t,e,s){throw new t("Failed to execute 'requestSubmit' on 'HTMLFormElement': "+e+".",s)}"function"!=typeof t.requestSubmit&&(t.requestSubmit=function(t){t?(!function(t,s){t instanceof HTMLElement||e(TypeError,"parameter 1 is not of type 'HTMLElement'"),"submit"==t.type||e(TypeError,"The specified element is not a submit button"),t.form==s||e(DOMException,"The specified element is not owned by this form element","NotFoundError")}(t,this),t.click()):((t=document.createElement("input")).type="submit",t.hidden=!0,this.appendChild(t),t.click(),this.removeChild(t))})}(HTMLFormElement.prototype),jQuery.ajaxSettings.traditional=!0,function(t){"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof module&&module.exports?module.exports=function(e,s){return void 0===s&&(s="undefined"!=typeof window?require("jquery"):require("jquery")(e)),t(s),s}:t(jQuery)}(function(t){"use strict";var e=/\r?\n/g,s={};s.fileapi=void 0!==t('<input type="file">').get(0).files,s.formdata=void 0!==window.FormData;var i=!!t.fn.prop;function o(e){var s=e.data;e.isDefaultPrevented()||(e.preventDefault(),t(e.target).closest("form").ajaxSubmit(s))}function a(e){var s=e.target,i=t(s);if(!i.is("[type=submit],[type=image]")){var o=i.closest("[type=submit]");if(0===o.length)return;s=o[0]}var a=s.form;if(a.clk=s,"image"===s.type)if(void 0!==e.offsetX)a.clk_x=e.offsetX,a.clk_y=e.offsetY;else if("function"==typeof t.fn.offset){var n=i.offset();a.clk_x=e.pageX-n.left,a.clk_y=e.pageY-n.top}else a.clk_x=e.pageX-s.offsetLeft,a.clk_y=e.pageY-s.offsetTop;setTimeout(function(){a.clk=a.clk_x=a.clk_y=null},100)}function n(){if(t.fn.ajaxSubmit.debug){var e="[jquery.form] "+Array.prototype.join.call(arguments,"");window.console&&window.console.log?window.console.log(e):window.opera&&window.opera.postError&&window.opera.postError(e)}}t.fn.attr2=function(){if(!i)return this.attr.apply(this,arguments);var t=this.prop.apply(this,arguments);return t&&t.jquery||"string"==typeof t?t:this.attr.apply(this,arguments)},t.fn.ajaxSubmit=function(e,o,a,r){if(!this.length)return n("ajaxSubmit: ski
1pping submit process - no element selected"),this;var l=this;"function"==typeof e?e={success:e}:"string"==typeof e||!1===e&&arguments.length>0?(e={url:e,data:o,dataType:a},"function"==typeof r&&(e.success=r)):void 0===e&&(e={});var h=e.method||e.type||this.attr2("method"),d=e.url||this.attr2("action"),u="string"==typeof d?t.trim(d):"";(u=u||window.location.href||"")&&(u=(u.match(/^([^#]+)/)||[])[1]);var p=/(MSIE|Trident)/.test(navigator.userAgent||"")&&/^https/i.test(window.location.href||"")?"javascript:false":"about:blank";e=t.extend(!0,{url:u,success:t.ajaxSettings.success,type:h||t.ajaxSettings.type,iframeSrc:p},e);var c={};if(this.trigger("form-pre-serialize",[this,e,c]),c.veto)return n("ajaxSubmit: submit vetoed via form-pre-serialize trigger"),this;if(e.beforeSerialize&&!1===e.beforeSerialize(this,e))return n("ajaxSubmit: submit aborted via beforeSerialize callback"),this;var m=e.traditional;void 0===m&&(m=t.ajaxSettings.traditional);var f,_=[],b=this.formToArray(e.semantic,_,e.filtering);if(e.data){var g=t.isFunction(e.data)?e.data(b):e.data;e.extraData=g,f=t.param(g,m)}if(e.beforeSubmit&&!1===e.beforeSubmit(b,this,e))return n("ajaxSubmit: submit aborted via beforeSubmit callback"),this;if(this.trigger("form-submit-validate",[b,this,e,c]),c.veto)return n("ajaxSubmit: submit vetoed via form-submit-validate trigger"),this;var v=t.param(b,m);f&&(v=v?v+"&"+f:f),"GET"===e.type.toUpperCase()?(e.url+=(e.url.indexOf("?")>=0?"&":"?")+v,e.data=null):e.data=v;var w=[];if(e.resetForm&&w.push(function(){l.resetForm()}),e.clearForm&&w.push(function(){l.clearForm(e.includeHidden)}),!e.dataType&&e.target){var y=e.success||function(){};w.push(function(s,i,o){var a=arguments,n=e.replaceTarget?"replaceWith":"html";t(e.target)[n](s).each(function(){y.apply(this,a)})})}else e.success&&(t.isArray(e.success)?t.merge(w,e.success):w.push(e.success));if(e.success=function(t,s,i){for(var o=e.context||this,a=0,n=w.length;a<n;a++)w[a].apply(o,[t,s,i||l,l])},e.error){var x=e.error;e.error=function(t,s,i){var o=e.context||this;x.apply(o,[t,s,i,l])}}if(e.complete){var $=e.complete;e.complete=function(t,s){var i=e.context||this;$.apply(i,[t,s,l])}}var j=t("input[type=file]:enabled",this).filter(function(){return""!==t(this).val()}).length>0,k="multipart/form-data",T=l.attr("enctype")===k||l.attr("encoding")===k,C=s.fileapi&&s.formdata;n("fileAPI :"+C);var z,W=(j||T)&&!C;!1!==e.iframe&&(e.iframe||W)?e.closeKeepAlive?t.get(e.closeKeepAlive,function(){z=M(b)}):z=M(b):z=(j||T)&&C?function(s){for(var i=new FormData,o=0;o<s.length;o++)i.append(s[o].name,s[o].value);if(e.extraData){var a=function(s){var i,o,a=t.param(s,e.traditional).split("&"),n=a.length,r=[];for(i=0;i<n;i++)a[i]=a[i].replace(/\+/g," "),o=a[i].split("="),r.push([decodeURIComponent(o[0]),decodeURIComponent(o[1])]);return r}(e.extraData);for(o=0;o<a.length;o++)a[o]&&i.append(a[o][0],a[o][1])}e.data=null;var n=t.extend(!0,{},t.ajaxSettings,e,{contentType:!1,processData:!1,cache:!1,type:h||"POST"});e.uploadProgress&&(n.xhr=function(){var s=t.ajaxSettings.xhr();return s.upload&&s.upload.addEventListener("progress",function(t){var s=0,i=t.loaded||t.position,o=t.total;t.lengthComputable&&(s=Math.ceil(i/o*100)),e.uploadProgress(t,i,o,s)},!1),s});n.data=null;var r=n.beforeSend;return n.beforeSend=function(t,s){e.formData?s.data=e.formData:s.data=i,r&&r.call(this,t,s)},t.ajax(n)}(b):t.ajax(e),l.removeData("jqxhr").data("jqxhr",z);for(var S=0;S<_.length;S++)_[S]=null;return this.trigger("form-submit-notify",[this,e]),this;function M(s){var o,a,r,d,u,p,c,m,f,b,g,v,w=l[0],y=t.Deferred();if(y.abort=function(t){m.abort(t)},s)for(a=0;a<_.length;a++)o=t(_[a]),i?o.prop("disabled",!1):o.removeAttr("disabled");(r=t.extend(!0,{},t.ajaxSettings,e)).context=r.context||r,u="jqFormIO"+(new Date).getTime();var x=w.ownerDocument,$=l.closest("body");if(r.iframeTarget?(b=(p=t(r.iframeTarget,x)).attr2("name"))?u=b:p.attr2("name",u):(p=t('<iframe name="'+u+'" src="'+r.iframeSrc+'" />',x)).css({position:"absolute",top:"-1000px",left:"-1000px"}),c=p[0],m={aborted:0,responseText:null,responseXML:null,status:0,statusText:"n/a",getAllResponseHeaders:function(){},getResponseHeader:function(){},setRequestHeader:function(){},abort:function(e){var s="timeout"===e?"timeout":"aborted";n("aborting upload... "+s),this.aborted=1;try{c.contentWindow.document.execCommand&&c.contentWindow.document.execCommand("Stop")}catch(t){}p.attr("src",r.iframeSrc),m.error=s,r.error&&r.error.call(r.context,m,s,e),d&&t.event.trigger("ajaxError",[m,r,s]),r.complete&&r.complete.call(r.context,m,s)}},(d=r.global)&&0===t.active++&&t.event.trigger("ajaxStart"),d&&t.event.trigger("ajaxSend",[m,r]),r.beforeSend&&!1===r.beforeSend.c
1all(r.context,m,r))return r.global&&t.active--,y.reject(),y;if(m.aborted)return y.reject(),y;(f=w.clk)&&(b=f.name)&&!f.disabled&&(r.extraData=r.extraData||{},r.extraData[b]=f.value,"image"===f.type&&(r.extraData[b+".x"]=w.clk_x,r.extraData[b+".y"]=w.clk_y));function j(t){var e=null;try{t.contentWindow&&(e=t.contentWindow.document)}catch(t){n("cannot get iframe.contentWindow document: "+t)}if(e)return e;try{e=t.contentDocument?t.contentDocument:t.document}catch(s){n("cannot get iframe.contentDocument: "+s),e=t.document}return e}var k=t("meta[name=csrf-token]").attr("content"),T=t("meta[name=csrf-param]").attr("content");function C(){var e=l.attr2("target"),s=l.attr2("action"),i=l.attr("enctype")||l.attr("encoding")||"multipart/form-data";w.setAttribute("target",u),h&&!/post/i.test(h)||w.setAttribute("method","POST"),s!==r.url&&w.setAttribute("action",r.url),r.skipEncodingOverride||h&&!/post/i.test(h)||l.attr({encoding:"multipart/form-data",enctype:"multipart/form-data"}),r.timeout&&(v=setTimeout(function(){g=!0,I(1)},r.timeout));var o=[];try{if(r.extraData)for(var a in r.extraData)r.extraData.hasOwnProperty(a)&&(t.isPlainObject(r.extraData[a])&&r.extraData[a].hasOwnProperty("name")&&r.extraData[a].hasOwnProperty("value")?o.push(t('<input type="hidden" name="'+r.extraData[a].name+'">',x).val(r.extraData[a].value).appendTo(w)[0]):o.push(t('<input type="hidden" name="'+a+'">',x).val(r.extraData[a]).appendTo(w)[0]));r.iframeTarget||p.appendTo($),c.attachEvent?c.attachEvent("onload",I):c.addEventListener("load",I,!1),setTimeout(function t(){try{var e=j(c).readyState;n("state = "+e),e&&"uninitialized"===e.toLowerCase()&&setTimeout(t,50)}catch(t){n("Server abort: ",t," (",t.name,")"),I(2),v&&clearTimeout(v),v=void 0}},15);try{w.submit()}catch(t){document.createElement("form").submit.apply(w)}}finally{w.setAttribute("action",s),w.setAttribute("enctype",i),e?w.setAttribute("target",e):l.removeAttr("target"),t(o).remove()}}T&&k&&(r.extraData=r.extraData||{},r.extraData[T]=k),r.forceSync?C():setTimeout(C,10);var z,W,S,M=50;function I(e){if(!m.aborted&&!S){if((W=j(c))||(n("cannot access response document"),e=2),1===e&&m)return m.abort("timeout"),void y.reject(m,"timeout");if(2===e&&m)return m.abort("server abort"),void y.reject(m,"error","server abort");if(W&&W.location.href!==r.iframeSrc||g){c.detachEvent?c.detachEvent("onload",I):c.removeEventListener("load",I,!1);var s,i="success";try{if(g)throw"timeout";var o="xml"===r.dataType||W.XMLDocument||t.isXMLDoc(W);if(n("isXml="+o),!o&&window.opera&&(null===W.body||!W.body.innerHTML)&&--M)return n("requeing onLoad callback, DOM not available"),void setTimeout(I,250);var a=W.body?W.body:W.documentElement;m.responseText=a?a.innerHTML:null,m.responseXML=W.XMLDocument?W.XMLDocument:W,o&&(r.dataType="xml"),m.getResponseHeader=function(t){return{"content-type":r.dataType}[t.toLowerCase()]},a&&(m.status=Number(a.getAttribute("status"))||m.status,m.statusText=a.getAttribute("statusText")||m.statusText);var l=(r.dataType||"").toLowerCase(),h=/(json|script|text)/.test(l);if(h||r.textarea){var u=W.getElementsByTagName("textarea")[0];if(u)m.responseText=u.value,m.status=Number(u.getAttribute("status"))||m.status,m.statusText=u.getAttribute("statusText")||m.statusText;else if(h){var f=W.getElementsByTagName("pre")[0],_=W.getElementsByTagName("body")[0];f?m.responseText=f.textContent?f.textContent:f.innerText:_&&(m.responseText=_.textContent?_.textContent:_.innerText)}}else"xml"===l&&!m.responseXML&&m.responseText&&(m.responseXML=A(m.responseText));try{z=L(m,l,r)}catch(t){i="parsererror",m.error=s=t||i}}catch(t){n("error caught: ",t),i="error",m.error=s=t||i}m.aborted&&(n("upload aborted"),i=null),m.status&&(i=m.status>=200&&m.status<300||304===m.status?"success":"error"),"success"===i?(r.success&&r.success.call(r.context,z,"success",m),y.resolve(m.responseText,"success",m),d&&t.event.trigger("ajaxSuccess",[m,r])):i&&(void 0===s&&(s=m.statusText),r.error&&r.error.call(r.context,m,i,s),y.reject(m,"error",s),d&&t.event.trigger("ajaxError",[m,r,s])),d&&t.event.trigger("ajaxComplete",[m,r]),d&&! --t.active&&t.event.trigger("ajaxStop"),r.complete&&r.complete.call(r.context,m,i),S=!0,r.timeout&&clearTimeout(v),setTimeout(function(){r.iframeTarget?p.attr("src",r.iframeSrc):p.remove(),m.responseXML=null},100)}}}var A=t.parseXML||function(t,e){return window.ActiveXObject?((e=new ActiveXObject("Microsoft.XMLDOM")).async="false",e.loadXML(t)):e=(new DOMParser).parseFromString(t,"text/xml"),e&&e.documentElement&&"parsererror"!==e.documentElement.nodeName?e:null},N=t.parseJSON||function(t){return window.eval("("+t+")")},L=function(e,s,i){var o=e.getResponseHeader("content-type")||"",a=("xml"===s||!s)&&o.indexOf("xml")>=0,n=a?e.responseXML:e.responseText;return a&&"parsererror"===n.documentElement.nodeName&&t.error&&t.error("parsererror"),i&&i.dataFilter&&(n=i.dataFilter(n,s)),"string"==typeof n&&(("json"===s||!s)&&o.indexOf("json")>=0?n=N(n):("script"===s||!s)&&o.indexOf("javascript")>=0&&t.globalEval(n)),n};return y}},t.fn.ajaxForm=function(e,s,i,r){if(("string"==typeof e||!1===e&&arguments.length>0)&&(e={url:e,data:s,dataType:i},"function"==typeof r&&(e.success=r)),(e=e||{}).delegation=e.delegation&&t.isFunction(t.fn.on),!e.delegation&&0===this.length){var l={s:this.selector,c:this.context};return!t.isReady&&l.s?(n("DOM not ready, queuing ajaxForm"),t(function(){t(l.s,l.c).ajaxForm(e)}),this):(n("terminating; zero elements found by selector"+(t.isReady?"":" (DOM not ready)")),this)}return e.delegation?(t(document).off("submit.form-plugin",this.selector,o).off("click.form-plugin",this.selector,a).on("submit.form-plugin",this.selector,e,o).on("click.form-plugin",this.selector,e,a),this):(e.beforeFormUnbind&&e.beforeFormUnbind(this,e),this.ajaxFormUnbind().on("submit.form-plugin",e,o).on("click.form-plugin",e,a))},t.fn.ajaxFormUnbind=function(){return this.off("submit.form-plugin click.form-plugin")},t.fn.formToArray=function(e,i,o){var a=[];if(0===this.length)return a;var n,r,l,h,d,u,p,c,m=this[0],f=this.attr("id"),_=e||void 0===m.elements?m.getElementsByTagName("*"):m.elements;if(_&&(_=t.makeArray(_)),f&&(e||/(Edge|Trident)\//.test(navigator.userAgent))&&(n=t(':input[form="'+f+'"]').get()).length&&(_=(_||[]).concat(n)),!_||!_.length)return a;for(t.isFunction(o)&&(_=t.map(_,o)),r=0,p=_.length;r<p;r++)if((h=(u=_[r]).name)&&!u.disabled)if(e&&m.clk&&"image"===u.type)m.clk===u&&(a.push({name:h,value:t(u).val(),type:u.type}),a.push({name:h+".x",value:m.clk_x},{name:h+".y",value:m.clk_y}));else if((d=t.fieldValue(u,!0))&&d.constructor===Array)for(i&&i.push(u),l=0,c=d.length;l<c;l++)a.push({name:h,value:d[l]});else if(s.fileapi&&"file"===u.type){i&&i.push(u);var b=u.files;if(b.length)for(l=0;l<b.length;l++)a.push({name:h,value:b[l],type:u.type});else a.push({name:h,value:"",type:u.type})}else null!=d&&(i&&i.push(u),a.push({name:h,value:d,type:u.type,required:u.required}));if(!e&&m.clk){var g=t(m.clk),v=g[0];(h=v.name)&&!v.disabled&&"image"===v.type&&(a.push({name:h,value:g.val()}),a.push({name:h+".x",value:m.clk_x},{name:h+".y",value:m.clk_y}))}return a}
1,t.fn.formSerialize=function(e){return t.param(this.formToArray(e))},t.fn.fieldSerialize=function(e){var s=[];return this.each(function(){var i=this.name;if(i){var o=t.fieldValue(this,e);if(o&&o.constructor===Array)for(var a=0,n=o.length;a<n;a++)s.push({name:i,value:o[a]});else null!=o&&s.push({name:this.name,value:o})}}),t.param(s)},t.fn.fieldValue=function(e){for(var s=[],i=0,o=this.length;i<o;i++){var a=this[i],n=t.fieldValue(a,e);null==n||n.constructor===Array&&!n.length||(n.constructor===Array?t.merge(s,n):s.push(n))}return s},t.fieldValue=function(s,i){var o=s.name,a=s.type,n=s.tagName.toLowerCase();if(void 0===i&&(i=!0),i&&(!o||s.disabled||"reset"===a||"button"===a||("checkbox"===a||"radio"===a)&&!s.checked||("submit"===a||"image"===a)&&s.form&&s.form.clk!==s||"select"===n&&-1===s.selectedIndex))return null;if("select"===n){var r=s.selectedIndex;if(r<0)return null;for(var l=[],h=s.options,d="select-one"===a,u=d?r+1:h.length,p=d?r:0;p<u;p++){var c=h[p];if(c.selected&&!c.disabled){var m=c.value;if(m||(m=c.attributes&&c.attributes.value&&!c.attributes.value.specified?c.text:c.value),d)return m;l.push(m)}}return l}return t(s).val().replace(e,"\r\n")},t.fn.clearForm=function(e){return this.each(function(){t("input,select,textarea",this).clearFields(e)})},t.fn.clearFields=t.fn.clearInputs=function(e){var s=/^(?:color|date|datetime|email|month|number|password|range|search|tel|text|time|url|week)$/i;return this.each(function(){var i=this.type,o=this.tagName.toLowerCase();s.test(i)||"textarea"===o?this.value="":"checkbox"===i||"radio"===i?this.checked=!1:"select"===o?this.selectedIndex=-1:"file"===i?/MSIE/.test(navigator.userAgent)?t(this).replaceWith(t(this).clone(!0)):t(this).val(""):e&&(!0===e&&/hidden/.test(i)||"string"==typeof e&&t(this).is(e))&&(this.value="")})},t.fn.resetForm=function(){return this.each(function(){var e=t(this),s=this.tagName.toLowerCase();switch(s){case"input":this.checked=this.defaultChecked;case"textarea":return this.value=this.defaultValue,!0;case"option":case"optgroup":var i=e.parents("select");return i.length&&i[0].multiple?"option"===s?this.selected=this.defaultSelected:e.find("option").resetForm():i.resetForm(),!0;case"select":return e.find("option").each(function(t){if(this.selected=this.defaultSelected,this.defaultSelected&&!e[0].multiple)return e[0].selectedIndex=t,!1}),!0;case"label":var o=t(e.attr("for")),a=e.find("input,select,textarea");return o[0]&&a.unshift(o[0]),a.resetForm(),!0;case"form":return("function"==typeof this.reset||"object"==typeof this.reset&&!this.reset.nodeType)&&this.reset(),!0;default:return e.find("form,input,label,select,textarea").resetForm(),!0}})},t.fn.enable=function(t){return void 0===t&&(t=!0),this.each(function(){this.disabled=!t})},t.fn.selected=function(e){return void 0===e&&(e=!0),this.each(function(){var s=this.type;if("checkbox"===s||"radio"===s)this.checked=e;else if("option"===this.tagName.toLowerCase()){var i=t(this).parent("select");e&&i[0]&&"select-one"===i[0].type&&i.find("option").selected(!1),this.selected=e}})},t.fn.ajaxSubmit.debug=!1}),function(t){"use strict";"function"==typeof define&&define.amd?define(["jquery"],t):"undefined"!=typeof module&&module.exports?module.exports=t(require("jquery")):t(jQuery)}(function(t){"use strict";var e=t.scrollTo=function(e,s,i){return t(window).scrollTo(e,s,i)};function s(e){return!e.nodeName||-1!==t.inArray(e.nodeName.toLowerCase(),["iframe","#document","html","body"])}function i(t){return"function"==typeof t}function o(e){return i(e)||t.isPlainObject(e)?e:{top:e,left:e}}return e.defaults={axis:"xy",duration:0,limit:!0},t.fn.scrollTo=function(a,n,r){"object"==typeof n&&(r=n,n=0),"function"==typeof r&&(r={onAfter:r}),"max"===a&&(a=9e9),r=t.extend({},e.defaults,r),n=n||r.duration;var l=r.queue&&r.axis.length>1;return l&&(n/=2),r.offset=o(r.offset),r.over=o(r.over),this.each(function(){if(null!==a){var h,d=s(this),u=d?this.contentWindow||window:this,p=t(u),c=a,m={};switch(typeof c){case"number":case"string":if(/^([+-]=?)?\d+(\.\d+)?(px|%)?$/.test(c)){c=o(c);break}c=d?t(c):t(c,u);case"object":if(0===c.length)return;(c.is||c.style)&&(h=(c=t(c)).offset())}var f=i(r.offset)&&r.offset(u,c)||r.offset;t.each(r.axis.split(""),function(t,s){var i="x"===s?"Left":"Top",o=i.toLowerCase(),a="scroll"+i,n=p[a](),b=e.max(u,s);if(h)m[a]=h[o]+(d?0:n-p.offset()[o]),r.margin&&(m[a]-=parseInt(c.css("margin"+i),10)||0,m[a]-=parseInt(c.css("border"+i+"Width"),10)||0),m[a]+=f[o]||0,r.over[o]&&(m[a]+=c["x"===s?"width":"height"]()*r.over[o]);else{var g=c[o];m[a]=g.slice&&"%"===g.slice(-1)?parseFloat(g)/100*b:g}r.limit&&/^\d+$/.test(m[a])&&(m[a]=m[a]<=0?0:Math.min(m[a],b)),!t&&r.axis.length>1&&(n===m[a]?m={}:l&&(_(r.onAfterFirst),m={}))}),_(r.onAfter)}function _(e){var s=t.extend({},r,{queue:!0,duration:n,complete:e&&function(){e.call(u,c,r)}});p.animate(m,s)}})},e.max=function(e,i){var o="x"===i?"Width":"Height",a="scroll"+o;if(!s(e))return e[a]-t(e)[o.toLowerCase()]();var n="client"+o,r=e.ownerDocument||e.document,l=r.documentElement,h=r.body;return Math.max(l[a],h[a])-Math.min(l[n],h[n])},t.Tween.propHooks.scrollLeft=t.Tween.propHooks.scrollTop={get:function(e){return t(e.elem)[e.prop]()},set:function(e){var s=this.get(e);if(e.options.interrupt&&e._last&&e._last!==s)return t(e.elem).stop();var i=Math.round(e.now);s!==i&&(t(e.elem)[e.prop](i),e._last=this.get(e))}},e}),_uFocus.current=null,_uFocus.last_fixed=null,_uFocus.glisteners=[],_uFocus.globalset=!1,_uFocus.inprocess=0,_uFocus.delayedactivate=null,_uFocus._onkey=function(t){var e,s="on"+t.type;"keypress"==t.type&&((37==t.keyCode||38==t.keyCode||39==t.keyCode||40==t.keyCode||0==t.keyCode&&$.browser&&$.browser.opera)&&t.target&&"input"!=t.target.tagName.toLowerCase()&&"textarea"!=t.target.tagName.toLowerCase()||32==t.keyCode&&t.ctrlKey)&&_uFocus.current&&t.preventDefault(),"keydown"==t.type&&$.browser&&$.browser.opera&&0==t.keyCode&&(t.keyCode=93);for(var i=0;i<_uFocus.glisteners.length;i++)if((e=_uFocus.glisteners[i])[s]&&e[s].call(e._thispar,t,e._param,_uFocus.current))return;if(e=_uFocus.current){for(var o=[];e;)o.unshift(e),e=e._parent;for(i=0;i<o.length;i++)if(o[i][s]&&o[i][s].call(o[i]._thispar,t,o[i]._param,_uFocus.current))return}}
1,_uFocus.prototype={activate:function(){return this.destroyed||0!=this._tp&&1!=this._tp?0:_uFocus.inprocess?(_uFocus.delayedactivate=this,-1):(_uFocus.inprocess=1,t=this._activate(this,_uFocus.current),_uFocus.inprocess=0,_uFocus.delayedactivate&&setTimeout("var _uf=_uFocus.delayedactivate; _uFocus.delayedactivate=null; if (_uf)_uf.activate();",0),t);var t},deactivate:function(){var t;this.destroyed||0!=this._tp&&1!=this._tp||_uFocus.inprocess||(_uFocus.inprocess=1,t=this._deactivate(_uFocus.current,null),_uFocus.inprocess=0,_uFocus.delayedactivate?setTimeout("var _uf=_uFocus.delayedactivate; _uFocus.delayedactivate=null; if (_uf)_uf.activate();",0):1!=t||!_uFocus.last_fixed||_uFocus.current&&1==_uFocus.current._tp||_uFocus.last_fixed.activate())},isactive:function(t){return this==_uFocus.current||!t&&this.isparentof(_uFocus.current)},isparentof:function(t){if(!t)return 0;for(var e=t._parent;e;){if(e==this)return 1;e=e._parent}return 0},_activate:function(t,e,s){var i,o;if(this.isactive()&&(i=_uFocus.current,!s||i==this))return 1;if(this._parent&&!this._parent._activate(this._parent,e))return 0;if((i=_uFocus.current)&&i!=this._parent){for(;i._parent&&i._parent!=this._parent;)i=i._parent;if(-1==i._deactivate(e,t))return 0}for(var a=0;a<_uFocus.glisteners.length;a++)if((i=_uFocus.glisteners[a]).canactivate&&(!(o=i.canactivate.call(i._thispar,i._param,e,t))||-1==o&&_uFocus.delayedactivate))return 0;var n=[this];for(i=this._parent;i;)n.unshift(i),i=i._parent;for(a=0;a<n.length;a++)if(n[a].canactivate&&(!(o=n[a].canactivate.call(n[a]._thispar,n[a]._param,e,t))||-1==o&&_uFocus.delayedactivate))return 0;_uFocus.current=this,1==this._tp&&e&&0==e._tp?_uFocus.last_fixed=e:0==this._tp&&(_uFocus.last_fixed=null);for(a=0;a<_uFocus.glisteners.length;a++)if((i=_uFocus.glisteners[a]).onactivate&&-1==i.onactivate.call(i._thispar,i._param,e,t)&&_uFocus.delayedactivate)return 0;for(a=0;a<n.length;a++)if(n[a].onactivate&&-1==n[a].onactivate.call(n[a]._thispar,n[a]._param,e,t)&&_uFocus.delayedactivate)return 0;return 1},_deactivate:function(t,e){if(!this.isactive())return 0;for(var s,i,o=_uFocus.current;o;){if(_uFocus.current=o._parent,o.ondeactivate&&-1==o.ondeactivate.call(o._thispar,o._param,t,e)&&_uFocus.delayedactivate)return-1;for(1!=o._tp&&(_uFocus.last_fixed=null),s=0;s<_uFocus.glisteners.length;s++)(i=_uFocus.glisteners[s]).ondeactivate&&i.ondeactivate.call(i._thispar,i._param,o,e);if(o==this)break;o=o._parent}return 1},destroy:function(){if(!this.destroyed){if(this.deactivate(),2==this._tp)for(var t=0;t<_uFocus.glisteners.length;t++)if(_uFocus.glisteners[t]==this){_uFocus.glisteners.splice(t,1);break}this.destroyed=1}}},_uMenu.get=function(t){var e=$("#"+t)[0];return e?e._umenu:null},_uMenu.show=function(t,e,s,i,o,a){var n=_uMenu.get(t);n&&n.show_menu(e,s,i,o,a)},_uMenu.hide=function(t,e){var s=_uMenu.get(t);s&&(e?s.hide_child():s.hide_menu())},_uMenu.hideAll=function(e){var gr;with(_uMenu.prototype)for(gr in have_active){if(have_active[gr]&&!donothide[gr]){for(var i in all_menus[gr])_uMenu.hide(i);have_active[gr]=""}donothide[gr]=!1}},_uMenu.showOver=function(id,par,tp,mid,dy,dx){var o=_uMenu.get(id);if(o){var gr=o.group;with(_uMenu.prototype)timerid2[gr]&&clearTimeout(timerid2[gr]),have_active[gr].length>0&&-1==have_active[gr].indexOf(","+id+",")&&o.show_menu(par,tp,mid,dy,dx)}},_uMenu.schedule_hidechild=function(id){var o=_uMenu.get(id);if(o){var gr=o.group;with(_uMenu.prototype)timerid2[gr]&&clearTimeout(timerid2[gr]),timerid2[gr]=setTimeout("_uMenu.hide('"+id+"',1);_uMenu.prototype.timerid2['"+gr+"']=0;",800)}},_uMenu.prototype={donothide:[],all_menus:[],have_active:[],timerid:[],timerid2:[],global_set:!1,init:function(t,e,s){this.id=t,this.obj=$("#"+t)[0],this.obj&&(this.obj._umenu=this,e||(e=t),this.parentid=e,s||(s="def"),this.group=s,this.obj.style.display="none",$(this.obj).on("click",this,function(t){t.data.donothide[t.data.group]=!0}),null==this.all_menus[s]&&(this.all_menus[s]=[]),null==this.have_active[s]&&(this.have_active[s]=""),this.all_menus[s][t]=this,this.global_set||($(document).on("click",_uMenu.hideAll),$(window).on("resize",_uMenu.hideAll),_uMenu.prototype.global_set=!0))},show_menu:function(par,tp,mid,dy,dx){var ddX=0,ddY=0;if(this.timerid2[this.group]&&clearTimeout(this.timerid2[this.group]),this.have_active[this.group].indexOf(","+this.id+",")>=0)this.hide_menu();else{dy||(dy=0),dx||(dx=0),mid&&(ddX=$("#"+mid)[0].offsetLeft,ddY=$("#"+mid)[0].offsetTop),this.allmenus_hidenp(),par=par?$("#"+par)[0]:this.obj.parentNode;var pos=_uGetOffset(par);pos.left+=dx-ddX,pos.top+=dy-ddY,"r"==tp?pos.left+=par.offsetWidth-4:pos.top+=par.offsetHeight+1;var ww=$(window).width();
1with(this.obj.style)left=pos.left+"px",top=pos.top+"px",display="",visibility="visible";try{pos.left+this.obj.offsetWidth>ww&&(pos.left=ww-this.obj.offsetWidth-5,this.obj.style.left=pos.left+"px")}catch(e){}this.have_active[this.group]||(this.have_active[this.group]=""),this.have_active[this.group]+=","+this.id+",",this.timerid[this.group]&&clearTimeout(this.timerid[this.group]),this.donothide[this.group]=!0,this.timerid[this.group]=setTimeout("with (_uMenu.prototype){donothide['"+this.group+"']=false;timerid['"+this.group+"']=null;};",100)}},allmenus_hidenp:function(){for(var t={},e=this.id;this.all_menus[this.group][e]&&this.all_menus[this.group][e].parentid!=e&&e;)t[this.all_menus[this.group][e].parentid]=1,e=this.all_menus[this.group][e].parentid;for(var s in this.all_menus[this.group])1!=t[s]&&this.all_menus[this.group][s].hide_menu()},hide_menu:function(){with(this){hide_child();var x=have_active[group].indexOf(","+id+",");x>=0&&(have_active[group]=have_active[group].substring(0,x)),obj.style.display="none",obj.style.visibility="hidden"}},hide_child:function(){with(this)for(var i in all_menus[group])all_menus[group][i].parentid==id&&i!=id&&all_menus[group][i].hide_menu()}},_uMENU.all=[],_uMENU.nextidx=0,_uMENU.lastz=0,_uMENU.defz=25050,_uMENU.defdesign="std",_uMENU.globalset=!1,_uMENU.ignoreclick=null,_uMENU.onclickTabAsMenu=function(t,e,s,i,o){var a=i.tabctrl,n=i.tabid||i.id||t;a&&a.activateTab(n)},_uMENU._onchangeTabAsMenu=function(t,e,s){var i,o=t.props._prevtabmenu_onchange?t.props._prevtabmenu_onchange.apply(this,arguments):1,a=t._tabasmenu;if(!a)return o;for(var n=0;n<a.elems.length;n++)a.elems[n][2].tabclass&&a.elems[n][2].tabctrl==t&&((i=a.elems[n][2].tabid||a.elems[n][2].id)&&i==s||!i&&n==e?$(a.parts.elems[n]).addClass(a.elems[n][2].tabclass):$(a.parts.elems[n]).removeClass(a.elems[n][2].tabclass));return o},_uMENU.initTabAsMenu=function(t,e){if(e.constructor==_uWnd&&(e=e.menu),e){t._tabasmenu=e,t.props._prevtabmenu_onchange=t.props.onchange,t.props.onchange=_uMENU._onchangeTabAsMenu;for(var s=0;s<t.data.length;s++)t.data[s].onchange&&t.data[s].onchange!=t.props._prevtabmenu_onchange||(t.data[s].onchange=_uMENU._onchangeTabAsMenu)}},_uMENU.getbyname=function(t){for(var e=this.all,s=0;s<e.length;s++)if(e[s]&&e[s].name==t)return e[s];return null},_uMENU.designs={std:{sh_sz:[4,2],menu_init:function(t,e,s,i){var o={};return s.horiz?($(t).attr("class","u-menuh"+(s.addclass?" "+String(s.addclass):"")+(s.withmarks?" u-menumarks":"")).css("overflow","hidden"),$(t).html('<div class="u-menubody"><div class="u-menucont" style="overflow:hidden;height:'+e+'px"></div></div>')):($(t).attr("class","u-menu"+(s.addclass?" "+String(s.addclass):"")+(s.withmarks?" u-menumarks":"")),s.flatStructure?$(t).html(`<div class="u-menucont" style="overflow:visible;height:${e}px;"></div></div>`):$(t).html((i&&i.props.horiz?"":'<div class="xw-tl"><div class="xw-tr"><div class="xw-tc xw-tsps"></div></div></div>')+'<div class="xw-ml"><div class="xw-mr"><div class="xw-mc"><div class="u-menubody"><div class="u-menucont" style="overflow:visible;height:'+e+'px"></div></div></div></div></div><div class="xw-bl"><div class="xw-br"><div class="xw-bc"><div class="xw-footer"></div></div></div></div>'),s.shadow&&t.classList.add("xw-shadow")),o.content=$(t).find(".u-menucont")[0],o.elems=[],o.marks=[],$(t).find("div,span")[$.fn.andSelf?"andSelf":"addBack"]().attr("unselectable","on"),o},setitemtext:function(t,e,s){t.props.withmarks&&null!=t.elems[e][2].mark&&(s='<div class="u-menumark"></div>'+s),$(t.parts.elems[e]).html(s)},append_item:function(t,e,s){var i,o,a,n,r,l,h=t.elems.length;a=e[1]?e[1]:void 0!==e[2].action?e[2].action:t.props.onitem,r=e[2].onldown||t.props.onldown,l=e[2].onrdown||t.props.onrdown,o=e[0],null!=e[2].hl&&(s=e[2].hl),t.props.withmarks&&"sep"!=o&&null!=e[2].mark&&(o='<div class="u-menumark"></div>'+o,n=1),!a||"a"!=a&&"a"!=e[2].action?i=document.createElement("div"):(i=document.createElement("a"),$(i).css("display","block")),t.props.horiz?($(i).css("float","left"),"sep"==o?i.className="u-menuhsep":(i.className="u-menuhitem",a&&a.constructor==_uMENU?($(i).addClass("u-menuhitemparent").html(o),$(i).on("mouseover",{hl:s,item:h,obj:t},_uMENU._onitemmouseover).on("mouseout",{hl:s,item:h,obj:t},_uMENU._onitemmouseout),$(i).on("mousedown",{child:a,obj:t,item:h,itemobj:e},_uMENU._onitemclick),e[2].action&&$(i).on("click",{act:e[2].action,obj:t,item:h,itemobj:e},_uMENU._onitemclick),(r||l)&&$(i).on("mousedown",{actl:r,actr:l,obj:t,item:h,itemobj:e},_uMENU._onitemmousedown)):($(i).html(o),s&&$(i).on("mouseover",{hl:s,item:h,obj:t},_uMENU._onitemmouseover).on("mouseout",{hl:s,item:h,obj:t},_uMENU._onitemmouseout),a&&$(i).on("click",{act:a,obj:t,item:h,itemobj:e},_uMENU._onitemclick),(r||l)&&$(i).on("mousedown",{actl:r,actr:l,obj:t,item:h,itemobj:e}
1,_uMENU._onitemmousedown)))):"sep"==o?i.className="u-menuvsep":(i.className="u-menuvitem",a&&a.constructor==_uMENU?($(i).addClass("u-menuvitemparent").html('<div class="u-menuarrow"></div>'+o),$(i).on("mouseover",{hl:s,item:h,obj:t},_uMENU._onitemmouseover).on("mouseout",{hl:s,item:h,obj:t},_uMENU._onitemmouseout),$(i).on("mousedown",{child:a,obj:t,item:h,itemobj:e},_uMENU._onitemclick),e[2].action&&$(i).on("click",{act:e[2].action,obj:t,item:h,itemobj:e},_uMENU._onitemclick),(r||l)&&$(i).on("mousedown",{actl:r,actr:l,obj:t,item:h,itemobj:e},_uMENU._onitemmousedown)):($(i).html(o),s&&$(i).on("mouseover",{hl:s,item:h,obj:t},_uMENU._onitemmouseover).on("mouseout",{hl:s,item:-1,obj:t},_uMENU._onitemmouseout),a&&$(i).on("click",{act:a,obj:t,item:h,itemobj:e},_uMENU._onitemclick),(r||l)&&$(i).on("mousedown",{actl:r,actr:l,obj:t,item:h,itemobj:e},_uMENU._onitemmousedown))),s&&$(i).find("*")[$.fn.andSelf?"andSelf":"addBack"]().filter("[nodeType=1]").attr("unselectable","on"),t.elems[h]=e,t.parts.elems[h]=i,n&&(t.parts.marks[h]=$(i).find(".u-menumark")[0]),t.props.horiz&&(t.props.rtl||window._rtl)?t.parts.content.insertBefore(i,t.parts.content.firstChild):t.parts.content.appendChild(i)},calc_size:function(t){var e=0,s=0,i=0,o=0;if(t.props.horiz){for(a=0;a<t.parts.elems.length;a++)e+=Math.max(t.parts.elems[a].offsetWidth,t.parts.elems[a].scrollWidth),s=Math.max(s,t.parts.elems[a].offsetHeight);e+=2}else{for(var a=0;a<t.parts.elems.length;a++)e=Math.max(e,Math.max(t.parts.elems[a].offsetWidth,t.parts.elems[a].scrollWidth)),i+=Math.max(o,parseInt("0"+$(t.parts.elems[a]).css("margin-top"))),o=parseInt("0"+$(t.parts.elems[a]).css("margin-bottom")),s+=t.parts.elems[a].offsetHeight;s+=i+o}return{w:e,h:s}},_onitemhl:function(t,e){e?$(this).addClass("u-menuitemhl"):$(this).removeClass("u-menuitemhl")}}},_uMENU._onitemmouseover=function(t){var e=t.data;e.obj.removehl(e.item),e.hl&&e.obj.design._onitemhl.apply(this,[t,1]),e.obj.hlitem=e.item,e.obj.hidetimer&&clearTimeout(e.obj.hidetimer),e.obj.hidetimer=null,e.item>=0&&(e.obj.props.horiz&&!e.obj._focus.isactive()||e.obj.schedule_childopen(e.item))},_uMENU._onitemmouseout=function(t){var e,s=t.data;if(s.hl){if(s.obj.props.statical&&s.obj._focus.isactive())return;if(s.item==s.obj.hlitem&&s.item>=0){if((e=s.obj.elems[s.item])&&e[1]&&e[1].constructor==_uMENU&&e[1].state.visible)return;s.obj.design._onitemhl.apply(this,[t,0]),s.obj.hlitem=-1}}},_uMENU._onitemclick=function(t){var e=t.data,s=e.itemobj[1]||e.itemobj[2].action||e.obj.props.onitem;if(e.child||!s)e.child&&(e.obj.reset_childopen(),e.obj.hidechildren(e.child),e.obj.props.statical&&e.child.state.visible?(e.child.hide(),e.obj._focus.deactivate()):e.child.state.visible||(e.obj.props.statical&&e.obj.sethl(e.item),e.obj.childopen(e.item),_uMENU.ignoreclick=e.child));else if(e.obj.props.statical?e.obj.hidechildren():e.obj.hide(!0),s.constructor==Function)s.apply(e.itemobj[2].thispar||e.obj.props.thispar,[e.item,e.obj,e.itemobj[2].id,e.itemobj[2],t]);else if("a"==s){var i=null;if(this==t.target||"a"!=t.target.tagName.toLowerCase()){if(this!=t.target){var o=$(this).parents()[$.fn.andSelf?"andSelf":"addBack"]();i=0==$(t.target).parents().not(o).filter("A").length?$(this).find("a")[0]:null}else i=$(this).find("a")[0];if(i&&(this.target=i.target,this.href=i.href,i.onclick))return i.onclick()}i||this.removeAttribute("href")}},_uMENU._onitemmousedown=function(t){var e=t.data,s=e.actl||e.obj.props.onldown,i=e.actr||e.obj.props.onrdown;1==t.which&&t.ctrlKey&&(t.which=3),1==t.which&&s?(_uWnd.globalmousedown(),s.apply(e.itemobj[2].thispar||e.obj.props.thispar,[e.item,e.obj,e.itemobj[2].id,e.itemobj[2],t]),t.stopPropagation()):3==t.which&&i&&(i.apply(e.itemobj[2].thispar||e.obj.props.thispar,[e.item,e.obj,e.itemobj[2].id,e.itemobj[2],t]),t.preventDefault(),t.stopPropagation())},_uMENU.hideallmenus=function(){var t,e,s;t:for(t=0;t<_uMENU.all.length;t++)if((e=_uMENU.all[t])&&e.state.visible){for(s=_uMENU.ignoreclick;s;){if(s==e)continue t;s=s.pos.parent}e.props.statical?e._focus.deactivate():e.hide()}_uMENU.ignoreclick&&setTimeout("_uMENU.ignoreclick=null;",10)},_uMENU._onmenumousedown=function(t){t.data.props.wnd&&t.data.props.wnd.activate(t,1),1==t.which&&t.ctrlKey&&(t.which=3),3==t.which&&t.data.props.horiz||(_uMENU.ignoreclick||(_uMENU.ignoreclick=t.data),_uWnd.globalmousedown(2),t.stopPropagation())},_uMENU.prototype={removehl:function(t){var e,s=this.hlitem;s>=0&&("number"!=typeof t||s!=t)&&((e=this.elems[s])&&"sep"!=e[0]&&(null!=e[2].hl?e[2].hl:this.props.highlight)&&this.design._onitemhl.apply(this.parts.elems[s],[null,0]),this.hlitem=-1)},sethl:function(t){var e;this.hlitem!=t&&(this.removehl(t),(e=this.elems[t])&&"sep"!=e[0]&&(null!=e[2].hl?e[2].hl:this.props.highlight)&&this.design._onitemhl.apply(this.parts.elems[t],[null,1]),this.hlitem=t)},onfocusdeactivate:function(){this.props.statical?this.removehl():this.hide()},onkeydown:function(t,e,s){var i,o,a,n,r,l,h,d=t.keyCode;if(27==d&&s==this._focus)return this.props.statical?(this.hidechildren(),this._focus.deactivate()):(this.hide(),this.pos.parent&&this.pos.parent.props.statical&&this.pos.parent._focus.deactivate()),t.preventDefault(),t.stopPropagation(),1;if((17==d||18==d)&&t.ctrlKey&&t.altKey)return this._focus.deactivate(),t.preventDefault(),t.stopPropagation(),1;if((13==d||40==d&&this.props.horiz)&&s==this._focus){if(t.preventDefault(),t.stopPropagation(),this.hlitem<0)return 1;o=this.hlitem;var u=(a=this.elems[o])[1]||a[2].action||this.props.onitem,p=a[2].onldown||this.props.onldown;return n=0,u&&u.constructor==_uMENU?(this.reset_childopen(),this.hidechildren(o),u.state.visible||this.childopen(o,0)):a[2].action?u=a[2].action:u&&u.constructor==Function||(u=null),40==d?1:(u&&u.constructor==Function&&(u.apply(a[2].thispar||this.props.thispar,[o,this,a[2].id,a[2],t]),n=1),p&&p.constructor==Function&&(p.apply(a[2].thispar||this.props.thispar,[o,this,a[2].id,a[2],t]),n=1),n&&(this.props.statical?this.hidechildren():this.hide(1)),1)}if(93==d&&s==this._focus){if(t.preventDefault(),t.stopPropagation(),this.hlitem<0)return 1;o=this.hlitem;var c=(a=this.elems[o])[2].onrdown||this.props.onrdown;return c&&c.constructor==Function&&c.apply(a[2].thispar||this.props.thispar,[o,this,a[2].id,a[2],t]),1}if((37==d||39==d)&&s==this._focus&&!this.props.horiz){if(t.preventDefault(),t.stopPropagation(),39==d&&this.hlitem>=0){if(o=this.hlitem,(a=this.elems[o])&&a[1]&&a[1].constructor==_uMENU)return this.childopen(o,0),1}else if(37==d&&this.pos.parent&&!this.pos.parent.props.horiz)return this.hide(),1;for(a=this.pos.parent;a&&!a.props.horiz&&a!=this;)a=a.pos.parent;a&&a.props.horiz&&a.onkeydown(t,e,a._focus)}if((40==d||38==d||(37==d||39==d)&&this.props.horiz)&&s==this._focus){if(t.preventDefault(),t.stopPropagation(),this.props.horiz&&(40==d||38==d))return 1;for(h=40==d||39==d?1:-1,r=o=this.hlitem,i=this.elems.length,l=0;l<i&&(((o+=h)>=i||o<0)&&(o=h>0?0:i-1),!(a=this.elems[o])||"sep"==a[0]||!(null!=a[2].hl?a[2].hl:this.props.highlight));l++);return l>=i||r==o||(this.hlitem=o,r>=0&&(a=this.elems[r])&&"sep"!=a[0]&&(null!=a[2].hl?a[2].hl:this.props.highlight)&&(this.design._onitemhl.apply(this.parts.elems[r],[t,0]),this.reset_childopen()),this.design._onitemhl.apply(this.parts.elems[o],[t,1]),this.hidetimer&&clearTimeout(this.hidetimer),this.hidetimer=null,this.props.horiz&&this.childopen(o,0)),1}},moveTo:function(x,y){with(this)$(top).css("left",x+"px").css("top",y+"px"),xpos=x,ypos=y},resizeTo:function(w,h){with(this)0==props.width?$(menu).css("width",w+"px"):"auto"!=props.width?$(menu).css("width",props.width):$(menu).css("width","auto"),props.horiz?($(menu).css("height",h+"px"),$(parts.content).css("width",w-decor.w+"px").css("height",h-decor.h+"px")):($(parts.content).css("width",w-decor.w+"px"),$.browser&&$.browser.opera&&$(top).css("width",w+"px")),w<0&&(w=0),frame&&$(frame).css("width",w+"px").css("height",h+"px"),width=w,height=h},init1:function(nocalcsize){with(this)decor.w=menu.offsetWidth-parts.content.offsetWidth,decor.w<0&&(decor.w=0),decor.h=menu.offsetHeight-(props.horiz?10:50),decor.h<0&&(decor.h=0),state.init=!0,_initsubmenus(),add_elems?appendItems(null,0,nocalcsize):(pend_show&&show(pend_show),props.onreadycreate&&(props.onreadycreate.call?props.onreadycreate.call(props.thispar,this):props.onreadycreate(this)),props.onreadycreate=null)},show:function(t,e){if(!this.state.destroyed)if(this.state.init){if(this.pend_show=null,this.pos=$.extend(this.pos,t||{}),!this.pos.parent||this.pos.parent.state.visible){if(this._focus.deactivate(),this._focus._parent=this.pos.parentfocus?this.pos.parentfocus:this.pos.parent?this.pos.parent._focus:this.props.wnd?this.props.wnd._focus:null,this.pos.parent?this.zpos=this.pos.parent.zpos+5:this.zpos=_uMENU.defz,$(this.top).css("z-index",this.zpos),this.pos.pos||this.pos.alignObj){var s,i,o;this.pos.alignObj?(b=this.pos.alignObj,s=$(b).offset(),i=b.offsetWidth,o=b.offsetHeight):(s={left:this.pos.pos.x,top:this.pos.pos.y},i=o=0);var a,n,r,l=_uWnd.getdims(),h=l.clientW,d=l.clientH,u=l.clientLeft,p=l.clientTop,c=this.pos.align||"d";this.props.wnd&&this.props.wnd.desktop&&(h=(l=this.props.wnd.desktop).calcwidth(),d=l.calcheight(),u=l.calcexclude(0),p=l.calcexclude(2)),n=this.props.rtl||window._rtl?s.left+i+this.pos.dx-this.width:s.left+this.pos.dx,r=s.top+this.pos.dy,"r"==c||"R"==c?n=s.left+i+this.pos.dx:"l"==c||"L"==c?n=s.left-this.width+this.pos.dx:"d"==c||"D"==c?r=s.top+o+this.pos.dy:"u"!=c&&"U"!=c||(r=s.top-this.height+this.pos.dy),(n-u+this.width>h-3-this.design.sh_sz[0]||n-u<1)&&("R"==c||"U"==c?n=s.left-this.width-this.pos.dx:"L"==c&&(n=s.left+i-this.pos.dx)),n-u+this.width>h-3&&(n=h-3-this.design.sh_sz[0]-this.width+u),n-u<1&&(n=1+u),(r-p+this.height>d-3-this.design.sh_sz[1]||r-p<1)&&("D"==c?r=s.top-this.height-this.pos.dy:"U"==c&&(r=s.top+o-this.pos.dy)),r-p+this.height>d-3&&(r=d-3-this.design.sh_sz[1]-this.height+p),r-p<1&&(r=1+p),this.props.parentnode&&((a=$(this.props.parentnode).offset()).left+=(parseInt(j
1Query.css(this.props.parentnode,"borderLeftWidth",!0),10)||0)-$(this.props.parentnode).scrollLeft(),a.top+=(parseInt(jQuery.css(this.props.parentnode,"borderTopWidth",!0),10)||0)-$(this.props.parentnode).scrollTop(),n-=a.left,r-=a.top),this.moveTo(n,r)}if(this.props.onshow&&this.props.onshow.apply(this.props.thispar,[this,this.idx]),this.props.withmarks)for(var m=0;m<this.elems.length;m++){var f=this.elems[m];if(f&&f[2]&&this.parts.marks[m])if(f[2].mark){var _=f[2].marktext||this.props.withmarks;"object"==typeof _&&_.constructr!=String&&(_=_[f[2].mark]),$(this.parts.marks[m]).html(String(_)).css("display","block")}else this.parts.marks[m].style.display="none"}var b;if(this.props.statical||this.removehl(),$(this.top).show(),this.state.visible=!0,this.props.statical||this._focus.activate(),null!=typeof e&&NaN!=Number(e))if((b=Number(e))>=0&&b<this.elems.length){var g=this.elems[b];g&&"sep"!=g[0]&&(null!=g[2].hl?g[2].hl:this.props.highlight)&&(this.design._onitemhl.apply(this.parts.elems[b],[null,1]),this.hlitem=b)}this.props.hidetimer>0&&(this.hidetimer=setTimeout("var _um=_uMENU.all["+this.idx+"]; if (_um)_um.hide();",this.props.hidetimer))}}else this.pend_show=t||{}},hidechildren:function(t){if(!this.state.destroyed)for(var e=this.elems,s=0;s<e.length;s++)e[s]&&e[s].constructor==Array&&e[s][1]&&e[s][1].constructor==_uMENU&&e[s][1]!=t&&e[s][1].hide()},hide:function(t){if(!this.state.destroyed&&this.state.visible&&($(this.top).hide(),this.state.visible=!1,this.hidetimer&&clearTimeout(this.hidetimer),this.hidetimer=null,this.pend_show=null,this.hidechildren(),this.props.onhide&&this.props.onhide.apply(this.props.thispar,[this,this.idx]),this._focus.deactivate(),t)){for(var e=this.pos.parent;e&&!e.props.statical&&e!=this;)e.hide(!1),e=e.pos.parent;e&&e!=this&&e.props.statical&&e._focus.deactivate()}},childopen:function(t,e){if(!this.state.destroyed){this.childtimer&&clearTimeout(this.childtimer),this.childtimer=null;var s=this.parts.elems[t],i=this.elems[t];i&&((i=i[1])&&i.constructor==_uMENU?(this.hidechildren(i),i.show({dx:this.props.horiz?0:-3*(this.props.rtl||window._rtl?-1:1),alignObj:s,align:this.props.horiz?"D":this.props.rtl||window._rtl?"L":"R",parent:this},e)):this.hidechildren(i))}},schedule_childopen:function(t){if(!this.state.destroyed){this.childtimer&&clearTimeout(this.childtimer);var e=this.elems[t];e&&e[1]&&e[1].constructor==_uMENU&&e[1].state.visible?this.childtimer=null:this.childtimer=setTimeout("var _um=_uMENU.all["+this.idx+"]; if (_um)_um.childopen("+t+");",100)}},reset_childopen:function(){this.childtimer&&clearTimeout(this.childtimer)},_initsubmenus:function(){with(this){for(var i=0;i<toinit.length;i++)toinit[i].init1(!0),tocalcsize[tocalcsize.length]=toinit[i];toinit.length=0}},_calcsizesubmenus:function(){with(this){for(var i=0;i<tocalcsize.length;i++)tocalcsize[i]._setsize();tocalcsize.length=0}},createsubmenus:function(){var t,e=!1;for(t=0;t<this.add_elems.length;t++)for(var s=this.add_elems[t],i=s.length,o=0;o<i;o++)if(s[o]&&s[o].constructor==Array&&s[o][1]&&s[o][1].constructor==Array){var a,n={};s[o][2]&&"object"==typeof s[o][2]?n=s[o][2]:"number"==typeof s[o][2]?n={hl:s[o][2]}:"string"==typeof s[o][2]&&(n={id:s[o][2]}),s[o][2]=n,a=new _uMENU("",$.extend({parent:this,dx:this.props.horiz?this.pos.childd
1x:0,dy:this.props.horiz?this.pos.childdy:0},n.pos||{}),$.extend({shadow:this.props.shadow,rtl:this.props.rtl?1:0,parentnode:this.props.wnd?this.props.wnd.top:this.props.parentnode,wnd:this.props.wnd,onitem:this.props.onitem,onshow:this.props.onshow,onhide:this.props.onhide,thispar:this.props.thispar,flatStructure:this.props.flatStructure},n.opts||{}),s[o][1],!0),s[o][1]=a,this.toinit[this.toinit.length]=a,e=!0}return e},indexById:function(t){if("number"==typeof t)return t>=0&&t<this.elems.length?t:-1;t=String(t);for(var e=0;e<this.elems.length;e++)if(this.elems[e][2].id===t)return e;return-1},setItemText:function(t,e){(t=this.indexById(t))<0||this.design.setitemtext(this,t,e)},itemOptions:function(t){return(t=this.indexById(t))<0?null:this.elems[t][2]},removeItems:function(t,e,s){var i,o,a;if(null==t||null==t)for(t=[],i=0;i<this.elems.length;i++)t[i]=this.elems.length-1-i;else t.constructor!=Array&&(t=[t]);for(i=0;i<t.length;i++)null!=t[i]&&null!=t[i]&&t[i].constructor==Number||(t[i]=this.indexById(t[i]));for(t.sort(function(t,e){return e-t}),o=-1,i=0;i<t.length;i++)t[i]==o||t[i]<0||t[i]>=this.elems.length||(a=this.elems[t[i]],!e&&a&&a.constructor==Array&&a[1]&&a[1].constructor==_uMENU&&a[1].destroy(),this.elems.splice(t[i],1),this.parts.elems[t[i]].parentNode.removeChild(this.parts.elems[t[i]]),this.parts.elems.splice(t[i],1),o=t[i]);s||this.appendItems(null,0)},appendItems:function(t,e,s){if(!this.state.destroyed&&(t&&t.constructor==Array&&t.length>0&&(this.add_elems[this.add_elems.length]=t),this.state.init))if(this.createsubmenus())setTimeout("var _um=_uMENU.all["+this.idx+"]; if (_um){_um._initsubmenus(); _um.appendItems(null,0,"+s+");}",10);else{var i;for(this.appendtimer&&clearTimeout(this.appendtimer),this.appendtimer=null,$(this.top).css("visibility","hidden").css("display","block"),this.props.horiz?(this.props.noabs?$(this.menu).css("width",0==this.props.width||"auto"==this.props.width?"auto":this.props.width+"px"):$(this.menu).css("width","2100px").css("height","auto"),$(this.parts.content).css("width","2000px").css("height","auto")):($.browser&&$.browser.opera&&$(this.top).css("width","2000px"),$(this.menu).css("width","auto").css("height","auto"),$(this.parts.content).css("width","auto").css("height","auto")),i=0;i<this.add_elems.length;i++)for(var o=(t=this.add_elems[i]).length,a=0;a<o;a++){t[a]&&t[a].constructor==Array||(t[a]=[""+t[a]]);var n={};t[a][2]&&"object"==typeof t[a][2]?n=t[a][2]:"number"==typeof t[a][2]?n={hl:t[a][2]}:"string"==typeof t[a][2]&&(n={id:t[a][2]}),t[a][2]=n,this.design.append_item(this,t[a],this.props.highlight)}this.add_elems.splice(0,i),s||(this.appendtimer=setTimeout("var _um=_uMENU.all["+this.idx+"]; if (_um){_um.appendtimer=null; _um._setsize();}",10))}},_setsize:function(){var t=this.design.calc_size(this);this.resizeTo(t.w+this.decor.w,t.h+this.decor.h),this._calcsizesubmenus(),$(this.top).css("display","none").css("visibility",""),(this.pend_show||this.state.visible)&&this.show(this.pend_show);var e=this.props.onreadycreate;if(e&&(this.props.onreadycreate=null,e.call?e.call(this.props.thispar,this):e(this)),this.onsetsize){var s=this.onsetsize;this.onsetsize=null,this.props.wnd&&s.apply(this.props.wnd)}},destroy:function(){this.state.destroyed||(this.removeItems(),this.top.parentNode.removeChild(this.top),_uMENU.all[this.idx]=null,this._focus.destroy(),this.state.destroyed=!0,this.props.ondestroy&&this.props.ondestroy.apply(this.props.thispar,[this,this.idx]))}},_uComboBox.all=[],_uComboBox.nextidx=0,_uComboBox.defz=20015,_uComboBox.globalset=!1,_uComboBox.ignoreclick=null,_uComboBox.getbyname=function(t){for(var e=this.all,s=0;s<e.length;s++)if(e[s]&&e[s].name==t)return e[s];return null},_uComboBox.hideall=function(){for(var t=_uComboBox.all,e=0;e<t.length;e++)t[e]&&!t[e].destroyed&&_uComboBox.ignoreclick!=t[e]&&t[e].hidelist();_uComboBox.ignoreclick&&setTimeout("_uComboBox.ignoreclick=null;",10)},_uComboBox.designs={std:{combo_init:function(t){var e={};
1return t.combo=$('<table id="_ucombo'+t.idx+'" style="position:relative" cellspacing="0" cellpadding="0" border="0" class="x-unselectable u-combo" align="'+(t.props.rtl?"right":"left")+'"><tr><td class="u-comboeditcell"></td>'+(t.props.filter&&t.props.nodropdown?"":'<td class="u-combobutcell"><div class="u-combobut"></td>')+"</tr></table>")[0],t.obj.parentNode.insertBefore(t.combo,t.obj),t.parent!=t.obj.parentNode?t.parent.appendChild(t.toplist):t.parent.insertBefore(t.toplist,t.obj),e.editcell=$(t.combo).find(".u-comboeditcell")[0],t.props.filter&&t.props.nodropdown?e.button=e.butcell=null:(e.button=$(t.combo).find(".u-combobut")[0],e.butcell=$(t.combo).find(".u-combobutcell")[0]),e.editcell.appendChild(t.obj),t.props.readonly&&e.editcell.appendChild(t.valobj),$(t.obj).attr("class","x-selectable u-comboedit"+(t.haveicons?" u-comboeditimg":"")+" "+$(t.obj).attr("class")),t.tablemode?$(t.toplist).append('<div class="u-combolist"><div style="zoom:1"><table border="0" cellspacing="0" class="x-unselectable u-combocont" width="100%"></table></div></div>'):$(t.toplist).append('<div class="u-combolist"><div style="zoom:1"></div></div>'),e.list=$(t.toplist).find(".u-combolist")[0],t.props.maxlistheight>=50&&t.havemaxheight&&$(e.list).css({maxHeight:t.props.maxlistheight+"px",overflow:"auto"}),e.listc=e.list.firstChild,t.tablemode?e.content=$(t.toplist).find(".u-combocont")[0]:e.content=null,t.props.readonly?t.props.filter||$(t.obj).on("mousedown",function(t){return t.preventDefault(),0}):e.button&&$(e.button).on("mousedown",t,_uComboBox._onbutclick),e.button&&$(e.button).on("mouseover",t.design._onbutmouseover).on("mouseout",t.design._onbutmouseout),e.items=[],t.props.filter&&t.props.nodropdown&&t.props.emptyprompt?(t.tablemode?(e.row_prompt=e.content.insertRow(0),$(e.row_prompt).css("display","none"),$(e.row_prompt.insertCell(0)).attr("class","u-combocell0").attr("colspan",t.tablecols).html(t.props.emptyprompt)):(e.row_prompt=document.createElement("DIV"),e.row_prompt._attached=0,$(e.row_prompt).addClass("u-combocell0").html(t.props.emptyprompt)),$(e.row_prompt).addClass("u-comborow").addClass("u-comboemptyprompt").on("mousedown",function(t){return 0})):e.row_prompt=null,t.props.filter&&t.props.nomatchtext?(t.tablemode?(e.row_nomatch=e.content.insertRow(0),$(e.row_nomatch).css("display","none"),$(e.row_nomatch.insertCell(0)).attr("class","u-combocell0").attr("colspan",t.tablecols).html(t.props.nomatchtext)):(e.row_nomatch=document.createElement("DIV"),e.row_nomatch._attached=0,$(e.row_nomatch).addClass("u-combocell0").html(t.props.nomatchtext)),$(e.row_nomatch).addClass("u-comborow").addClass("u-combonomatch").on("mousedown",function(t){return 0})):e.row_nomatch=null,t.props.filter&&t.props.haveotherprompt&&t.props.filtermax>0?(t.tablemode?(e.row_haveother=e.content.insertRow(0),$(e.row_haveother).css("display","none"),$(e.row_haveother.insertCell(0)).attr("class","u-combocell0").attr("colspan",t.tablecols).html(t.props.haveotherprompt)):(e.row_haveother=document.createElement("DIV"),e.row_haveother._attached=0,$(e.row_haveother).addClass("u-combocell0").html(t.props.haveotherprompt)),$(e.row_haveother).addClass("u-comborow").addClass("u-combonomatch").on("mousedown",function(t){return 0})):e.row_haveother=null,$(t.toplist).find("div,span,table")[$.fn.andSelf?"andSelf":"addBack"]().attr("unselectable","on"),e},content_reset:function(t){if(!t.tablemode){var e=$('<div class="x-unselectable u-combocont"></div>')[0];t.parts.listc.insertBefore(e,t.parts.content),t.parts.content=e,t.parts.row_prompt&&(t.parts.row_prompt._attached=0),t.parts.row_nomatch&&(t.parts.row_nomatch._attached=0),t.parts.row_haveother&&(t.parts.row_haveother._attached=0)}},append_item:function(t,e,s){var i,o,a,n;if(t.tablemode){a=t.parts.content,i=t.parts.items[s]=a.insertRow(s);for(var r=0;r<t.tablecols;r++)o=i.insertCell(r),t.props.filter||(n=r+3<e.length?e[r+3]:0==r?e[0]:"",0==r&&e[1]&&(n='<img class="u-comborowicon" border="0" src="'+e[1]+'">'+n.replace(/&/g,"&amp;").replace(/</g,"&lt;")),$(o).attr("class","u-combocell"+r).html(n)),$(o).attr("class","u-combocell"+r),t.colwidth[r]&&$(o).attr("width",t.colwidth[r])}else i=t.parts.items[s]=document.createElement("DIV"),t.props.filter||$(i).html((e[1]?'<img class="u-comborowicon" border="0" src="'+e[1]+'">':"")+(e.length>3?e[3]:e[0]).replace(/&/g,"&amp;").replace(/</g,"&lt;")),$(i).attr("class","u-combocell0");$(i).addClass("u-comborow").on("mouseover",t,_uComboBox._onitemmouseover).on("mouseout",t,_uComboBox._onitemmouseout).on("click",{obj:t,idx:s},_uComboBox._onitemclick),$(i).find("*")[$.fn.andSelf?"andSelf":"addBack"]().attr("unselectable","on")},remove_item:function(t,e){if(!(e<0||e>=t.parts.items.length)){if(t.tablemode){var s=t.parts.content;if(e>=s.rows.length)return;$(s.rows[e]).off(),s.deleteRow(e)}else t.parts.items[e].parentNode&&t.parts.items[e].parentNode.removeChild(t.parts.items[e]);t.parts.items.splice(e,1)}},_onitemmouseover:function(t,e){e?$(this).addClass("u-comborowhl"):$(this).removeClass("u-comborowhl")},_onbutmouseover:function(){$(this).addClass("u-combobuthl")},_onbutmouseout:function(){$(this).removeClass("u-combobuthl")},_onlistopen:function(t){$(t.combo).addClass("u-comboopen")},_onlisthide:function(t){$(t.combo).removeClass("u-comboopen")},_onfocus:function(t,e){$(t.combo).addClass("u-combofocus")},_onblur:function(t,e){$(t.combo).removeClass("u-combofocus")},_select:function(t,e){$(t.parts.items[e]).addClass("u-comborowsel")},_deselect:function(t,e){$(t.parts.items[e]).removeClass("u-comborowsel")},onprompt:function(t,e){e?$(t.obj).addClass("u-comboprompt"):$(t.obj).removeClass("u-comboprompt")},seticon:function(t,e){e?$(t.obj).css("background-image","url("+e+")"):$(t.obj).css("background-image",t.props.deficon?"url("+t.props.deficon+")":"none")}}},_uComboBox._onitemmouseover=function(t){t.data.design._onitemmouseover.apply(this,[t,1]),t.data.to_unHL.push(this)},_uComboBox._onitemmouseout=function(t){var e,s=t.data.to_unHL;for(t.data.design._onitemmouseover.apply(this,[t,0]),e=0;e<s.length;e++)s[e]==this&&s.splice(e,1)},_uComboBox._onitemclick=function(t){var e=t.data,s=e.obj;s.obj.focus(),s.hidelist(),s.select(e.idx),t.preventDefault()},_uComboBox._onbutclick=function(t){var e=t.data;_uComboBox.ignoreclick=t.data,e.opened?e.hidelist():(e.showlist(),_uComboBox.ignoreclick=t.data),e.obj.focus(),t.preventDefault()},_uComboBox._onlistmousedown=function(t){_uComboBox.ignoreclick=t.data,t.data.obj.focus(),t.preventDefault()}
1,_uComboBox._oncombomousedown=function(t){if(_uComboBox.ignoreclick=t.data,1==t.which){var e=t.data;e.props.readonly&&(e.opened?e.hidelist():(e.showlist(),_uComboBox.ignoreclick=t.data)),e.obj.focus(),t.target!=e.obj&&t.preventDefault()}},_uComboBox._onobjfocus=function(t){t.data._onobjfocus(t)},_uComboBox._onobjblur=function(t){t.data.cancelblur||t.data._onobjblur()},_uComboBox._onobjdeact=function(t){t.data.cancelblur&&t.preventDefault()},_uComboBox.isUpKey=function(t){return 38==t||63232==t},_uComboBox.isDownKey=function(t){return 40==t||63233==t},_uComboBox.prototype={destroy:function(){this.destroyed||(this.props.readonly&&$(this.valobj).remove(),this.toplist&&($(this.toplist).remove(),this.toplist=null),this.combo&&($(this.combo).remove(),this.combo=null),this.frame&&($(this.frame).remove(),this.frame=null),this.parts=null,this.obj=this.valobj=null,this.data=null,this.changetimer&&clearTimeout(this.changetimer),this.blurtimer&&clearTimeout(this.blurtimer),this.showtimer&&clearTimeout(this.showtimer),this.changetimer=this.blurtimer=this.showtimer=null,this.to_unHL=[],this.destroyed=1)},_unhightlight:function(){var t,e=this.to_unHL;for(t=0;t<e.length;t++)this.design._onitemmouseover.apply(e[t],[null,0]);e.splice(0,e.length)},_setvalue:function(i,soft){with(this)i>=0&&i<data.length?(soft&&props.readonly||(valobj.value=data[i][0]),props.readonly?obj.value=prevInput=data[i][2]:prevInput=data[i][0],haveicons&&design.seticon(this,data[i][1])):(props.readonly?(soft||(valobj.value=""),!prompttxt||focused||userInput?(obj.value=prevInput=userInput,isprompt=0,design.onprompt(this,0)):(obj.value=prompttxt,prevInput="",isprompt=1,design.onprompt(this,1))):valobj.value=prevInput=userInput,haveicons&&this.design.seticon(this,null))},_selectitem:function(i){with(this)selected>=0&&selected<data.length&&(design._deselect(this,selected),selected=-1),i>=0&&i<data.length&&(design._select(this,i),selected=i)},setvalue:function(v){with(this){var ch=!1;if(props.readonly)return;changetimer&&clearTimeout(changetimer),valobj.value!=v&&(ch=!0),valobj.value=prevInput=userInput=v,-1!=selected&&(ch=!0),_selectitem(-1),userIdx=-1,haveicons&&this.design.seticon(this,null),props.onchange&&ch&&props.onchange.apply(this.app,[selected,v,this])}},select:function(i,soft){with(this){var ch=!1;changetimer&&clearTimeout(changetimer),changetimer=null,_selectitem(i),_setvalue(selected,soft),soft||(selected!=userIdx&&(ch=!0),userIdx=selected,ch&&updatelist(),props.onchange&&ch&&props.onchange.apply(this.app,[selected,valobj.value,this]))}},_onobjfocus:function(t){this.blurtimer&&clearTimeout(this.blurtimer),this.blurtimer=null,this.focused=1,this.isprompt&&(this.isprompt=0,this.obj.value=this.userInput,this.design.onprompt(this,0)),this.design._onfocus(this,t),this.props.readonly&&!this.opened&&(this.showlist(),_uComboBox.ignoreclick=this)},_onobjblur:function(t){this.blurtimer&&clearTimeout(this.blurtimer),this.focused=0,this.blurtimer=setTimeout("var _ucb=_uComboBox.all["+this.idx+"]; if (_ucb)_ucb._onblur2();",10)},_onblur2:function(e){with(this){if(blurtimer=null,hidelist(),design._onblur(this,e),props.filter&&-1==selected&&-1==userIdx&&userInput&&numdata>0)for(var k=dataindex;k<data.length;k++)if(data[k][4]&&data[k][2]==userInput)return void select(dataindex);select(userIdx,1),prompttxt&&-1==userIdx&&(isprompt=1,obj.value=this.prompttxt,design.onprompt(this,1))}},focus:function(){this.obj.focus()},blur:function(){this.obj.blur()},onkeydown:function(e){var i;with(this){var c=e.keyCode;if(27==c&&opened)return select(userIdx,!0),hidelist(),!1;if(0==data.length||0==numdata)return;if(13==c)return obj.focus(),hidelist(),select(selected),e.preventDefault(),e.stopPropagation(),!1;if(9==c)return void(changetimer&&select(selected));if(_uComboBox.isDownKey(c)||_uComboBox.isUpKey(c))return i=_findnextvalid(selected,_uComboBox.isDownKey(c)?1:-1),select(i,!0),opened||(props.nodropdown?showlist():changetimer=setTimeout("var _ucb=_uComboBox.all["+this.idx+"]; if (_ucb)_ucb.select("+i+");",500)),!1}},onkeyup:function(e){with(this){if(!props.filter&&props.readonly||obj.value==prevInput)return;changetimer&&clearTimeout(changetimer),prevInput=userInput=obj.value;var previdx=userIdx;userIdx=-1,updatelist(),!props.filter||previdx>=0&&(data[previdx][4]<1||!prevfilter)?(_selectitem(-1),props.readonly&&(valobj.value=""),props.onchange&&props.readonly&&-1!=previdx&&props.onchange.apply(this.app,[-1,obj.value,this]),haveicons&&this.design.seticon(this,null)):previdx>=0&&(userIdx=previdx),props.filter&&showlist(),props.onchange&&!props.readonly&&props.onchange.apply(this.app,[-1,obj.value,this])}},appendItem:function(elem){with(this){var i=data.length;data[i]=[elem[0],elem[1],elem.length>
13?elem[3]:elem[0]],"string"!=typeof data[i][2]&&(data[i][2]=String(data[i][2])),props.filter&&(props.translit?data[i][3]=new _uTransStr(data[i][2]):data[i][3]=data[i][2].toLowerCase()),!props.tablemode&&props.filter||design.append_item(this,elem,i),updated=!0,tablemode?(data[i][4]=1,numdata++):data[i][4]=0}},removeItem:function(t){t<0||t>=this.data.length||(this.design.remove_item(this,t),this.data[t][4]>0&&this.numdata--,this.data.splice(t,1),this.updated=!0)},removeAll:function(){for(var t=0;t<this.data.length;t++)this.design.remove_item(this,0);this.data.splice(0,this.data.length),this.updated=!0},hidelist:function(){this.opened&&(this.toplist.style.display="none",this.opened=!1,this.design._onlisthide(this),this._unhightlight())},_findnextvalid:function(ii,d){var j,k;with(this){if(numdata<=0||0==data.length)return-1;if(d>0){if(ii<0)j=dataindex;else if(ii>=data.length-1){if(!props.readonly||props.filter)return-1;j=0}else j=ii+1;for(k=0;k<data.length;k++){if(data[j][4]>0)return j;if(j++,j>=data.length){if(!props.readonly||props.filter)return-1;j=0}}}else{if(ii<0||ii>=data.length)j=data.length-1;else if(0==ii){if(!props.readonly||props.filter)return-1;j=data.length-1}else j=ii-1;for(k=0;k<data.length;k++){if(data[j][4]>0)return j;if(j--,j<0){if(!props.readonly||props.filter)return-1;j=data.length-1}}}}return ii},_marksections:function(t,e){if(t=t.replace(/&/g,"&amp;").replace(/</g,"&lt;"),!e||0==e.length)return t;e.length>1&&e.sort(function(t,e){return t[0]-e[0]});for(var s="",i=0,o=0;o<e.length;o++)o<e.length-1&&e[o+1][0]==e[o][0]+e[o][1]?(e[o+1][0]=e[o][0],e[o+1][1]+=e[o][1]):(e[o][0]>i&&(s+=t.substring(i,e[o][0])),s+='<span class="'+this.props.filtermarkclass+'">'+t.substr(e[o][0],e[o][1])+"</span>",i=e[o][0]+e[o][1]);return i<t.length&&(s+=t.substr(i)),s},_intersect:function(t,e,s){for(var i=0;i<t.length;i++)if(!(e>=t[i][0]+t[i][1]||e+s<=t[i][0]))return 1;return 0},updatelist:function(){with(this){var i,ii,tmp,off,vv,sect,keys,subfilter=0,maxshow,showotherprompt=0;if(!props.filter)return;if(maxshow=props.filtermax>0&&props.filtermax<data.length?props.filtermax:data.length,props.translit){if(tmp=new _uTransStr(userInput),prevfilter==tmp.translit&&prevfilteridx==userIdx)return;prevfilter.length>0&&(0==props.filtertype?tmp.translit.length>prevfilter.length&&tmp.translit.indexOf(prevfilter)>=0&&(subfilter=1):tmp.translit.length>prevfilter.length&&0==tmp.translit.indexOf(prevfilter)&&(subfilter=1)),prevfilter=tmp.translit,prevfilteridx=userIdx,keys=tmp.splitsps(),sect=[]}else{if(tmp=userInput.toLowerCase().replace(/^ */,""),2!=props.filtertype&&(tmp=tmp.replace(/  +/g," ").replace(/ +$/,""),keys=tmp.split(" "),sect=[]),prevfilter==tmp&&prevfilteridx==userIdx)return;prevfilter.length>0&&(0==props.filtertype?tmp.length>prevfilter.length&&tmp.indexOf(prevfilter)>=0&&(subfilter=1):1==props.filtertype&&tmp.length>prevfilter.length&&0==tmp.indexOf(prevfilter)&&(subfilter=1)),prevfilter=tmp,prevfilteridx=userIdx}if(updated=1,prevfilter){if(tablemode||subfilter&&parts.content||design.content_reset(this),parts.row_prompt&&props.nodropdown&&(tablemode?parts.row_prompt.style.display="none":parts.row_prompt._attached&&(parts.content.removeChild(parts.row_prompt),parts.row_prompt._attached=0)),subfilter||(dataindex=-1),numdata=0,props.translit){if(1==props.filtertype){t:for(i=subfilter&&dataindex>=0?dataindex:0,dataindex=-1;i<data.length&&numdata<maxshow;i++)if(!subfilter||0!=data[i][4]){for(sect.length=0,ii=0;ii<keys.length;ii++){for(off=[-1,0,-1];;){if(off=data[i][3].find(keys[ii],off[0]+1,off[2]),!off)break;if(!(off[2]>0&&" "!=data[i][3].translit.charAt(off[2]-1))&&!this._intersect(sect,off[0],off[1]))break}if(!off){data[i][4]>0&&(tablemode?parts.items[i].style.display="none":subfilter&&parts.content.removeChild(parts.items[i])),data[i][4]=0;continue t}sect[ii]=off}tablemode||parts.items[i]||design.append_item(this,null,i),props.filtermarkclass&&(tablemode?parts.items[i].cells[0].innerHTML=_marksections(data[i][2],sect):parts.items[i].innerHTML=_marksections(data[i][2],sect)),tablemode?1!=data[i][4]&&(parts.items[i].style.display=""):subfilter&&1==data[i][4]||parts.content.appendChild(parts.items[i]),data[i][4]=1,numdata++,dataindex<0&&(dataindex=i)}}else t:for(i=subfilter&&dataindex>=0?dataindex:0,dataindex=-1;i<data.length&&numdata<maxshow;i++)if(!subfilter||0!=data[i][4]){for(sect.length=0,ii=0;ii<keys.length;ii++){off=[-1,0,-1];do{if(off=data[i][3].find(keys[ii],off[0]+1,off[2]),!off)break}while(this._intersect(sect,off[0],off[1]));if(!off){data[i][4]>0&&(tablemode?parts.items[i].style.display="none":subfilter&&parts.content.removeChild(parts.items[i])),data[i][4]=0;continue t}sect[ii]=off}tablemode||parts.items[i]||design.append_item(this,null,i),props.filtermarkclass&&(tablemode?parts.items[i].cells[0].innerHTML=_marksections(data[i][2],sect):parts.items[i].innerHTML=_marksections(data[i][2],sect)),tablemode?1!=data[i][4]&&(parts.items[i].style.display=""):subfilter&&1==data[i][4]||parts.content.appendChild(parts.items[i]),data[i][4]=1,numdata++,dataindex<0&&(dataindex=i)}}else if(1==props.filtertype){t:for(i=subfilter&&dataindex>=0?dataindex:0,dataindex=-1;i<data.length&&numdata<maxshow;i++)if(!subfilter||0!=data[i][4]){for(sect.length=0,ii=0;ii<keys.length;ii++){for(off=-1;;){if(off=data[i][3].indexOf(keys[ii],off+1),off<0)break;if(!(off>0&&" "!=data[i][3].charAt(off-1))&&!this._intersect(sect,off,keys[ii].length))break}if(off<0){data[i][4]>0&&(tablemode?parts.items[i].style.display="none":subfilter&&parts.content.removeChild(parts.items[i])),data[i][4]=0;continue t}sect[ii]=[off,keys[ii].length]}tablemode||parts.items[i]||design.append_item(this,null,i),props.filtermarkclass&&(tablemode?parts.items[i].cells[0].innerHTML=_marksections(data[i][2],sect):parts.items[i].innerHTML=_marksections(data[i][2],sect)),tablemode?1!=data[i][4]&&(parts.items[i].style.display=""):subfilter&&1==data[i][4]||parts.content.appendChild(parts.items[i]),data[i][4]=1,numdata++,dataindex<0&&(dataindex=i)}}else if(2==props.filtertype)for(sect=[[0,tmp.length]],i=subfilter&&dataindex>=0?dataindex:0,dataindex=-1;i<data.length&&numdata<maxshow;
1i++)subfilter&&0==data[i][4]||(data[i][3].length<tmp.length||data[i][3].substr(0,tmp.length)!=tmp?(data[i][4]>0&&(tablemode?parts.items[i].style.display="none":subfilter&&parts.content.removeChild(parts.items[i])),data[i][4]=0):(tablemode||parts.items[i]||design.append_item(this,null,i),props.filtermarkclass&&(tablemode?parts.items[i].cells[0].innerHTML=_marksections(data[i][2],sect):parts.items[i].innerHTML=_marksections(data[i][2],sect)),tablemode?1!=data[i][4]&&(parts.items[i].style.display=""):subfilter&&1==data[i][4]||parts.content.appendChild(parts.items[i]),data[i][4]=1,numdata++,dataindex<0&&(dataindex=i)));else t:for(i=subfilter&&dataindex>=0?dataindex:0,dataindex=-1;i<data.length&&numdata<maxshow;i++)if(!subfilter||0!=data[i][4]){for(sect.length=0,ii=0;ii<keys.length;ii++){off=-1;do{off=data[i][3].indexOf(keys[ii],off+1)}while(off>=0&&this._intersect(sect,off,keys[ii].length));if(off<0){data[i][4]>0&&(tablemode?parts.items[i].style.display="none":subfilter&&parts.content.removeChild(parts.items[i])),data[i][4]=0;continue t}sect[ii]=[off,keys[ii].length]}tablemode||parts.items[i]||design.append_item(this,null,i),props.filtermarkclass&&(tablemode?parts.items[i].cells[0].innerHTML=_marksections(data[i][2],sect):parts.items[i].innerHTML=_marksections(data[i][2],sect)),tablemode?1!=data[i][4]&&(parts.items[i].style.display=""):subfilter&&1==data[i][4]||parts.content.appendChild(parts.items[i]),data[i][4]=1,numdata++,dataindex<0&&(dataindex=i)}for(i<data.length&&(showotherprompt=1);i<data.length;i++)data[i][4]>0&&(tablemode?parts.items[i].style.display="none":subfilter&&parts.content.removeChild(parts.items[i])),data[i][4]=-1}else if(props.nodropdown){if(tablemode&&numdata>0)for(i=dataindex;i<data.length;i++)0!=data[i][4]&&(parts.items[i].style.display="none",data[i][4]=0);else if(!tablemode&&(design.content_reset(this),numdata>0))for(i=dataindex;i<data.length;i++)data[i][4]=0;numdata=dataindex=0,parts.row_prompt&&(tablemode?parts.row_prompt.style.display=userIdx>=0?"none":"":userIdx<0&&(parts.content.appendChild(parts.row_prompt),parts.row_prompt._attached=1))}else if(!props.nodropdown&&numdata<data.length){if(tablemode){for(i=0;i<maxshow;i++)parts.items[i].cells[0].innerHTML=data[i][2],data[i][4]>0||(parts.items[i].style.display="",data[i][4]=1);for(i<data.length&&(showotherprompt=1);i<data.length;i++)data[i][4]<0||(parts.items[i].style.display="none",data[i][4]=-1)}else{for(design.content_reset(this),i=0;i<maxshow;i++)parts.items[i]||design.append_item(this,null,i),parts.items[i].innerHTML=data[i][2],parts.content.appendChild(parts.items[i]),data[i][4]=1;for(i<data.length&&(showotherprompt=1);i<data.length;i++)data[i][4]=-1}numdata=maxshow,dataindex=0}parts.row_nomatch&&props.readonly&&(tablemode?parts.row_nomatch.style.display=numdata>0||!prevfilter?"none":"":numdata>0||!prevfilter?(parts.row_nomatch._attached&&parts.content.removeChild(parts.row_nomatch),parts.row_nomatch._attached=0):(parts.row_nomatch._attached||parts.content.appendChild(parts.row_nomatch),parts.row_nomatch._attached=1)),parts.row_haveother&&(tablemode?parts.row_haveother.style.display=showotherprompt?"":"none":showotherprompt?(parts.content.appendChild(parts.row_haveother),parts.row_haveother._attached=1):(parts.row_haveother._attached&&parts.content.removeChild(parts.row_haveother),parts.row_haveother._attached=0)),!tablemode&&!subfilter&&parts.listc.childNodes.length>1&&parts.listc.removeChild(parts.listc.lastChild),opened&&showlist()}},showlist:function(){var t,e,s;if(!(this.opened&&!this.updated||this.props.nodropdown&&this.props.filter&&!this.userInput&&!this.parts.row_prompt)){if(this.opened&&(!this.havemaxheight||"auto"==this.props.maxlistheight))return $(this.parts.list).css({height:"auto",overflow:"hidden"}),this.showtimer&&clearTimeout(this.showtimer),this._showlist(),void(this.updated=!1);var i=$(this.combo).offset(),o=$(this.parent).offset();o.left+=(parseInt(jQuery.css(this.parent,"borderLeftWidth",!0),10)||0)-$(this.parent).scrollLeft(),o.top+=(parseInt(jQuery.css(this.parent,"borderTopWidth",!0),10)||0)-$(this.parent).scrollTop(),e=i.left-o.left,s=i.top-o.top,t="auto"==this.props.listwidth?this.combo.offsetWidth+"px":this.props.listwidth,$(this.toplist).css({left:e+"px",to
1p:s+this.combo.offsetHeight-1+"px",width:t,minWidth:this.combo.offsetWidth+"px"}),this.frame&&$(this.frame).css({width:t}),!this.updated||this.havemaxheight&&"auto"!=this.props.maxlistheight?this.toplist.style.display="block":($(this.parts.list).css({height:"auto",overflow:"hidden"}),$(this.toplist).css({visibility:"hidden"}).css({display:"block"}),this.showtimer&&clearTimeout(this.showtimer),this.showtimer=setTimeout("var _ucb=_uComboBox.all["+this.idx+"]; if (_ucb)_ucb._showlist();",10)),this.design._onlistopen(this),this.opened=!0,this.updated=!1}},_showlist:function(){this.showtimer=null;var t,e,s,i=this.parts.list,o=_uWnd.getdims();t=Math.max(i.scrollHeight,i.offsetHeight),s=$(this.toplist).offset(),(t>(e=this.props.maxlistheight>0?Math.max(50,Math.min(this.props.maxlistheight,o.clientH-s.top)):Math.max(50,o.clientH-s.top))||!t&&this.numdata>0)&&($(this.parts.list).css({height:e+"px",overflow:"auto"}),t=e),this.frame&&$(this.frame).css({height:t+"px"}),$(this.toplist).css({visibility:""})}},_uSuggestList.all=[],_uSuggestList.nextidx=0,_uSuggestList.defz=20015,_uSuggestList.globalset=!1,_uSuggestList.ignoreclick=null,_uSuggestList.getbyname=function(t){for(var e=this.all,s=0;s<e.length;s++)if(e[s]&&e[s].name==t)return e[s];return null},_uSuggestList.hideall=function(){for(var t=_uSuggestList.all,e=0;e<t.length;e++)t[e]&&!t[e].destroyed&&_uSuggestList.ignoreclick!=t[e]&&t[e].onblur(null);_uSuggestList.ignoreclick&&setTimeout("_uSuggestList.ignoreclick=null;",10)},_uSuggestList.casecompare=function(t,e){return t.toLowerCase()==e.toLowerCase()?0:1},_uSuggestList.designs={std:{suggest_init:function(t){var e={};return $(t.obj).attr("class","x-selectable u-suggedit "+$(t.obj).attr("class")),$(t.top).append('<div class="u-sugglist" style="zoom:1"><div style="zoom:1"><table border="0" cellspacing="0" class="x-unselectable u-suggcont" width="100%"></table></div></div>'),e.list=$(t.top).find(".u-sugglist")[0],e.content=$(t.top).find(".u-suggcont")[0],$(t.top).find("div,span,table")[$.fn.andSelf?"andSelf":"addBack"]().attr("unselectable","on"),e},append_row:function(t,e,s,i,o){var a,n=t.parts.content.insertRow(-1),r=t.props.haveDataId?1:0;o?$(n).on("mousedown",t._ignoreevent):$(n).on("mousedown",t,t._onrowmousedown).on("mousemove",t,t._onrowmousemove).on("mouseover",t,t._onrowmouseover),$(n).addClass("u-suggrow").attr("usuggeststr",e[r]),t.props.haveDataId&&$(n).attr("usuggestid",e[0]),(a=String(e[r])).toLowerCase().substr(0,i.length)==i.toLowerCase()&&(a='<span class="u-suggmark">'+a.substr(0,i.length)+"</span>"+a.substr(i.length));for(var l=0;l<s;l++)$(n).append("<td unselectable='on' class='u-suggcell"+l+"'>"+(0==l?a:e[l+r])+"</td>")},update_row:function(t,e,s,i,o){var a,n,r=t.props.haveDataId?1:0;if($(e).attr("usuggeststr",s[r]),t.props.haveDataId&&$(e).attr("usuggestid",s[0]),(a=String(s[r])).toLowerCase().substr(0,o.length)==o.toLowerCase()&&(a='<span class="u-suggmark">'+a.substr(0,o.length)+"</span>"+a.substr(o.length)),e.cells.length==i)for(n=0;n<i;n++)e.cells[n].innerHTML=0==n?a:s[n+r];else{for(n=0;n<cells.length;n++)e.deleteCell(0);for(n=0;n<i;n++)$(e).append("<td unselectable='on' class='u-suggcell"+n+"'>"+(0==n?a:s[n+r])+"</td>")}},_select:function(t,e){$(e).addClass("u-suggrowhl")},_deselect:function(t,e){$(e).removeClass("u-suggrowhl")}}},_uSuggestList.prototype={queryCache:[],destroy:function(){with(this){if(destroyed)return;destroyed=1,top&&$(top).remove(),obj&&$(obj).off(),hideTimer&&clearTimeout(hideTimer),remoteReqTimer&&clearTimeout(remoteReqTimer),AJAXTimer&&clearTimeout(AJAXTimer);try{AJAXObj&&AJAXObj.abort()}catch(e){}for(var i in _uSuggestList.all[idx]=null,this)"destroyed"!=i&&"idx"!=i&&"function"!=typeof i&&(this[i]=null)}},onsubmitform:function(t){this.visible&&(""!=this.resultInput&&(props.preserveonout?setValue(_getvalue_sep(),dataid):(_setvalue_sep(userInput),dataid=props.emptyDataId)),this.hide())},hide:function(){with(this)top.style.display="none",visible=!1,hlRow&&design._deselect(this,hlRow),hlRow=null,hlIndex=-1},show:function(){with(this)if(!visible&&numItems()>0){var w=obj.offsetWidth,x,y,off,offp;off=$(obj).offset(),offp=$(parent).offset(),offp.left+=(parseInt(j
1Query.css(parent,"borderLeftWidth",!0),10)||0)-$(parent).scrollLeft(),offp.top+=(parseInt(jQuery.css(parent,"borderTopWidth",!0),10)||0)-$(parent).scrollTop(),$(top).css({left:off.left-offp.left+"px",top:off.top-offp.top+obj.offsetHeight+"px",width:w+"px"}),frame&&$(frame).css({width:w+"px"}),top.style.display="block",visible=!0,blockMouseOver=!0}},numItems:function(){return this.parts.content?this.parts.content.rows.length:0},onblur:function(e){with(this)visible&&(hlIndex>=0&&(props.preserveonout?setValue(_getvalue_sep(),dataid):(_setvalue_sep(userInput),dataid=props.emptyDataId)),hide())},onfocus:function(e){with(this)props.showalways&&procRequest(_getvalue_sep(),!0)},select:function(){with(this)props.onselect&&props.onselect.call(props.app,obj.value,dataid,this)},onkeydown:function(e){with(this){var c=e.keyCode;if(27==c&&visible)return""!=resultInput&&(_setvalue_sep(userInput),dataid=props.emptyDataId),hide(),!1;if(""==resultInput&&!props.showalways)return;if(13==c&&hlIndex>=0&&visible)return dataobj&&(dataobj.value=dataid),userInput=_getvalue_sep(),previousInput=obj.value,resetRequest(userInput),hide(),userInput!=resultInput&&clearResult(),obj.focus(),props.onchange&&props.onchange.call(props.app,obj.value,dataid,this),props.onselect&&props.onselect.call(props.app,obj.value,dataid,this),e.preventDefault(),e.stopPropagation(),!1;if(isDownKey(c))return moveSelection(hlIndex+1),!1;if(isUpKey(c))return moveSelection(hlIndex-1),!1}},onkeyup:function(e){with(this){if(""!=ignoreInput&&_getvalue_sep()==ignoreInput)return;if(obj.value==previousInput)return;
1ignoreInput=resultInput="",previousInput=obj.value,userInput=_getvalue_sep(),dataid=props.emptyDataId,dataobj&&(dataobj.value=dataid),hideTimer&&clearTimeout(hideTimer),hideTimer=setTimeout("var _usl=_uSuggestList.all["+idx+"]; if (_usl){var _fl=0; if (_usl.visible)_fl=1; _usl.clearResult(1); if (_usl.props.showalways && _fl)_usl._appendCurrent();}",200),procRequest(userInput),props.onchange&&props.onchange.call(props.app,obj.value,props.emptyDataId,this)}},setValue:function(v,id){with(this)void 0!==id&&null!=id||(id=props.emptyDataId),userInput=previousInput=obj.value=v,ignoreInput=resultInput="",dataid=id,dataobj&&(dataobj.value=id),hideTimer&&clearTimeout(hideTimer),hideTimer=null,clearResult(),props.onchange&&props.onchange.call(props.app,obj.value,id,this)},_setvalue_sep:function(v){with(this)sep_pos>=0?obj.value=obj.value.substr(0,sep_pos)+props.separator+" "+v:obj.value=v},_getvalue_sep:function(){with(this){if(props.separator&&(sep_pos=obj.value.lastIndexOf(props.separator)),sep_pos>=0){var t=obj.value.substr(sep_pos+props.separator.length);return t=t.replace(/^\s+/,""),t}return obj.value}},moveSelection:function(newi){with(this){if(""==resultInput&&""!=ignoreInput&&_getvalue_sep()==ignoreInput)return void procRequest(ignoreInput,!0);if(!visible&&resultInput.length>0&&resultInput==_getvalue_sep())return void show();if(!visible)return;hlRow&&design._deselect(this,hlRow),hlRow=null;var cnt=numItems();if(props.showalways){if(!cnt||0==userInput.length)return;newi>=cnt?newi=0:newi<0&&(newi=cnt-1)}else if(newi>=cnt?newi=-1:newi<-1&&(newi=cnt-1),-1==newi)return hlIndex=-1,_setvalue_sep(userInput),void obj.focus();hlIndex=newi,hlRow=parts.content.rows[newi],design._select(this,hlRow),ignoreInput=$(hlRow).attr("usuggeststr"),props.haveDataId&&(dataid=$(hlRow).attr("usuggestid")),_setvalue_sep(ignoreInput)}},isUpKey:function(t){return 38==t||63232==t},isDownKey:function(t){return 40==t||63233==t},resetRequest:function(txt){with(this){if(remoteReqTimer&&requestedInput==txt)return;clearTimeout(remoteReqTimer),remoteReqTimer=null,clearTimeout(AJAXTimer),AJAXTimer=null;try{AJAXObj&&AJAXObj.abort(),AJAXObj=null}catch(e){}}},_appendCurrent:function(){with(this)saIndex=parts.content.rows.length,hlRow&&design._deselect(this,hlRow),hlRow=null,0==userInput.length?(props.emptyprompt&&props.emptyprompt.length>0?design.append_row(this,props.haveDataId?[props.emptyDataId,props.emptyprompt]:[props.emptyprompt],1,"",1):saIndex=-1,hlIndex=-1):(design.append_row(this,props.haveDataId?[props.emptyDataId,userInput]:[userInput],1,userInput),hlIndex=saIndex,hlRow=parts.content.rows[saIndex],design._select(this,hlRow)),show()},procRequest:function(txt,nopause){with(this){if(resetRequest(txt),txt.length<props.minlen&&(props.showalways?(clearResult(),hideTimer&&clearTimeout(hideTimer),hideTimer=null):clearResult(!0),!props.showalways||txt.length))return;if(queryCache[cacheGroup][txt])return void setResult(txt,queryCache[cacheGroup][txt]);if(props.showalways&&(saIndex>=0?(hlRow!=parts.content.rows[saIndex]&&(hlRow&&design._deselect(this,hlRow),hlIndex=saIndex,hlRow=parts.content.rows[saIndex],design._select(this,hlRow)),design.update_row(this,hlRow,props.haveDataId?[props.emptyDataId,userInput]:[userInput],1,userInput),show()):_appendCurrent()),AJAXretries=0,!props.url)return;requestedInput=txt,nopause?remoteRequest():remoteReqTimer=setTimeout("var _usl=_uSuggestList.all["+this.idx+"]; if (_usl)_usl.remoteRequest();",200)}},remoteRequest:function(){with(this){clearTimeout(remoteReqTimer),remoteReqTimer=null;try{AJAXObj&&AJAXObj.abort(),AJAXObj=null}catch(e){}if(AJAXretries>1)return;clearTimeout(AJAXTimer),AJAXTimer=setTimeout("var _usl=_uSuggestList.all["+this.idx+"]; if (_usl){_usl.AJAXretries++; _usl.remoteRequest();}",12e3),AJAXObj=$.ajax({type:"GET",dataType:props.dataType,cache:!1,url:props.url,data:{tag:requestedInput},success:new Function("resp","status","var _usl=_uSuggestList.all["+this.idx+"]; if (_usl)_usl.parseRequest(resp,status);"),timeout:1e4})}},parseRequest:function(resp,status){clearTimeout(this.AJAXTimer),this.AJAXTimer=null,this.AJAXretries=0;var res=[];if("text"==this.props.dataType)try{res=eval("res="+resp)}catch(t){}else res=resp;if(this.AJAXObj=null,!res||res.length<2||res[1]<1||res[1]>10)this.clearResult();else{var n=res[1],idx=0,data=[];this.props.haveDataId&&n++;for(var i=2;i<res.length;i+=n,idx++){data[idx]=[];for(var j=0;j<n;j++)data[idx][j]=res[i+j]}this.queryCache[this.cacheGroup][res[0]]=data,res[0]==this._getvalue_sep()&&this.setResult(res[0],this.queryCache[this.cacheGroup][res[0]])}},_ignoreevent:function(t){t.preventDefault(),t.stopPropagation()},_onrowmousemove:function(t){return t.data.onrowmousemove(t)},_onrowmouseover:function(t){return t.data.onrowmouseover(t)},_onrowmousedown:function(t){return t.preventDefault(),t.stopPropagation(),t.data.onrowmousedown(t)},onrowmousemove:function(t){this.blockMouseOver&&(this.blockMouseOver=!1,this.onrowmouseover(t))},onrowmouseover:function(e){with(this){if(blockMouseOver)return;hlRow&&design._deselect(this,hlRow),hlRow=null,hlIndex=-1;for(var i=0;i<parts.content.rows.length;i++)if(parts.content.rows[i]==e.target||jQuery.inArray(e.target,$(parts.content.rows[i]).find("*"))>=0){hlIndex=i,hlRow=parts.content.rows[i],design._select(this,hlRow);break}}},onrowmousedown:function(e){with(this){if(numItems()<=0||!hlIndex<0||!hlRow)return;ignoreInput=userInput=$(hlRow).attr("usuggeststr"),props.haveDataId&&(dataid=$(hlRow).attr("usuggestid"),dataobj&&(dataobj.value=dataid)),_setvalue_sep(userInput),previousInput=obj.value,resetRequest
1(userInput),hide(),userInput!=resultInput&&clearResult(),obj.focus(),props.onchange&&props.onchange.call(props.app,obj.value,dataid,this),props.onselect&&props.onselect.call(props.app,obj.value,dataid,this)}},setResult:function(phrase,table){with(this){hideTimer&&clearTimeout(hideTimer),hideTimer=null,clearResult(),hlIndex=-1,hlRow=null,resultInput=phrase;var cnt=table.length,cols,havecurrent=-1;if(props.showalways)cnt>0&&(cols=table[0].length);else{if(cnt<=0)return void hide();cols=table[0].length}props.haveDataId&&cols--;for(var i=0;i<cnt;i++)design.append_row(this,table[i],cols,phrase),props.compareFunc?"nocase"===props.compareFunc?_uSuggestList.casecompare(table[i][props.haveDataId?1:0],userInput)||(havecurrent=i):props.compareFunc(table[i][props.haveDataId?1:0],userInput)||(havecurrent=i):table[i][props.haveDataId?1:0]==userInput&&(havecurrent=i);props.showalways&&havecurrent<0?_appendCurrent():(saIndex=-1,hlIndex=havecurrent,hlRow&&design._deselect(this,hlRow),hlRow=havecurrent<0?null:parts.content.rows[hlIndex],design._select(this,hlRow),show())}},clearResult:function(hide){with(this)for(hide&&hide(),resultInput="",hlRow=null,saIndex=hlIndex=-1;parts.content.rows.length>0;)parts.content.deleteRow(0)}},_uDraggable.dummy=function(){},_uDraggable.obj=null,_uDraggable.clkX=0,_uDraggable.clkY=0,_uDraggable.scrL=0,_uDraggable.scrT=0,_uDraggable.globalset=!1,_uDraggable.onmousemove=function(e){with(_uDraggable){var o=obj;if(!o)return;if(o.event=e,void 0!==e.which&&1!=e.which)return o.stop(),void(obj=null);e.stopPropagation(),e.preventDefault();var d=_uWnd.getdims();return o.moved||e.clientX==clkX&&e.clientY==clkY||(o.onstartdrag.apply(o.par,[o.x,o.y,o.w,o.h,o.m]),o.moved=!0),o.onmove.apply(o.par,[e.clientX-clkX-(scrL-d.clientLeft),e.clientY-clkY-(scrT-d.clientTop),o.x,o.y,o.w,o.h,o.m]),o.event=null,!1}},_uDraggable.onmouseup=function(e){if(1==e.which)with(_uDraggable){var o=obj;if(!o)return;o.moved&&onmousemove(e),o.event=e,o.stop(),o.event=null,obj=null}},_uDraggable.prototype={start:function(t,e,s,i,o,a){var n=_uDraggable;
1n.obj&&(n.obj.event=t,n.obj.onstopdrag.apply(n.obj.par),n.obj.event=null),this.x=e,this.y=s,this.w=i,this.h=o,this.m=a,this.active=!0,this.moved=!1,n.obj=this;var r=_uWnd.getdims();n.clkX=t.clientX,n.clkY=t.clientY,n.scrL=r.clientLeft,n.scrT=r.clientTop,this.event=t,this.oninitdrag.apply(this.par,[e,s,i,o,a])},stop:function(){var t=_uDraggable;t.obj==this&&(t.obj=null),this.active&&(this.onstopdrag.apply(this.par,[this.x,this.y,this.w,this.h,this.m]),this.active=!1)}},_uSlider._onmousedownparent=function(t){var e=t.data;if(!e.disabled){var s="h"==e.type?t.pageX:t.pageY,i=$(this).offset(),o="h"==e.type?s-i.left:s-i.top;e.setPos(o-e.hotoff),t.preventDefault()}},_uSlider._onmousedown=function(t){var e=t.data;e.disabled||e.drag.start(t,e.pos)},_uSlider._onmousemove=function(t){t.preventDefault()},_uSlider.prototype={setPos:function(t){t<this.min_pos?t=this.min_pos:t>this.max_pos&&(t=this.max_pos);var e=this.min_value<this.max_value?1:-1,s=(t-this.min_pos)/(this.max_pos-this.min_pos)*(this.max_value-this.min_value)+this.min_value;this.step>0&&(t=((s=Math.round((s-this.min_value)/this.step)*this.step+this.min_value)-this.min_value)/(this.max_value-this.min_value)*(this.max_pos-this.min_pos)+this.min_pos,t=Math.round(t)),s*e<this.min_value*e?s=this.min_value:s*e>this.max_value*e&&(s=this.max_value),s!=this.value&&(this.pos=t,"h"==this.type?this.slider.style.left=this.pos+"px":this.slider.style.top=this.pos+"px",this.value=s,this.props.onchange&&this.props.onchange.call(this.props.thispar,this.value,this.props.param,this))},_ondrag:function(t,e,s){this.disabled||this.setPos(s+t)},setValue:function(t){var e=this.min_value<this.max_value?1:-1;if(!(t*e<this.min_value*e||t*e>this.max_value*e)){this.step>0&&((t=Math.round((t-this.min_value)/this.step)*this.step+this.min_value)*e<this.min_value*e?t=this.min_value:t*e>this.max_value*e&&(t=this.max_value));var s=(t-this.min_value)/(this.max_value-this.min_value)*(this.max_pos-this.min_pos)+this.min_pos;this.pos=Math.round(s),"h"==this.type?this.slider.style.left=this.pos+"px":this.slider.style.top=this.pos+"px",this.value=t,!this.disabled&&this.props.onchange&&this.props.onchange.call(this.props.thispar,this.value,this.props.param,this)}}},_uSlider.buildH=function(t,e){var s=$.extend({w:124,lw:0,limg:"",limgcss:"",rw:0,rimg:null,rimgcss:"",title:"",ch:20,cw:120,cimg:"/img/d/sldBg.gif",cimgcss:"no-repeat 0 10px",simg:"/img/d/sld.gif",simgcss:"no-repeat 0 0",sh:20,sw:9,st:2},e||{});return String(s.w).indexOf("%")<0&&String(s.w).toLowerCase().indexOf("px")<0&&(s.w+="px"),'<table border="0" cellpadding="1" cellspacing="1" style="width:'+s.w+'">\t<tr>'+(s.lw>0?'<td width="'+s.lw+'" '+(s.limg||s.limgcss?'style="background:'+(s.limg?"url("+s.limg+") ":"")+s.limgcss+'"':"")+"></td>":"")+"<td><div"+(s.title?' title="'+s.title+'"':"")+' style="height:'+s.ch+"px;width:"+s.cw+"px"+(s.cimg||s.cimgcss?";background:"+(s.cimg?"url("+s.cimg+") ":"")+s.cimgcss:"")+'"><div unselectable="on" id="'+t+'" style="cursor:pointer;-moz-user-select:none;height:'+s.sh+"px; width:"+s.sw+"px; position:relative; top:"+s.st+"px"+(s.simg||s.simgcss?";background:"+(s.simg?"url("+s.simg+") ":"")+s.simgcss:"")+'"></div></div></td>'+(s.rw>0?'<td width="'+s.rw+'" '+(s.rimg||s.rimgcss?'style="background:'+(s.rimg?"url("+s.rimg+") ":"")+s.rimgcss+'"':"")+"></td>":"")+"</tr>\t</table>"},_uTabCtrl.all=[],_uTabCtrl.nextidx=1,_uTabCtrl.globalset=!1,_uTabCtrl.getbyname=function(t){var e=this.all,s=parseInt(t);if(!isNaN(s)&&String(s)==String(t))return e[s]||null;for(var i=0;i<e.length;i++)if(e[i]&&e[i].name==t)return e[i];return null},_uTabCtrl.findparentcontent=function(t){return $(t).parents(".u-tabc-content,.u-tabc-header,.u-tabc-footer")[0]},_uTabCtrl.closeTab=function(t,e){var s=this.getbyname(t);s&&s.closeTab(e)},_uTabCtrl.content=function(t,e,s){var i=this.getbyname(t);i&&i.content(e,s)},_uTabCtrl.headerheight=function(t,e,s){var i=this.getbyname(t);i&&i.headerheight(e,s)},_uTabCtrl.footerheight=function(t,e,s){var i=this.getbyname(t);i&&i.footerheight(e,s)},_uTabCtrl.setTitle=function(t,e,s){var i=this.getbyname(t);i&&i.setTitle(e,s)},_uTabCtrl.designs={std:{content_class:"u-tabc-content",header_class:"u-tabc-header",footer_class:"u-tabc-footer",tabctrl_init:function(t){var e={};return $(t.top).attr("class","x-unselectable u-tabc").html((t.props.notabs?"":'<div class="u-tabc-p"><div class="u-tabc-listp"><div class="u-tabc-list"></div><div class="u-tabc-pbot"></div></div><div class="u-tabc-scrbut"><div class="u-tabc-tabl"><div class="u-tabc-label"><div class="u-tabc-scrl"></div><div class="u-tabc-scrr"></div></div></div></div></div>')+'<div class="u-tabc-body"><div class="u-tabc-content" style="height:'+t.props.min_height+'px">'+t.props.emptycontent+"</div></div>"),t.props.notabs||(e.pane=$(t.top).find(".u-tabc-p")[0],e.panebot=$(t.top).find(".u-tabc-pbot")[0],e.listp=$(t.top).find(".u-tabc-listp")[0],e.list=$(t.top).find(".u-tabc-list")[0],e.scrbut=$(t.top).find(".u-tabc-scrbut")[0],e.scrl=$(t.top).find(".u-tabc-scrl")[0],e.scrr=$(t.top).find(".u-tabc-scrr")[0],$(e.scrl).on("click mousedown mouseover mouseout",{obj:t,but:0},_uTabCtrl._onscrbutevent),$(e.scrr).on("click mousedown mouseover mouseout",{obj:t,but:1},_uTabCtrl._onscrbutevent)),e.body=$(t.top).find(".u-tabc-body")[0],e.emptycontent=e.content=$(t.top).find(".u-tabc-content")[0],$(t.top).find("div,span")[$.fn.andSelf?"andSelf":"addBack"]().attr("unselectable","on"),e},remove_item:function(t,e){t.props.notabs||t.parts.list.removeChild(t.data[e].obj)},set_title:function(t,e){t.props.notabs||$(t.data[e].label).html((t.data[e].icon?'<img class="u-tabc-icon" border="0" src="'+t.data[e].icon+'">':"")+t.data[e].title)},insert_item:function(t,e){if(!t.props.notabs){var s,i=document.createElement("div");s=t.data[e].icon?'<img class="u-tabc-icon" border="0" src="'+t.data[e].icon+'">':t.data[e].iconstyle?'<div class="u-tabc-icon" style="background:'+t.data[e].iconstyle+'"></div>':"",$(i).attr("class","u-tabc-tab"+(t.data[e].close?" u-tabc-wcl":"")).html((t.data[e].href?"<a "+(t.data[e].target?'target="'+t.data[e].target+'" ':"")+'href="'+t.data[e].href+'" class="u-tabc-tabl" style="display:block">':'<div class="u-tabc-tabl">')+(t.data[e].close?'<div class="u-tabc-closebut"></div>':"")+'<div class="u-tabc-tabr"><div class="u-tabc-label">'+s+t.data[e].title+"</div></div>"+(t.data[e].href?"</a>":"</div>")),t.data[e].obj=i,t.data[e].label=$(i).find(".u-tabc-label")[0],t.data[e].link=$(i).find(".u-tabc-tabl")[0],t.data[e].close&&(t.data[e].clbut=$(i).find(".u-tabc-closebut")[0],$(t.data[e].clbut).on("mouseover",this._onclbutmouseover).on("mouseout",this._onclbutmouseout).on("click",{obj:t,tab:t.data[e]},_uTabCtrl._onclbutclick).on("mousedown",{obj:t,tab:t.data[e]},_uTabCtrl._onclbutdown)),$(t.data[e].link).on("mouseover",this._ontabmouseover).on("mouseout",this._ontabmouseout).on("mousedown",{obj:t,tab:t.data[e]},_uTabCtrl._ontabclick),$(i).find("div,span,a,img")[$.fn.andSelf?"andSelf":"addBack"]().attr("unselectable","on"),t.data[e].ishidden&&(i.style.display="none");var o=t.parts.list.childNodes.length;t.parts.list.insertBefore(i,e>=o?null:t.parts.list.childNodes[e])}},_ontabmouseover:function(t){$(this.parentNode).addClass("u-tabc-tab-over")},_ontabmouseout:function(t){$(this.parentNode).removeClass("u-tabc-tab-over")},_onclbutmouseover:function(t){$(this).addClass("u-tabc-closebut-over")},_onclbutmouseout:function(t){$(this).removeClass("u-tabc-closebut-over")},_onclbutmousedown:function(t,e){e?$(t).addClass("u-tabc-closebut-down"):$(t).removeClass("u-tabc-closebut-down")},_ontabactivate:function(t,e){t.props.notabs||$(t.data[e].obj).addClass("u-tabc-tab-act")},_ontabdeactivate:function(t,e){t.props.notabs||$(t.data[e].obj).removeClass("u-tabc-tab-act")},_onscrbutactivate:function(t,e,s){s?$(e?t.parts.scrr:t.parts.scrl).removeClass("u-tabc-scr-dis"):$(e?t.parts.scrr:t.parts.scrl).addClass("u-tabc-scr-dis")},_onscrbutover:function(t,e,s){var i=e?t.parts.scrr:t.parts.scrl;s?$(i).addClass("u-tabc-scr-over"):$(i).removeClass("u-tabc-scr-over")},_onscrbutdown:function(t,e,s){var i=e?t.parts.scrr:t.parts.scrl;s?$(i).addClass("u-tabc-scr-down"):$(i).removeClass("u-tabc-scr-down")},_onbuttonup:function(t,e,s){e<2?this._onscrbutdown(t,e,0):this._onclbutmousedown(s.clbut,0)}}},_uTabCtrl._onclbutdown=function(t){1==t.which&&(t.stopPropagation(),t.data.obj.design._onclbutmousedown(t.data.tab.clbut,1),t.data.obj.butdown.start(t,2,t.data.tab)),_uWnd.globalmousedown()},_uTabCtrl._onscrbutevent=function(t){var e=t.data.obj,s=t.data.but;"click"==t.type&&1==t.which?e.scrollTabPane(s?40:-40):"mouseover"==t.type?e.design._onscrbutover(e,s,1):"mouseout"==t.type?e.design._onscrbutover(e,s,0):"mousedown"==t.type&&1==t.which&&(e.design._onscrbutdown(e,s,1),e.butdown.start(t,s))},_uTabCtrl._onclbutclick=function(t){for(var e=t.data,s=e.obj,i=0;i<s.data.length;i++)if(s.data[i]==e.tab){if("function"==typeof s.data[i].onbeforeclose&&!s.data[i].onbeforeclose.call(s.app,s,i,s.data[i].id))break;s.closeTab(i);break}t.preventDefault(),t.stopPropagation()},_uTabCtrl._ontabclick=function(t){var e=t.data.obj;t.preventDefault();for(var s=0;s<e.data.length;s++)if(e.data[s]==t.data.tab){if(s==e.active_tab)return;if("function"==typeof e.data[s].onbeforechange&&!e.data[s].onbeforechange.call(e.app,e,s,e.data[s].id))break;e.activateTab(s);break}},_uTabCtrl.prototype={saveSession:function(){return this.sesupdate=0,{tab:this.active_tab}},init:function(t){var e=document.createElement("div");if(e.id="_utabctrl"+this.idx,this.props.parentnode)this.props.parentnode.appendChild(e);else if(this.props.wnd){for(var s=this.props.wnd.parts.wndcont;s.firstChild;)s.removeChild(s.firstChild);s.appendChild(e),this.wnd=this.props.wnd,this.wnd.tabctrl=this,this.wnd.state.loaded=!0}else $($("body")[0]).append(e);this.top=e,$(e).css({visibility:"hidden",display:"block"}),this.width>
10&&$(e).css("width",this.width+"px"),this.parts=this.design.tabctrl_init(this),this.parts.markloadcont=null,this.parts.headercontent=null,this.parts.footercontent=null,this.show(),t||setTimeout("var _utc=_uTabCtrl.all["+this.idx+"]; if (_utc)_utc.init1();",10)},init1:function(t){var e=this.parts,s=this.decor;if(this.width>0||(this.width=this.top.offsetWidth),this.height>0||(this.height=this.top.offsetHeight),s.cdw=this.top.offsetWidth-e.content.offsetWidth,s.cdh=this.top.offsetHeight-e.content.offsetHeight,this.props.notabs?s.pdw=0:s.pdw=this.top.offsetWidth-e.listp.offsetWidth,s.hh=0,s.fh=0,this.props.wnd||t||($(this.top).css("height",this.height+"px"),$(e.content).css({width:this.top.offsetWidth-s.cdw+"px",height:this.top.offsetHeight-s.cdh+"px"}),this.props.notabs||$(e.listp).css({width:this.top.offsetWidth-s.pdw+"px"})),!this.props.notabs){$(e.listp).css({overflow:"hidden"}),$(e.panebot).css("width","4000px"),$(e.list).css("width","4000px");for(var i=0;i<this.ntabs;i++)this.design.insert_item(this,i)}this.props.wnd&&this.resizeTo(this.props.wnd.width-this.props.wnd.decor.w,this.props.wnd.height-this.props.wnd.decor.h),this.state.init=!0;var o=this.active_tab;if(this.active_tab=-1,"auto"==o)if(this.name&&this.name.length>0&&self.location.hash.length>1){for(var a=self.location.hash.substr(1).split(";"),n="T_"+this.name+"=",r=0;r<a.length;r++)if(a[r].length>n.length&&a[r].substr(0,n.length)==n){var l=this.idxbyid(a[r].substr(n.length));if(l>=0&&l<this.data.length){o=l;break}}}else o=-1;if($(this.top).css("display","block").css("visibility",""),-1==o&&this.data.length>0&&(o=0),o>=0&&o<this.ntabs)for(i=0;i<this.ntabs;i++){var h=(o+i)%this.ntabs;if(!this.data[h].ishidden&&(!this.data[h].onbeforechange||this.data[h].onbeforechange(this,h,this.data[h].id))){this.activateTab(h,!0);break}}else this.activateTab(-1,!0);$(this.top).css("display","none").css("visibility",""),this.pend_show&&this.show(this.pend_show[0]),this.props.wnd&&this.props.wnd.onexternalload()},scrollTabPane:function(t){if(!this.props.notabs){var e=this.scrollpos.pos+=t,s=this.scrollpos.tabswidth,i=this.scrollpos.havewidth;if(s<i)this.design._onscrbutactivate(this,0,0),this.design._onscrbutactivate(this,1,0),e=(this.props.rtl||window._rtl)&&this.data.length>0?this.data[this.data.length-1].obj.offsetLeft+i-s:0,this.scrollpos.pos=e,this.parts.listp.scrollLeft=e;else{if(this.props.rtl||window._rtl){var o=this.data[this.data.length-1].obj.offsetLeft;e<o?e=o:e>o+s-i&&(e=o+s-i)}else e<0?e=0:e>s-i&&(e=s-i);this.scrollpos.pos=e,this.parts.listp.scrollLeft=e,e>0?this.design._onscrbutactivate(this,0,1):this.design._onscrbutactivate(this,0,0),e<s-i?this.design._onscrbutactivate(this,1,1):this.design._onscrbutactivate(this,1,0)}}},_setscrolls:function(t){if(this.state.init&&!this.props.notabs){var e=0,s=this.parts.listp.offsetWidth;if(this.parts.listp.clientWidth>0&&this.parts.listp.clientWidth<s&&(s=this.parts.listp.clientWidth),this.data.length>0){var i=this.data[this.data.length-1].obj;if(this.props.rtl||window._rtl){var o=this.data[0].obj;e=o.offsetLeft+o.offsetWidth-i.offsetLeft}else e=i.offsetLeft+i.offsetWidth}s<e?(this.parts.scrbut.style.display="block",s-=this.parts.scrbut.offsetWidth):this.parts.scrbut.style.display="none",null==this.scrollpos.pos?(this.props.rtl||window._rtl)&&this.data.length>0?this.scrollpos.pos=this.data[this.data.length-1].obj.offsetLeft+e-s:this.scrollpos.pos=0:this.scrollpos.havewidth!=s&&(this.props.rtl||window._rtl)&&(this.scrollpos.pos+=this.scrollpos.havewidth-s),this.scrollpos.havewidth=s,this.scrollpos.tabswidth=e,s<e&&t&&this.active_tab>=0&&this.active_tab<this.data.length&&(this.props.rtl||window._rtl||((i=this.data[this.active_tab].obj).offsetLeft<this.scrollpos.pos?this.scrollTabPane(i.offsetLeft-this.scrollpos.pos):i.offsetLeft+i.offsetWidth>this.scrollpos.pos+s&&this.scrollTabPane(i.offsetLeft+i.offsetWidth-(this.scrollpos.pos+s)))),this.scrollTabPane(0)}},show:function(t){this.state.init?($(this.top).show(),this.state.visible=!0):this.pend_show=[t]},resizeTo:function(w,h){var d=this.decor;with(this)width=w,height=h,$(top).width(w).height(h),$(parts.content).css({width:w-d.cdw+"px",height:h-d.cdh-d.fh-d.hh+"px"}),parts.headercontent&&$(parts.headercontent).css({width:w-d.cdw+"px",height:d.hh+"px"}),parts.footercontent&&$(parts.footercontent).css({width:w-d.cdw+"px",height:d.fh+"px"}),props.notabs||$(parts.listp).css({width:w-d.pdw+"px"}),props.onresize&&props.onresize.call(app,w-d.cdw,h-d.cdh,this,name),_setscrolls()},addTab:function(t,e,s,i){var o=null!=i&&i>=0&&i<this.data.length?i:this.data.length,a=s||{},n=a.id||"";n&&0!=n.length||(n="_tc"+this.idx+"tb"+this.maxid++);var r={id:n,title:t||".",dat:e||"",footer:a.footerc||null,footerh:a.footerh&&a.footerh>0?a.footerh:0,header:a.headerc||null,headerh:a.headerh&&a.headerh>0?a.headerh:0,footercont:null,headercont:null,cont:null,ismarkload:0,iserrorload:0,markloadcont:null,obj:null,ishidden:a.hidden,clbut:null,link:null,href:a.href,target:a.target,label:null,align:null==a.align?this.props.align:a.align,close:null==a.close?this.props.close:a.close,icon:a.icon,iconstyle:a.iconstyle,markload:a.markload,firstload:0,firstshow:0,xmlobj:null,xmlobj_ignoreabort:0,onload:null==a.onload?this.props.onload:a.onload,onerror:null==a.onerror?this.props.onerror:a.onerror,onshow:null==a.onshow?this.props.onshow:a.onshow,onhide:null==a.onhide?this.props.onhide:a.onhide,onbeforechange:null==a.onbeforechange?this.props.onbeforechange:a.onbeforechange,onchange:null==a.onchange?this.props.onchange:a.onchange,onbeforeclose:null==a.onbeforeclose?this.props.onbeforeclose:a.onbeforeclose,onclose:null==a.onclose?this.props.onclose:a.onclose};return o<this.data.length?this.data.splice(o,0,r):this.data[o]=r,this.design.insert_item(this,o),this._setscrolls(),o},tabHidden:function(t,e){if(!this.props.notabs&&!((t=this.idxbyid(t))<0||t>=this.data.length)){var s=this.data[t];s.obj.style.display=e?"none":"",s.ishidden=!!e,this._setscrolls()}},activateTab:function(t,e){if(t=this.idxbyid(t),!this.state.init)return this.active_tab=t,1;if(t<0||t>=this.data.length||this.active_tab==t){if(!(e&&this.data.length>0))return 0;t=0}return this.design._ontabactivate(this,t),this.active_tab>=0&&this.active_tab<this.data.length&&("function"==typeof this.data[this.active_tab].onhide&&this.data[this.active_tab].onhide.call(this.app,this,this.active_tab,this.data[this.active_tab].id),document.activeElement&&document.activeElement!=document.body&&document.activeElement.blur&&$(document.activeElement,this.data[this.active_tab].cont)[0]&&document.activeElement.blur(),this.design._ontabdeactivate(this,this.active_tab)),this.active_tab=t,this._setscrolls(1),e||(this.sesupdate=1),this.data[t].firstshow=1,"function"!=typeof this.data[t].onchange||this.data[t].onchange.call(this.app,this,t,this.data[t].id)?(this.load(t),1):1},closeTab:function(t){if(this.state.init&&!((t=this.idxbyid(t))<0||t>=this.data.length)){this.data[t].xmlobj&&(this.data[t].xmlobj_ignoreabort=1,this.data[t].xmlobj.abort(),this.data[t].xmlobj=null),t==this.active_tab&&"function"==typeof this.data[t].onhide&&this.data[t].onhide.call(this.app,this,t,this.data[t].id),this.design.remove_item(this,t);var e=this.data[t].id,s=this.data[t].onclose;this.data.splice(t,1),t==this.active_tab?(this.active_tab=-1,t==this.data.length?0==t?this._assign_content(-1):this.activateTab(t-1):this.activateTab(t)):t<this.active_tab&&this.active_tab--,this._setscrolls(),s&&s(this,t,e)}},setTitle:function(t,e){(t=this.idxbyid(t))<0||t>=this.data.length||(this.data[t].title=e,this.design.set_title(this,t),this._setscrolls())},headerheight:function(t,e){(t=this.idxbyid(t))<0||t>=this.data.length||"number"!=typeof e||isNaN(e)||(this.data[t].headerh=e)},footerheight:function(t,e){(t=this.idxbyid(t))<0||t>=this.data.length||"number"!=typeof e||isNaN(e)||(this.data[t].footerh=e)},content:function(t,e,s,i,o){(t=this.idxbyid(t))<0||t>=this.data.length||(this.data[t].xmlobj&&(this.data[t].xmlobj_ignoreabort=1,this.data[t].xmlobj.abort(),this.data[t].xmlobj=null),void 0!==s&&null!=s||(s=this.data[t].headercont?null:this.data[t].header?this.data[t].header:""),void 0!==i&&null!=i||(i=this.data[t].footercont?null:this.data[t].footer?this.data[t].footer:""),void 0!==e&&null!=e||(e=this.data[t].cont?null:""),this.data[t].cont||(this.data[t].cont=document.createElement("DIV"),$(this.data[t].cont).addClass(this.design.content_class).css("text-align",this.data[t].align)),null!=e&&($(this.data[t].cont).html(e),this.data[t].firstload=o?0:1,this.data[t].ismarkload=0,this.data[t].iserrorload=o?1:0),s||null==s?(this.data[t].headercont||(this.data[t].headercont=document.createElement("DIV"),$(this.data[t].headercont).attr("class",this.design.content_class+" "+this.design.header_class).css("overflow","hidden").css("text-align",this.data[t].align)),s&&$(this.data[t].headercont).html(s)):this.data[t].headercont&&$(this.data[t].headercont).html(""),i||null==i?(this.data[t].footercont||(this.data[t].footercont=document.createElement("DIV"),$(this.data[t].footercont).attr("class",this.design.content_class+" "+this.design.footer_class).css("overflow","hidden").css("text-align",this.data[t].align)),i&&$(this.data[t].footercont).html(i)):this.data[t].footercont&&$(this.data[t].footercont).html(""),t==this.active_tab&&this._assign_content(t))},_assign_content:function(t){var e,s=0,i=0;for(t<0?(this.parts.content=this.parts.emptycontent,this.parts.headercontent=this.parts.footercontent=null):this.data[t].ismarkload?(this.parts.content=this.data[t].markloadcont,this.parts.headercontent=this.parts.footercontent=null):(this.parts.content=this.data[t].cont,this.parts.headercontent=this.data[t].headercont,i=this.data[t].headerh,this.parts.footercontent=this.data[t].footercont,s=this.data[t].footerh),e=0,this.parts.headercontent?($(this.parts.headercontent).css({width:this.width-this.decor.cdw+"px",height:i+"px"}),this.parts.body.childNodes[e]?this.parts.body.replaceChild(this.parts.headercontent,this.parts.body.childNodes[e]):this.parts.body.appendChild(this.parts.headercontent),this.decor.hh=i,e++):this.decor.hh=0,$(this.parts.content).css({width:this.width-this.decor.cdw+"px",height:this.height-this.decor.cdh-s-i+"px"}),this.parts.body.childNodes[e]?this.parts.body.replaceChild(this.parts.content,this.parts.body.childNodes[e]):this.parts.body.appendChild(this.parts.content),e++,this.parts.footercontent?($(this.parts.footercontent).css({width:this.width-this.decor.cdw+"px",height:s+"px"}),this.parts.body.childNodes[e]?this.parts.body.replaceChild(this.parts.footercontent,this.parts.body.childNodes[e]):this.parts.body.appendChild(this.parts.footercontent),this.decor.fh=s,e++):this.decor.fh=0;this.parts.body.childNodes[e];)this.parts.body.removeChild(this.parts.body.childNodes[e]);if(t>=0&&!this.data[t].ismarkload){if("function"==typeof this.data[t].onload&&this.data[t].firstload){var o,a;try{for(o=10,a=arguments.callee.caller;o>=0&&(a&&a.caller!=arguments.callee);o--)a=a.caller}catch(t){}(!a||o<0)&&this.data[t].onload.call(this.app,this,t,this.data[t].id,this.parts.content,this.parts.headercontent,this.parts.footercontent)}"function"==typeof this.data[t].onshow&&(this.data[t].firstshow||this.data[t].firstload)&&this.data[t].onshow.call(this.app,this.data[t].iserrorload,this,t,this.data[t].id,this.parts.content,this.parts.headercontent,this.parts.footercontent),this.data[t].firstshow=0}t>=0&&(this.data[t].firstload=0)},markload:function(t){(t=this.idxbyid(t))<0||t>=this.data.length||(this.data[t].markload?this.data[t].markloadcont||(this.data[t].markloadcont=document.createElement("DIV"),$(this.data[t].markloadcont).addClass("u-tabc-content").html(this.data[t].markload)):(this.parts.markloadcont||(this.parts.markloadcont=document.createElement("DIV"),$(this.parts.markloadcont).addClass("u-tabc-content").html(this.props.markload)),this.data[t].markloadcont=this.parts.markloadcont),this.data[t].ismarkload=1,this.data[t].iserrorload=0,t==this.active_tab&&this._assign_content(t))},idxbyid:function(t){if(this.state.destroyed)return-1;if("string"==typeof t){for(var e=0;e<this.data.length;e++)if(this.data[e].id==t)return e;return-1}return t},findintab:function(t,e){if((t=this.idxbyid(t))<0||t>=this.data.length)return $([]);var s=$(this.data[t].iserrorload?[]:this.data[t].cont);return this.data[t].headercont&&(s=s.add(this.data[t].headercont)),this.data[t].footercont&&(s=s.add(this.data[t].footercont)),e?s.find(e):s},load:function(t,e,s){if(!((t=this.idxbyid(t))<0||t>=this.data.length))if(null==this.data[t].cont||e){if((-1!==e||(this.data[t].cont=null,t==this.active_tab))&&(e||!this.data[t].xmlobj)){var i;if(this.data[t].xmlobj&&(this.data[t].xmlobj_ignoreabort=1,this.data[t].xmlobj.abort(),this.data[t].xmlobj=null),e&&!0!==e&&1!==e&&-1!==e?(s||(this.data[t].dat=e),i=e):i=this.data[t].dat,"string"==typeof i)this.content(t,i,this.data[t].header,this.data[t].footer);else if("function"==typeof i)this.content(t,i(),this.data[t].header,this.data[t].footer);else if("object"==typeof i){this.markload(t),this.app&&!("app"in i)&&
1(i.app=this.app.pid),this.wnd&&!("wnd"in i)&&(i.wnd=this.wnd.idx),i.tabctrl=this.idx,i.tabid=this.data[t].id,_uTabCtrl._onAjaxComplete||(_uTabCtrl._onAjaxComplete=function(t,e){var s=_uTabCtrl.all[this.tabctrl];s&&s._oncomplete(t,e,this)}),i.complete!=_uTabCtrl._onAjaxComplete&&(i.prev_complete_utabctrl=i.complete,i.complete=_uTabCtrl._onAjaxComplete),_uTabCtrl._onAjaxBeforeSend||(_uTabCtrl._onAjaxBeforeSend=function(t){var e=_uTabCtrl.all[this.tabctrl];if(e){var s=e.idxbyid(this.tabid);s>=0&&s<e.data.length&&(e.data[s].xmlobj=t,e.data[s].xmlobj_ignoreabort=0),this.prev_beforeSend_utabctrl&&this.prev_beforeSend_utabctrl.call(this,t)}}),i.beforeSend!=_uTabCtrl._onAjaxBeforeSend&&(i.prev_beforeSend_utabctrl=i.beforeSend,i.beforeSend=_uTabCtrl._onAjaxBeforeSend),i.success||!1!==i.xml||(i.dataType="text",_uTabCtrl._onAjaxSuccess||(_uTabCtrl._onAjaxSuccess=function(t,e){var s=_uTabCtrl.all[this.tabctrl];s&&s.content(this.tabid,t)}),i.success=_uTabCtrl._onAjaxSuccess);try{i.form&&(i.form.length>0||i.form.nodeType)?_uPostForm(i.form,i):i.url&&_uAjaxRequest(i.url,i)}catch(e){this.data[t].xmlobj=null,this._onerror(this.data[t].id,null,"",e,i)}}return!0}}else t==this.active_tab&&this._assign_content(t)},_oncomplete:function(t,e,s){var i=this.idxbyid(s.tabid);i<0||i>=this.data.length||(this.data[i].xmlobj=null,s.prev_complete_utabctrl&&s.prev_complete_utabctrl.call(s,t,e))},_onerror:function(t,e,s,i,o){var a=this.idxbyid(t);if(!(a<0||a>=this.data.length)&&("abort"!=s&&"aborted"!=s||this.data[a].xmlobj&&!this.data[a].xmlobj_ignoreabort)){var n=this.data[a].onerror||this.props.onerror;n&&"function"==typeof n?n.apply(this.app,[t,e,s,i,o]):this.content(a,_txt("ErrorLoadTab",this.idx,a),null,null,1)}},destroy:function(){this.state.destroyed||(this.data.splice(0,this.data.length),this.parts=null,this.top.parentNode&&this.top.parentNode.removeChild(this.top),this.top=null,this.wnd&&this.wnd.tabctrl==this&&(this.wnd.tabctrl=null),this.state.destroyed=!0,_uTabCtrl.all[this.idx]=null,this.props.ondestroy&&this.props.ondestroy(this,this.name))}},_uWnd.all={},_uWnd.nextidx=1,_uWnd.zchilds=[],_uWnd.lastz=0,_uWnd.zstep=2,_uWnd.minz=1e4,_uWnd.maxz=2e4,_uWnd.lastmodalz=0,_uWnd.minmodalz=21e3,_uWnd.maxmodalz=25e3,_uWnd.globalset=!1,_uWnd.defdesktop=null,_uWnd.ignoreclick=null,_uWnd.findactive=function(){for(var t=_uFocus.current;t;){if(t.owner&&t.owner.constructor==_uWnd)return t.owner;t=t._parent}return null},_uWnd.globalmousedown_queue=[],_uWnd.globalmousedown=function(t){1&(t=t||0)||_uMENU.hideallmenus(),4&t||_uSuggestList.hideall(),8&t||_uComboBox.hideall(),2&t||_uWnd.closepopup();for(var e=_uWnd.globalmousedown_queue.length-1;e>=0;e--){var s=_uWnd.globalmousedown_queue[e];s.func.call(s.thispar,s.param)}},_uWnd.addglobalmousedownhandler=function(t,e,s){"function"==typeof t&&_uWnd.globalmousedown_queue.push({func:t,thispar:e||null,param:s||null})},_uWnd.removeglobalmousedownhandler=function(t,e,s){if("function"==typeof t){e=e||null,s=s||null;for(var i=_uWnd.globalmousedown_queue.length-1;i>=0;i--){var o=_uWnd.globalmousedown_queue[i];o.func==t&&o.thispar==e&&o.param==s&&_uWnd.globalmousedown_queue.splice(i,1)}}},_uWnd.messageBoxclose=function(t,e){var s=t.props._msgdata;s.retval||(s.retval=s.defc),s.onsel&&s.onsel.call(s.app,s.retval,s.param,t)},_uWnd.messageBox=function(t,e,s,i,o,a,n){var r,l,h,d=$.extend({w:"auto",h:"auto",name:"",modal:1,closeonesc:1,align:"center",min:0,max:0,close:1,fadetype:0,fadeclosetype:0,resize:0,autosize:0},o||{}),u={onsel:i,app:n,param:a};for(d._msgdata=u,d.onclose=_uWnd.messageBoxclose,d.oncontent=_uWnd.messageBoxoncont,l={ok:1,yes:1,no:1,retry:1,cancel:1},u.buts=[],u.def=null,u.defc=null,s&&s.constructor==Array||(s=["ok"]),r=0;r<s.length;r++)"string"==typeof s[r]?u.buts.push({id:s[r],t:l[s[r]]?_txt(s[r]):s[r]}):"object"==typeof s[r]&&s[r].id&&u.buts.push({id:s[r].id,t:s[r].t||(l[s[r].id]?_txt(s[r].id):s[r].id),def:s[r].def});if(0==u.buts.length)return 0;for(h=0,r=0;r<u.buts.length;r++)h+=60,u.buts[r].def&&(1&u.buts[r].def&&(u.def=u.buts[r].id,void 0===u.buts[r].style&&(u.buts[r].style=0)),2&u.buts[r].def&&(u.defc=u.buts[r].id));return u.def||(u.def=u.buts[0].id,void 0===u.buts[0].style&&(u.buts[0].style=0)),u.defc||(u.defc=u.buts[u.buts.length-1].id),u.txt=t,new _uWnd(d.name||"",e,d.w&&"auto"!=d.w?d.w:-(h+50),d.h&&"auto"!=d.h?d.h:-100,d,_uWnd.messageBoxcont,null,n)},_uWnd.messageBoxoncont=function(t,e){var s,i=t.props._msgdata;(s=$(t.parts.wndcont).find("#_uw"+t.idx+"msg"+i.def)[0])&&s.focus()},_uWnd.messageBoxcont=function(t){var e,s,i;for(s=t.props._msgdata,e="",i=0;i<s.buts.length;i++)e+="<td>"+_uButton("","b",{style:void 0===s.buts[i].style?1:s.buts[i].style,text:s.buts[i].t,content:'onclick="var _uw=_uWnd.all['+t.idx+"]; if (_uw){_uw.props._msgdata.retval='"+encodeHtmlVal(s.buts[i].id)+"'; _uw.close()}\"",id:"_uw"+t.idx+"msg"+s.buts[i].id})+"</td>";return'<div class="messagebox-content">'+s.txt+'</div><div class="messagebox-actions"><table align="center" callpadding="0" cellspacing="10" border="0"><tr>'+e+"</tr></table></div>"},_uWnd.alerts=null,_uWnd.alert=function(t,e,s={},i){(s=Object.assign({w:150,h:100,tm:5e3,shadow:0,close:1,align:"center",icon:"",iconstyle:null,name:"",pad:null,topclass:[]},s)).pad&&(isNaN(s.pad)||(s.pad=`${s.pad}px`),t='<div class="'+s.class+'" style="padding:'+s.pad+'">'+t+"</div>");var o,a,n,r,l,h,d=s.noscale||"undefined"==typeof uwnd_scale?s.h:Math.ceil(s.h*uwnd_scale.h),u=s.noscale||"undefined"==typeof uwnd_scale?s.w:Math.ceil(s.w*uwnd_scale.w);
1if((o=_uWnd.defdesktop)?(a=o.width-o.calcexclude(1)-u-5,r=o.height-o.calcexclude(3)-d-5,l=o.alerts,h=o.calcexclude(2)):(a=(o=_uWnd.getdims()).clientW-u-5,r=o.clientH-d-5,l=_uWnd.alerts,h=0,o=null),n=r,l){for(l.y-(d+5)>=0&&(n=l.y-(d+5));l;)l.y>h&&(h=l.y),l=l.prev;h>0&&r-h>=d+5&&(n=r)}var p=new _uWnd(s.name,e,s.w,s.h,{close:s.close,min:0,max:0,icon:s.icon,iconstyle:s.iconstyle,align:s.align,x:a,y:n,alert:1,autosize:0,fixed:1,shadow:s.shadow,resize:0,nomove:1,hidden:0,notaskbar:1,fadetype:2,fadespeed:500,fadeclosetype:2,fadeclosespeed:500,oncontent:s.oncontent,onclose:function(t,e){_uWnd.rmalert(t,e)},noscale:s.noscale,topclass:s.topclass},t,null,i);return o?o.alerts={prev:o.alerts,wnd:p,y:n}:_uWnd.alerts={prev:_uWnd.alerts,wnd:p,y:n},s.tm>0&&setTimeout("var _uw=_uWnd.all["+p.idx+"]; if (_uw)_uw.close();",s.tm),p},_uWnd.rmalert=function(t,e){for(var s=t.desktop?t.desktop.alerts:_uWnd.alerts,i=null;s&&s.wnd!==t;)i=s,s=s.prev;s&&s.wnd===t&&(i?i.prev=s.prev:t.desktop?t.desktop.alerts=s.prev:_uWnd.alerts=s.prev)},_uWnd._onscroll=function(t){if($.browser&&$.browser.msie){_uWnd.getdims();var e=_uWnd.all;for(var s in e)e[s]&&(!e[s].props.fixed&&!e[s].grid||e[s].havefixed||e[s].moveTo(e[s].xpos,e[s].ypos))}},_uWnd._onresize=function(t,e){var s=_uWnd.getdims(),i=_uWnd.all;for(var o in i)i[o]&&((e||i[o].desktop)&&i[o].desktop!=e||i[o]._onresize(s))},_uWnd.closepopup=function(){var t=_uWnd.all;for(var e in t)t[e]&&t[e].props.popup&&_uWnd.ignoreclick!=t[e]&&t[e].closeevent();_uWnd.ignoreclick&&setTimeout("_uWnd.ignoreclick=null;",10)},_uWnd.findparent=function(t){for(var e=t;e&&e!=document.body;){if(e.id&&e.id.indexOf&&0==e.id.indexOf("_uwndTop")&&e._uwndobj)return e._uwndobj;e=e.parentNode}return null},_uWnd.getbyname=function(t){var e=this.all,s=parseInt(t);if(!isNaN(s)&&String(s)==String(t))return e[s]||null;for(var i in e)if(e[i]&&e[i].name==t)return e[i];return null},_uWnd.getTopZ=function(nc,ignw){with(nc||(nc=0),_uWnd){var z=lastz;if(z<minz?z=minz:z+=zstep,z+(1+nc)*zstep>maxz){var x=minz,ar=[];for(var i in all)all[i]&&all[i]!=ignw&&all[i].props&&!all[i].props.parent&&!(all[i].props.modal||all[i].props.alert||all[i].modalparent)&&(ar[ar.length]=all[i]);for(var i=0;i<zchilds.length;i++)zchilds[i]&&(ar[ar.length]=zchilds[i]);ar.sort(function(t,e){return t.zpos-e.zpos});for(var i=0;i<ar.length;i++)ar[i].setZ(x),x+=zstep*(1+(ar[i].nchilds?ar[i].nchilds:0));z=x}return lastz=z+(1+nc)*zstep,z}},_uWnd.getModalTopZ=function(nc,ignw){with(nc||(nc=0),_uWnd){var z=lastmodalz;if(z<minmodalz?z=minmodalz:z+=zstep,z+(1+nc)*zstep>maxmodalz){var x=minmodalz,ar=[];for(var i in all)all[i]&&all[i]!=ignw&&all[i].props&&!all[i].props.parent&&(all[i].props.modal||all[i].props.alert||all[i].modalparent)&&(ar[ar.length]=all[i]);ar.sort(function(t,e){return t.zpos-e.zpos});for(var i=0;i<ar.length;i++)ar[i].setZ(x),x+=zstep*(1+(ar[i].nchilds?ar[i].nchilds:0));z=x}return lastmodalz=z+(1+nc)*zstep,z}},_uWnd.getdims=function(){return{clientW:Math.min(document["BackCompat"===document.compatMode?"body":"documentElement"].clientWidth||$(window).width()),clientH:Math.min(document["BackCompat"===document.compatMode?"body":"documentElement"].clientHeight||$(window).height()),clientLeft:$(document).scrollLeft(),clientTop:$(document).scrollTop(),docW:$(document).width(),docH:$(document).height()}},_uWnd.csize=function(t,e){if("width"!=e&&"height"!=e)return 0;var s,i="width"==e?["Left","Right"]:["Top","Bottom"];s="width"==e?t.offsetWidth:t.offsetHeight;var o=0,a=0;return jQuery.each(i,function(){o+=parseFloat(jQuery.css(t,"padding"+this,!0))||0,a+=parseFloat(jQuery.css(t,"border"+this+"Width",!0))||0}),s-=Math.round(o+a),Math.max(0,s)},_uWnd.close=function(t){var e=this.getbyname(t);e?e.close():Object.values(this.all).filter(t=>!!t).forEach(t=>this.close(t.name))},_uWnd.content=function(t,e){var s=_uWnd.getbyname(t);s&&s.content(e)},_uWnd.header=function(t,e){var s=_uWnd.getbyname(t);s&&s.header(e)},_uWnd.footer=function(t,e){var s=_uWnd.getbyname(t);s&&s.footer(e)},_uWnd.headerheight=function(t,e){var s=_uWnd.getbyname(t);s&&s.headerheight(e)},_uWnd.footerheight=function(t,e){var s=_uWnd.getbyname(t);s&&s.footerheight(e)},_uWnd.reload=function(t,e){var s=_uWnd.getbyname(t);s&&s.reload(e)},_uWnd.setTitle=function(t,e){var s=_uWnd.getbyname(t);s&&s.setTitle(e)},_uWnd.activatetopwnd=function(t){var e=0,s=null,i=_uWnd.all;for(var o in i)!i[o]||t&&i[o].desktop!=t||!i[o].state.visible||i[o].state.minimized||i[o].props.alert||i[o].zpos>e&&(e=i[o].zpos,s=i[o]);s?s.activate():t&&t.activate()},_uWnd.havesysmenu=0,_uWnd.sysmenu=null,_uWnd.sysmenuitems=[[_txt("Restore"),null,"rest"],[_txt("Minimize"),null,"min"],[_txt("Maximize"),null,"max"],"sep",[_txt("Close"),null,"close"]],_uWnd._onsysmenuitem=function(t,e,s){var i=e.forwnd;if(i)switch(s){case"rest":i.state.minimized&&i.ontaskbar?i.desktop.wndlist.design.animatewndrestore(i.desktop.wndlist,i):i.restore(1);break;case"min":i.minimize();break;case"max":i.state.minimized&&i.ontaskbar?i.desktop.wndlist.design.animatewndmaximize(i.desktop.wndlist,i):i.maximize(1);break;
1case"close":i.closeevent()}},_uWnd.designs={std:{altcloseclass:"xt-close2",altmaxiclass:"xt-maxi2",altrestclass:"xt-rest2",custButMargin:5,wnd_init:function(t,e,s,i,o,a,n,r,l){e.classList.add("xw-plain","x-unselectable"),t.props.alert&&e.classList.add("xw-active"),r&&e.classList.add("xw-resize");let h="";if(t.props.customButtons)for(var d in t.props.customButtons)h+='<div class="xt xt-'+d+'"></div>';contentAlignmentAttribute="text-"+({start:"start",end:"end",left:"left",right:"right",center:"center",justify:"justify","match-parent":"match-parent"}[i]||"start");let u=a?`<div class="xw-tl"><div class="xw-tr"><div class="xw-tc">\n\t\t\t\t\t<div class="xw-sps"></div>\n\t\t\t\t\t<div class="xw-hdr">\n\t\t\t\t\t\t<div class="xt xt-close"></div>\n\t\t\t\t\t\t<div class="xt xt-maxi"></div>\n\t\t\t\t\t\t<div class="xt xt-rest"></div>\n\t\t\t\t\t\t<div class="xt xt-mini"></div>\n\t\t\t\t\t\t${h}\n\t\t\t\t\t\t${n?`<img unselectable="on" onmousedown="return false;" class="xw-icon x-unselectable" src="${n}">`:t.props.iconstyle?`<div unselectable="on" onmousedown="return false;" class="xw-icon x-unselectable" style="background:${t.props.iconstyle}"></div>`:""}\n\t\t\t\t\t\t<span class="xw-hdr-text">${s}</span>\n\t\t\t\t\t</div>\n\t\t\t\t</div></div></div>`:'<div class="xw-tl"><div class="xw-tr"><div class="xw-tc xw-tsps"></div></div></div>';e.innerHTML=`<div class="xw-disabled" style="display:none;overflow:hidden;position:absolute;z-index:30010"></div>\n\t\t\t\t${u}\n\t\t\t\t<div class="xw-ml"><div class="xw-mr"><div class="xw-mc">\n\t\t\t\t\t${l?'<div class="u-wndmenufr"><div class="u-wndmenu" style="position:relative"></div></div>':""}\n\t\t\t\t\t<div class="xw-body">\n\t\t\t\t\t\t${t.props.havegrid?`<div class="${t.props.markwaitclass}" style="display:none;overflow:hidden;position:absolute;z-index:30000"></div>`:""}\n\t\t\t\t\t\t${t.props.headerc?`<div class="myWinCont myWinHeader" style="overflow:hidden;height:${t.headerh}px"></div>`:""}\n\t\t\t\t\t\t${t.props.actlayer?'<div class="xw-actlayer" style="overflow:hidden;position:absolute;z-index:30005"></div>':""}\n\t\t\t\t\t\t<div style="overflow:scroll;height:${o}px">\n\t\t\t\t\t\t\t<div class="myWinCont" style="display:none;overflow:hidden;" ${contentAlignmentAttribute}></div>\n\t\t\t\t\t\t\t<div class="myWinCont" style="overflow:hidden;" ${contentAlignmentAttribute}></div>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t\t${t.props.footerc?`<div class="myWinCont myWinFooter" style="overflow:hidden;height:${"auto"==t.footerh?t.footerh:`${t.footerh}px`}"></div>`:""}\n\t\t\t\t\t</div>\n\t\t\t\t</div></div></div>\n\t\t\t\t<div class="xw-bl"><div class="xw-br"><div class="xw-bc"></div></div></div>\n\t\t\t\t<div class="xw-blank" style="display:none"></div>`;var p={},c=0;if(t.props.attachicon&&($(t.top).append('<div class="xw-attachicon" style="display:none;position:absolute;z-index:3"></div>'),p.attachicon=$(t.top).find(".xw-attachicon")[0]),p.markdis=$(e).find(".xw-disabled")[0],p.actlayer=$(e).find(".xw-actlayer")[0],p.wndmove=$(e).find(".xw-blank")[0],p.upper=$(e).find(".xw-tl")[0],p.center=$(e).find(".xw-ml")[0],p.bottom=$(e).find(".xw-bl")[0],p.bottomc=$(e).find(".xw-bc")[0],$(e).find(".xw-mc").on("mousedown",t,_uWnd._activateonmousedown),t.props.headerc&&(p.headercont=$(e).find(".myWinCont")[c],$(p.headercont).html(t.props.headerc),c++),p.markload=$(e).find(".myWinCont")[c],$(p.markload).html(t.props.markload),p.wndcont=$(e).find(".myWinCont")[c+1],t.props.footerc&&(p.footercont=$(e).find(".myWinCont")[c+2],$(p.footercont).html(t.props.footerc)),t.props.havegrid&&(p.markwait=$(e).find("."+t.props.markwaitclass)[0],$(p.markwait).html(t.props.markwaitcont)),p.hwndcont=p.wndcont.parentNode,a){p.hdr=$(e).find(".xw-hdr")[0],p.htitle=$(e).find(".xw-hdr-text")[0];var m={cbut:"xt-close",mbut:"xt-mini",xbut:"xt-maxi",rbut:"xt-rest",icon:"xw-icon"};for(var d in m)p[d]=$(p.hdr).find("."+m[d])[0];for(var d in p.custom={},t.props.customButtons)p.custom[d]=$(p.hdr).find(".xt-"+d)[0]}else p.hdr=p.htitle=p.cbut=p.mbut=p.xbut=p.rbut=p.icon=null;return p.menu=l?$(e).find(".u-wndmenu")[0]:null,$(e).find("div,span")[$.fn.andSelf?"andSelf":"addBack"]().attr("unselectable","on"),p},onstartautosz:function(t){t._savedScrollSize=t.parts.wndcont.scrollTop,t.parts.wndcont.style.overflow="hidden",t.parts.wndcont.style.height="auto"},onstopautosz:function(t,e){e||(t.parts.hwndcont.style.visibility="",t.parts.headercont&&t.props.hidehonresize&&(t.parts.headercont.style.visibility=""),t.parts.footercont&&t.props.hidefonresize&&(t.parts.footercont.style.visibility="")),t.parts.wndcont.style.overflow="auto",t.parts.wndcont.style.height="100%",t._savedScrollSize>0&&(t.parts.wndcont.scrollTop=t._savedScrollSize)},get_szbuts:function(t){var e={nw:"xw-tl",n:"xw-sps",ne:"xw-tr",w:"xw-ml",e:"xw-mr",sw:"xw-bl",s:"xw-bc",se:"xw-br"};for(var s in e)e[s]=$(t).find("."+e[s])[0];return e.n||(e.n=$(t).find(".xw-tsps")[0]),e},onbuttonover:function(t){var e=t.data.cls;t.data.state?$(this).addClass(e+"-over"):$(this).removeClass(e+"-over")},onstartdrag:function(t){$(t.top).addClass("xw-dragging"),!t.state.minimized&&t.props.hideonmove&&($(t.parts.center).add(t.parts.bottom).hide(),$(t.parts.wndmove).css("width",t.width+"px").css("height",t.height-t.decor.th+"px").show())},onstopdrag:function(t){$(t.top).removeClass("xw-dragging"),!t.state.minimized&&t.props.hideonmove&&($(t.parts.center).add(t.parts.bottom).show(),$(t.parts.wndmove).hide())},ondisable:function(t,e){e?($(t.parts.markdis).css("width",Math.abs(t.width)+"px").css("height",Math.abs(t.height)+"px").show(),$(t.wnd).removeClass("xw-active")):($(t.parts.markdis).hide(),(t.state.focused||t.props.alert)&&$(t.wnd).addClass("xw-active"))},onfocus:function(t,e){e&&!t.state.disabled?$(t.wnd).addClass("xw-active"):$(t.wnd).removeClass("xw-active")},onstartresize:function(t){},onstopresize:function(t){},onminimize:function(t){$(t.parts.center).css("display","none"),$(t.parts.bottomc).addClass("xw-bcm")},onrestore:function(t){$(t.parts.bottomc).removeClass("xw-bcm"),$(t.parts.center).css("display","block")}}},_uWnd.prototype={showsysmenu:function(t,e){this.activate();var s,i=_uWnd.sysmenu;i&&((s=i.indexById("rest"))>=0&&(this.state.minimized&&(this.props.max||"max"!=this.state.beforemin)||this.props.max&&this.state.maximized?($(i.parts.elems[s]).removeClass("u-graymenuitem"),i.elems[s][1]=null):($(i.parts.elems[s]).addClass("u-graymenuitem"),i.elems[s][1]=1)),(s=i.indexById("min"))>=0&&(this.props.min&&!this.state.minimized?($(i.parts.elems[s]).removeClass("u-graymenuitem"),i.elems[s][1]=null):($(i.parts.elems[s]).addClass("u-graymenuitem"),i.elems[s][1]=1)),(s=i.indexById("max"))>=0&&((this.props.max||this.state.minimized&&"max"==this.state.beforemin)&&!this.state.maximized?($(i.parts.elems[s]).removeClass("u-graymenuitem"),i.elems[s][1]=null):($(i.parts.elems[s]).addClass("u-graymenuitem"),i.elems[s][1]=1)),i.forwnd=this,this.props.popup&&(_uWnd.ignoreclick=this),_uWnd.globalmousedown(),i.show({pos:{x:t,y:e},parentfocus:this._focus}))},_foreachchild:function(t,e){for(var s,i=0;i<this.childs.length;i++)(s=this.childs[i])&&!s.state.destroyed&&(e?(s._foreachchild(t,e),t.call(this,s)):t.call(this,s)||s._foreachchild(t,e))},showattachicon:function(t){if(!this.state.destroyed){var e,s=this.props.attachicon,i=this.parts.attachicon,o=this.props.attachicondelta,a={lt:"l",lb:"l",rt:"r",rb:"r",tl:"t",tr:"t",bl:"b",br:"b"},n={lt:"h",lb:"h",rt:"h",rb:"h",tl:"v",tr:"v",bl:"v",br:"v"};if(this.parts.attachicon){if(arguments.length>0){if(t&&s&&((e="object"==typeof s?s[t]:s)||(e=s[a[t]])||(e=s[n[t]])),!e||!t)return void(this.parts.attachicon.style.display="none")}else if(!(t=this.attachicon))return;this.attachicon!=t&&$(i).html(e),"h"==n[t]?("lt"==t||"rt"==t?$(i).css({top:0,bottom:""}
1):$(i).css({bottom:-this.height+"px",top:""}),"l"==a[t]?$(i).css({left:"",right:-o+"px"}):$(i).css({right:"",left:this.width-o+"px"})):("tl"==t||"bl"==t?$(i).css({right:"",left:"0px"}):$(i).css({left:"",right:-this.width+"px"}),"t"==a[t]?$(i).css({bottom:-o+"px",top:""}):$(i).css({top:this.height-o+"px",bottom:""})),this.attachicon||(this.parts.attachicon.style.display=""),this.attachicon=t}}},setZ:function(z){with(this){if(state.destroyed)return;var c;zpos=z;for(var i=0;i<this.childs.length;i++)c=this.childs[i],c&&!c.state.destroyed&&(z+=_uWnd.zstep,c.setZ(z),z+=_uWnd.zstep*c.nchilds);$(top).css("z-index",zpos),grid&&$(grid).css("z-index",zpos-1)}},saveSession:function(){var t;return{x:(t=this.state.maximized||this.state.minimized?this.restRect:[this.xpos,this.ypos,this.width,this.height])[0],y:t[1],w:t[2]-this.decor.w,h:t[3]-this.decor.h,bm:this.state.minimized?this.state.beforemin:"",s:this.state.maximized?"max":this.state.minimized?"min":""}},attachTo:function(t,e,s,i){if(!this.state.destroyed){var o,a,n,r,l,h,d,u,p,c,m,f,_,b,g,v,w,y;if(t&&t.nodeType||t[0]&&t[0].nodeType)o=t.nodeType?t:t[0],a=$(o).offset(),n=o.offsetWidth,r=o.offsetHeight;else{if(!t||2!=t.length)return;a={left:t[0],top:t[1]},n=r=0}u=(d=_uWnd.getdims()).clientW,p=d.clientH,c=d.clientLeft,m=d.clientTop,e=e||"rt",s=s||0,i=i||0,this.desktop&&(u=(d=this.desktop).width,p=d.height,c=0,m=0),this.props.fixed&&(c=m=0),1==e.length&&("u"==e.toLowerCase()||"d"==e.toLowerCase()?e+="r":e+="t"),window._rtl&&(e=e.replace(/[lLrR]/g,function(t){return"l"==t?"r":"L"==t?"R":"r"==t?"l":"R"==t?"L":void 0})),f=e.substr(0,1),b=a.left+n+s,_=a.left-s-this.width,v=a.top+r+i,g=a.top-i-this.height,l=b,w="l",h=a.top-i,y="t","l"==f?(l=_,w="r"):"r"==f||"L"==f&&_-c<1&&c-_>b-c+this.width-u?(l=b,w="l"):"R"==f&&b-c+this.width>u-3&&c-_<b-c+this.width-u?(l=_,w="r"):"u"==f?(h=g,w="b"):"d"==f||"U"==f&&g-m<1&&m-g>v-m+this.height-p?(h=v,w="t"):"D"==f&&v-m+this.height>p-3&&m-g<v-m+this.height-p&&(h=g,w="b"),f=e.substr(1,1),b=a.left+n-this.width+s,_=a.left-s,v=a.top+r+-this.height+i,g=a.top-i,"l"==f?(l=_,y="l"):"r"==f||"L"==f&&_-c<1&&c-_>b-c+this.width-u?(l=b,y="r"):"R"==f&&b-c+this.width>u-3&&c-_<b-c+this.width-u?(l=_,y="l"):"t"==f?(h=g,y="t"):"b"==f||"T"==f&&g-m<1&&m-g>v-m+this.height-p?(h=v,y="b"):"B"==f&&v-m+this.height>p-3&&m-g<v-m+this.height-p&&(h=g,y="t"),this.showattachicon(w+y),l==this.xpos&&h==this.ypos||this.moveTo(l,h)}},moveTo:function(_x,_y,nopos){if(!this.state.destroyed){var d=_uWnd.getdims();with(this){if("auto"!=_x||"auto"!=_y||!desktop||props.fixed||props.autosize||props.center)"auto"==_x&&(_x=props.parent?Math.floor((props.parent.width-width)/2)+props.parent.xpos:desktop&&!props.fixed?Math.floor((desktop.calcwidth()-width)/2)+desktop.calcexclude(0):Math.floor((d.clientW-width)/2)+(props.fixed?0:d.clientLeft),_x<0&&(_x=0)),"auto"==_y&&(_y=props.parent?Math.floor((props.parent.height-height)/2)+props.parent.ypos:desktop&&!props.fixed?Math.floor((desktop.calcheight()-height)/2)+desktop.calcexclude(2):Math.floor((d.clientH-height)/2)+(props.fixed?0:d.clientTop),_y<0&&(_y=0));else{var p=desktop.getwndcoord(width,height);_x=p.x,_y=p.y}props.fixed&&!havefixed?$(top).css("left",d.clientLeft+_x+"px").css("top",d.clientTop+_y+"px"):$(top).css("left",_x+"px").css("top",_y+"px"),grid&&(havefixed?$(grid).css("left","0px").css("top","0px"):$(grid).css("left",d.clientLeft+"px").css("top",d.clientTop+"px")),xpos=_x,ypos=_y,nopos||(sesupdate=1),this.props.onposchange&&this.props.onposchange.apply(this.app,[this])}}},setTitle:function(t){this.state.destroyed||(null!=t&&(this.title=t),this.title||(this.title=""),this.props.header&&($(this.parts.htitle).attr("title","").text(this.title),this.ontaskbar&&desktop._onsetwindowtitle(this)))},resizeTo:function(w,h,center,nopos){with(this){if(state.destroyed)return;if(w<0&&(w=-w+decor.w),h<0&&(h=-h+decor.h),center&&!props.attachobj){var d=_uWnd.getdims(),_x=xpos,_y=ypos;"auto"==props.x&&(_x=props.parent?Math.floor((props.parent.width-w)/2)+props.parent.xpos:desktop&&!props.fixed?Math.floor((desktop.calcwidth()-w)/2)+desktop.calcexclude(0):Math.floor((d.clientW-w)/2)+(props.fixed?0:d.clientLeft),_x<0&&(_x=0)),"auto"==props.y&&(_y=props.parent?Math.floor((props.parent.height-h)/2)+props.parent.ypos:desktop&&!props.fixed?Math.floor((desktop.calcheight()-h)/2)+desktop.calcexclude(2):Math.floor((d.clientH-h)/2)+(props.fixed?0:d.clientTop),_y<0&&(_y=0)),_x!=xpos|_y!=ypos&&moveTo(_x,_y,1)}$(wnd).css("width",w+"px"),$(parts.wndcont).css("width",w-decor.w+"px"),$(parts.hwndcont).css("height",h-decor.h+"px"),parts.markwait&&$(parts.markwait).css({height:h-decor.h+footerh+headerh+"px",width:w-decor.w+"px"}),parts.actlayer&&$(parts.actlayer).css({height:h-decor.h+"px",width:w-decor.w+"px"}),parts.markdis&&$(parts.markdis).css("width",w+"px").css("height",h+"px"),menu&&$(parts.menu).css("width",w-decor.w+"px"),tabctrl&&tabctrl.resizeTo(w-decor.w,h-decor.h),frame&&$(frame).css("width",w+"px").css("height",h+"px"),width=w,height=h,props.attachobj&&attachTo(props.attachobj,props.attachtype,props.attachdx,props.attachdy),nopos||this.state.maximized||this.state.minimized||(sesupdate=1),!this.props.onposchange||this.state.maximized||this.state.minimized||this.props.onposchange.apply(this.app,[this]),showattachicon()}},_onresize:function(t){this.state.maximized&&(this.desktop&&!this.props.fixed?(this.moveTo(this.desktop.calcexclude(0),this.desktop.calcexclude(2),1),this.resizeTo(this.desktop.calcwidth(),this.desktop.calcheight(),0,1)):this.resizeTo(t.clientW,t.clientH)),this.grid&&$(this.grid).css("width",t.clientW+"px").css("height",t.clientH+"px")},showcustombutton:function(t,e){this.props.customButtons[t]&&(this.props.customButtons[t][0]=e,this.parts.custom[t]&&(e?$(this.parts.custom[t]).css("display","block"):$(this.parts.custom[t]).css("display","none")))},init:function(t){var e,s=this.props,i=document.createElement("div");if(i.id="_uwndTop"+this.idx,s.topclass&&(isArray(s.topclass)?i.classList?.add(...s.topclass):i.classList?.add(s.topclass)),i._uwndobj=this,this.desktop?this.desktop.dsk.appendChild(i):$($("body")[0]).prepend(i),this.top=i,s.fixed&&this.havefixed?$(i).css("position","fixed"):$(i).css("position","absolute"),$(i).css("visibility","hidden").css({display:"block",zIndex:this.zpos,overflow:"visible"}),s.modal&&!s.parent){var o=document.createElement("div"),a=_uWnd.getdims();const t={position:this.havefixed?"fixed":"absolute",width:`${a.clientW}px`,height:`${a.clientH}px`,"z-index":this.zpos-1};if(s.gridblur){const e=/[a-z]/.test(s.gridblur)?s.gridblur:`${s.gridblur}px`;t["backdrop-filter"]=`blur(${e})`}$(o).addClass(s.gridclass).css(t).hide().on("mousedown",function(t){t.stopPropagation(),t.preventDefault(),_uWnd.globalmousedown()}),this.desktop?this.desktop.dsk.appendChild(o):$(document.body).prepend(o),this.grid=o}if(this.moveTo(0,0,1),e=document.createElement("div"),s.shadow&&e.classList.add("xw-shadow"),e.id="_uwndWnd"+this.idx,i.appendChild(e),this.wnd=e,$(e).css({position:"absolute",width:Math.abs(this.width)+"px",zIndex:2,left:0,overflow:"visible"}),_uWnd._activateonmousedown||(_uWnd._activateonmousedown=function(t){t.stopPropagation(),t.data.activate(t),t.data.props.popup&&(_uWnd.ignoreclick=t.data),_uWnd.globalmousedown()}),this.parts=this.design.wnd_init(this,e,this.title,s.align,60,s.header,s.icon,s.resize,s.havemenu),_uWnd._onbuttonclose||(_uWnd._onbuttonclose=function(t){t.data.activate(t),t.data.closeevent()}),_uWnd._onbuttonhide||(_uWnd._onbuttonhide=function(t){t.data.hide()}),s.header){var n={cbut:"xt-close",mbut:"xt-mini",xbut:"xt-maxi",rbut:"xt-rest"};for(var r in _uWnd._retfalse||(_uWnd._retfalse=function(t){return!1}),_uWnd._onclickcustom||(_uWnd._onclickcustom=function(t){var e=t.data;e.wnd.activate(t),e.func.call(e.thispar,e.wnd,e.param)}),_uWnd._onbuttonmin||(_uWnd._onbuttonmin=function(t){t.data.activate(t),t.data.minimize()}),_uWnd._onbuttonmax||(_uWnd._onbuttonmax=function(t){t.data.activate(t),t.data.maximize()}),_uWnd._onbuttonrest||(_uWnd._onbuttonrest=function(t){t.data.activate(t),t.data.restore(
1)}),n)$(this.parts[r]).on("dblclick",_uWnd._retfalse).on("mouseover",{cls:n[r],state:1},this.design.onbuttonover).on("mouseout",{cls:n[r],state:0},this.design.onbuttonover).on("mousedown",this,_uWnd._activateonmousedown);for(var r in s.customButtons)$(this.parts.custom[r]).on("dblclick",_uWnd._retfalse).on("mouseover",{cls:"xt-"+r,state:1},this.design.onbuttonover).on("mouseout",{cls:"xt-"+r,state:0},this.design.onbuttonover).on("mousedown",this,_uWnd._activateonmousedown),s.customButtons[r][0]||$(this.parts.custom[r]).css("display","none"),s.customButtons[r][1]&&$(this.parts.custom[r]).on("click",{wnd:this,func:s.customButtons[r][1],thispar:s.customButtons[r][2],param:s.customButtons[r][3]||r},_uWnd._onclickcustom);s.close||$(this.parts.cbut).css("display","none"),$(this.parts.cbut).on("click",this,_uWnd._onbuttonclose),s.min||$(this.parts.mbut).css("display","none"),$(this.parts.mbut).on("click",this,_uWnd._onbuttonmin),s.max||$(this.parts.xbut).css("display","none"),$(this.parts.xbut).on("click",this,_uWnd._onbuttonmax),$(this.parts.rbut).css("display","none").on("click",this,_uWnd._onbuttonrest),s.close&&!s.min&&!s.max&&this.design.altcloseclass&&$(this.parts.cbut).addClass(this.design.altcloseclass),s.max&&!s.min&&(this.design.altmaxiclass&&$(this.parts.xbut).addClass(this.design.altmaxiclass),this.design.altrestclass&&$(this.parts.rbut).addClass(this.design.altrestclass)),_uWnd._onclicktodrag||(_uWnd._onclicktodrag=function(t){return t.stopPropagation(),t.data.activate(t),t.data.props.popup&&(_uWnd.ignoreclick=t.data),_uWnd.globalmousedown(),t.data._ondragmousedown(t)}),_uWnd._ondclicktomax||(_uWnd._ondclicktomax=function(t){var e=t.data;e.state.maximized&&e.props.max||e.state.minimized?e.restore():e.maximize()}),s.nomove||$(this.parts.hdr).addClass("xw-draggable"),$(this.parts.hdr).add(this.parts.htitle).on("mousedown",this,_uWnd._onclicktodrag),(s.max||s.min)&&$(this.parts.hdr).on("dblclick",this,_uWnd._ondclicktomax)}this.parts.attachicon&&s.attachiconact&&$(this.parts.attachicon).on("click",this,"hide"==s.attachiconact?_uWnd._onbuttonhide:_uWnd._onbuttonclose);var l=this.design.get_szbuts(e);for(var r in _uWnd._onresizebuttondown||(_uWnd._onresizebuttondown=function(t){return t.stopPropagation(),t.data.w.activate(t),t.data.w.props.popup&&(_uWnd.ignoreclick=t.data.w),_uWnd.globalmousedown(),t.data.w._onrsmousedown(t,t.data.tp)}),l)$(l[r]).on("mousedown",{w:this,tp:r},_uWnd._onresizebuttondown);if($(i).on("mousedown",this,_uWnd._activateonmousedown),s.havemenu){var h=$.extend({parentnode:this.parts.menu,wnd:this,thispar:this.app,noabs:1,horiz:1,statical:1,width:"auto"},s.menuopts||{});this.menu=new _uMENU("",{},h,t,!0)}if("object"==typeof this._content&&this._content.constructor==_uTabCtrl?(this.tabctrl=this._content,this.tabctrl.props.parentnode=this.parts.wndcont,this.tabctrl.wnd=this,this.tabctrl.init(!0)):this.tabctrl=null,s.trayicon&&this.desktop){var d={};s.trayicon.contructor==String?d.img=s.trayicon:s.trayicon.contructor!=Object&&(d.img=s.icon||s.iconstyle),d.img&&(s.trayicon.thisobj?$.extend(d,s.trayicon):(d.thisobj=this,s.trayicon.ondown||(d.ondown=this.ontrayicondown),s.trayicon.onrdown||(d.onrdown=this.ontrayiconrdown),d.param=s.trayicon.param),d.title||(d.title=this.title||""),this.trayicon=this.desktop.addTrayIcon(d.img,d.title,d.thisobj,d.ondown,d.onclick,d.onrdown,d.param),s.traymenu&&(this.traymenu=new _uMENU("",{align:"U"},{hidden:1},s.traymenu)))}s.hidden||this.show(!1),!this.desktop||s.popup||s.alert||!s.header||s.notaskbar?this.ontaskbar=!1:(this.ontaskbar=!0,this.desktop._addwindow(this)),s.modal&&s.parent&&s.parent.disable(1),this.props.parent&&this.props.parent._onnewchild(this),this.activate(),s.header||this.menu?setTimeout("var _uw=_uWnd.all["+this.idx+"]; if (_uw)_uw.init1();",10):setTimeout("var _uw=_uWnd.all["+this.idx+"]; if (_uw)_uw.init2();",10)},init1:function(){this.menu&&this.menu.init1(!0),setTimeout("var _uw=_uWnd.all["+this.idx+"]; if (_uw)_uw.init2();",10)},init2:function(){with(this){decor.sbw=parts.hwndcont.offsetWidth-parts.hwndcont.clientWidth,decor.sbh=parts.hwndcont.offsetHeight-parts.hwndcont.clientHeight,decor.w=Math.abs(width)-_uWnd.csize(parts.wndcont,"width")-decor.sbw,decor.h=wnd.offsetHeight-60,decor.th=parts.upper.offsetHeight,parts.hwndcont.style.overflow="hidden",tabctrl?tabctrl.init1(!0):(parts.headercont&&props.hideheader&&(parts.headercont.style.visibility="hidden"),parts.footercont&&props.hidefooter&&(parts.footercont.style.visibility="hidden")),showattachicon(props.attachicontype),props.session?resizeTo(props.session.w+decor.w,props.session.h+decor.h,0,1):resizeTo(width,height,0,1),props.attachobj||moveTo(props.x,props.y,1),menu&&menu._setsize(),state.init=!0;var rel=!!pend_show&&pend_show[0];props.oninit&&(props.oninit.call(app,this,name)||(rel=!1)),$(top).css("display","none").css("visibility","");var s=props.session;s=s&&s.s||props.initstate,"min"==s?(minimize(1),state.beforemin=s&&s.bm||"",props.max||"max"!=props.initstate||(state.beforemin="max")):"max"==s?maximize(0,1):pend_show&&show(rel,pen
1d_show[1],pend_show[2]),sesupdate=0}},disable:function(t,e){if(!this.state.destroyed){var s;if(!e)if(t){if(!this.state.disabled)for(var i=0;i<this.childs.length;i++)!(s=this.childs[i])||s.state.destroyed||s.props.alert||(s.state.prevdisabled=s.state.disabled,s.disable(1));this.state.disabled=!0}else{if(this.state.disabled)for(i=0;i<this.childs.length;i++)!(s=this.childs[i])||s.state.destroyed||s.props.alert||void 0===s.state.prevdisabled||s.disable(s.state.prevdisabled);this.state.disabled=!1}this.design.ondisable(this,t)}},_onkeypress:function(t,e,s){!this.state.disabled&&this.state.visible&&!this.props.toolwindow&&115==t.keyCode&&t.ctrlKey&&t.shiftKey&&t.preventDefault()},_onkeydown:function(t,e,s){if(!this.state.disabled&&this.state.visible&&!this.props.toolwindow){if(115==t.keyCode&&t.ctrlKey&&t.shiftKey||27==t.keyCode&&this.props.closeonesc)return this.props.close&&this.closeevent(),1;if(this.menu&&(17==t.keyCode||18==t.keyCode)&&t.ctrlKey&&t.altKey&&s.owner.constructor!=_uMENU)return this.props.popup&&(_uWnd.ignoreclick=this),_uWnd.globalmousedown(),this.menu.show(null,0),this.menu._focus.activate(),t.preventDefault(),t.stopPropagation(),1;if(this.props.havesysmenu&&this.props.header&&this.parts.hdr&&32==t.keyCode&&t.ctrlKey&&!this.state.resizing){var i=$(this.parts.hdr).offset();return this.showsysmenu(i.left,i.top+this.parts.hdr.offsetHeight),t.preventDefault(),t.stopPropagation(),1}}},_ondeactivate:function(t,e,s){if(this.props.toolwindow){for(var i=this.props.parent;i&&i.props.toolwindow;)i=i.props.parent;if(i&&i._focus.isparentof(s))return}this.state.focused=0,this.design.onfocus(this,0);var o=this.props.toolwindow?0:1;if(this.props.ondeactivate){var a=this.props.ondeactivate.apply(this.app,[this]);void 0!==a&&(o=a?1:0)}this.savedfocus=null;try{document.activeElement&&document.activeElement!=document.body&&document.activeElement.blur&&-1!=$.inArray(this.wnd,$.makeArray($(document.activeElement).parents()))&&(o&&(this.savedfocus=document.activeElement),document.activeElement.blur())}catch(t){}this.props.toolwindow||this._foreachchild(function(t){if(!t.props.toolwindow)return 1;t.state.focused=0,t.design.onfocus(t,0)},0)},_canactivate:function(t,e,s){return this.props.alert||this.state.minimized?0:1},activate:function(t,e){if(!this.state.destroyed&&(this.menu&&!e&&this.menu._focus.isactive()&&this.menu._focus.deactivate(),!this.props.alert))return this.props.modal&&this.props.parent&&this.props.parent.setforeground(),this._focus.activate()},_onactivate:function(t,e,s){if(s==this._focus)if(this.state.disabled){for(var i,o=0;o<this.childs.length;o++)if((i=this.childs[o])&&!i.state.destroyed&&!i.state.disabled&&!i.props.alert)return this.setforeground(),i.activate(),-1}else this.state.focused=1,this.design.onfocus(this,1),this.savedfocus&&this.savedfocus.focus&&-1!=$.inArray(this.wnd,$.makeArray($(this.savedfocus).parents()))&&this.savedfocus.focus(),this.props.onactivate&&this.props.onactivate.apply(this.app,[this]),this.savedfocus=null,this.props.toolwindow||this._foreachchild(function(t){if(!t.props.toolwindow)return 1;t.state.focused=1,t.design.onfocus(t,1)},0),this.setforeground()},setforeground:function(){this.props.modal&&!this.props.parent||this.props.alert||this.modalparent?this.zpos+this.nchilds*_uWnd.zstep!=_uWnd.lastmodalz&&this.setZ(_uWnd.getModalTopZ(this.nchilds)):this.zpos+this.nchilds*_uWnd.zstep!=_uWnd.lastz&&this.setZ(_uWnd.getTopZ(this.nchilds))},ontrayicondown:function(t,e,s){this.state.visible||this.state.minimized?this.state.minimized?"max"==this.state.beforemin?this.maximize(1):this.restore(1):this.props.min&&!this.props.notaskbar?this.minimize():t?this.hide():this.hide(0,0):t?this.show(!1):this.show(!1,0,0)},ontrayiconrdown:function(t,e,s){this.traymenu&&(this.traymenu.show({pos:{x:s.pageX,y:s.pageY}}),_uMENU.ignoreclick=this.traymenu)}
1,show:function(rel,fadetp,fadesp){if(!this.state.destroyed)with((arguments.length<2||null==fadetp)&&(fadetp=this.props.fadetype),(arguments.length<3||null==fadesp)&&(fadesp=this.props.fadespeed),_uWnd._onshowanimend||(_uWnd._onshowanimend=function(){var t=_uWnd.findparent(this);t&&(t.disable(t.state.disabled,1),t.autosz.startonshow&&t.delaychecksize())}),this){if(!state.init)return void(pend_show=[rel,fadetp,fadesp]);if(state.visible)return;if(state.visible=!0,grid&&$(grid).show(),1==fadetp)disable(1,1),$.browser&&$.browser.msie?($(wnd).hide(),$(top).show(),$(wnd).css("opacity","0").show().animate({opacity:1},{duration:fadesp,complete:_uWnd._onshowanimend})):$(top).fadeIn(fadesp,_uWnd._onshowanimend);else if(2==fadetp){disable(1,1);var endy=ypos;$(top).css("top",endy+(height>100?100:height)+"px"),$.browser&&$.browser.msie?($(wnd).hide(),$(top).show().animate({top:endy+"px"},{duration:fadesp,complete:_uWnd._onshowanimend}),$(wnd).css("opacity","0").show().animate({opacity:1},fadesp)):$(top).css("opacity","0").show().animate({top:endy+"px",opacity:1},{duration:fadesp,complete:_uWnd._onshowanimend})}else props.nohide&&$(top).css({visibility:""}),$(top).show(),disable(state.disabled),autosz.startonshow&&delaychecksize();state.loaded&&!rel||load()}},hide:function(fadetp,fadesp,doclose){if(!this.state.destroyed){with((arguments.length<1||null==fadetp)&&(fadetp=this.props.fadeclosetype),(arguments.length<2||null==fadesp)&&(fadesp=this.props.fadeclosespeed),_uWnd._onhideanimendcl||(_uWnd._onhideanimendcl=function(){var t=_uWnd.findparent(this);t&&t.close(1)}),this){if(!state.visible)return 0;if(autosz.active&&finishautosize(),state.visible=!1,1==fadetp)disable(1,doclose?0:1),$.browser&&$.browser.msie?$(wnd).animate({opacity:0}
1,{duration:fadesp,complete:doclose?_uWnd._onhideanimendcl:null}):$(top).animate({opacity:0},{duration:fadesp,complete:doclose?_uWnd._onhideanimendcl:null});else if(2==fadetp){disable(1,doclose?0:1);var endy=ypos+(height>100?100:height);$.browser&&$.browser.msie?($(top).animate({top:endy+"px"},{duration:fadesp,complete:doclose?_uWnd._onhideanimendcl:null}),$(wnd).animate({opacity:0},fadesp)):$(top).animate({top:endy+"px",opacity:0},{duration:fadesp,complete:doclose?_uWnd._onhideanimendcl:null})}else props.nohide?$(top).css({visibility:"hidden"}):$(top).hide(),doclose=!1;grid&&$(grid).hide(),_focus.isactive()&&(_focus.deactivate(),_uWnd.activatetopwnd(this.desktop))}return doclose?1:0}},markload:function(){if(!this.state.destroyed)with(this)parts.wndcont.style.display="none",parts.markload.style.display="block",parts.headercont&&props.hideheader&&(parts.headercont.style.visibility="hidden"),parts.footercont&&props.hidefooter&&(parts.footercont.style.visibility="hidden")},showgrid:function(){this.state.destroyed||this.parts.markwait&&(this.parts.markwait.style.display="block")},hidegrid:function(){this.state.destroyed||this.parts.markwait&&(this.parts.markwait.style.display="none")},reload:function(t,e){if(!this.state.destroyed){if("object"==typeof t&&t.constructor==_uTabCtrl){if(this.tabctrl!=t){if(t.state.init&&t.wnd!=this)return;this.tabctrl=t,t.props.parentnode=this.parts.wndcont,t.wnd=this;for(var s=this.parts.wndcont;s.firstChild;)s.removeChild(s.firstChild);t.state.init?(s.appendChild(t.top),t.resizeTo(this.width-this.decor.w,this.height-this.decor.h)):(t.init(!0),setTimeout("var _uw=_uWnd.all["+this.idx+"]; if (_uw && _uw.tabctrl){_uw.tabctrl.init1(true); _uw.resizeTo(_uw.width,_uw.height,0,1);}",10))}}else this.tabctrl&&(this.props.notabdestroy?(this.parts.wndcont.removeChild(this.tabctrl.top),this.tabctrl.parentnode=null,this.tabctrl.wnd=null):this.tabctrl.destroy()),this.tabctrl=null;this._content=t,this.state.loaded=!1,e||this.load()}},load:function(){if(!this.state.destroyed&&!this.tabctrl){var t=this._content;if(this.state.loaded=!0,this.xmlobj&&(this.xmlobj_ignoreabort=1,this.xmlobj.abort(),this.xmlobj=null),"string"==typeof t||"object"==typeof t&&(t.nodeType||t.constructor==jQuery))this.content(t);else if("function"==typeof t)this.content(t.apply(this.app,[this]));else if("object"==typeof t){this.markload(),this.app&&!("app"in t)&&(t.app=this.app.pid),t.wnd=this.idx,_uWnd._onAjaxComplete||(_uWnd._onAjaxComplete=function(t,e){var s=_uWnd.all[this.wnd];s&&s._oncomplete(t,e,this)}),t.complete!=_uWnd._onAjaxComplete&&(t.prev_complete_uwnd=t.complete,t.complete=_uWnd._onAjaxComplete),_uWnd._onAjaxBeforeSend||(_uWnd._onAjaxBeforeSend=function(t){var e=_uWnd.all[this.wnd];e&&(e.xmlobj=t,e.xmlobj_ignoreabort=0),this.prev_beforeSend_uwnd&&this.prev_beforeSend_uwnd.call(this,t)}),t.beforeSend!=_uWnd._onAjaxBeforeSend&&(t.prev_beforeSend_uwnd=t.beforeSend,t.beforeSend=_uWnd._onAjaxBeforeSend),t.success||!1!==t.xml||(t.dataType="text",_uWnd._onAjaxSuccess||(_uWnd._onAjaxSuccess=function(t,e){var s=_uWnd.all[this.wnd];s&&s.content(t)}),t.success=_uWnd._onAjaxSuccess);try{t.form&&t.form.length>0?_uPostForm(t.form,t):t.url&&_uAjaxRequest(t.url,t)}catch(e){this.xmlobj=null,this._onerror(null,"",e,t)}}}},_oncomplete:function(t,e,s){this.xmlobj=null,this.prev_complete_uwnd&&this.prev_complete_uwnd.call(s,t,e)},_onerror:function(t,e,s,i){if(!this.state.destroyed&&!this.state.pendingdestroy&&("abort"!=e&&"aborted"!=e||this.xmlobj&&!this.xmlobj_ignoreabort)){var o=this.props.onerror;o&&"function"==typeof o?o.call(this.app,this,t,e,s,i):this.close()}},header:function(t){if(!this.state.destroyed){var e=this.parts.headercont;e&&(t?$(e).html(t):$(e).html(""))}},footer:function(t){if(!this.state.destroyed){var e=this.parts.footercont;e&&(t?$(e).html(t):$(e).html(""))}},headerheight:function(t){if(!this.state.destroyed&&this.parts.headercont&&"number"==typeof t&&!isNaN(t)){var e=this.headerh;e!=t&&(this.decor.h+=t-e,this.headerh=t,$(this.parts.headercont).css("height",t+"px"),this.resizeTo(this.width,this.height+(this.props.contentsizeprio?t-e:0)))}},footerheight:function(t){if(!this.state.destroyed&&this.parts.footercont&&"number"==typeof t&&!isNaN(t)){var e=this.footerh;e!=t&&(this.decor.h+=t-e,this.footerh=t,$(this.parts.footercont).css("height",t+"px"),this.resizeTo(this.width,this.height+(this.props.contentsizeprio?t-e:0)))}},_checkimgload:function(load){var im=this.imgloader,i;if(im.active){if(load&&im.count++,im.images)for(i=0;i<im.images.length&&im.images[i].complete;i++);if(i>=im.images.length)this._stopimgload(!0);else if(im.count>=im.images.length&&(im.timer&&clearTimeout(im.timer),im.timer=setTimeout("var _uw=_uWnd.all["+this.idx+"]; if (_uw){_uw.imgloader.timer=null; _uw._checkimgload();}",100)),$.browser&&$.browser.opera&&im.images2){for(i=0;i<im.images2.length;i++)if(!im.images2[i].complete)return;with($(im.images2).off(),im.images2=null,this)parts.hwndcont.style.visibility="hidden",parts.markload.style.display="none",$(parts.wndcont).css("display","block"),parts.headercont&&!props.hidehonresize&&(parts.headercont.style.visibility=""),parts.footercont&&!props.hidefonresize&&(parts.footercont.style.visibility="")}}}
1,_stopimgload:function(start,wastm){var im=this.imgloader,d;if(im.active&&(im.active=!1,im.stoptimer&&(clearTimeout(im.stoptimer),im.stoptimer=null),im.timer&&(clearTimeout(im.timer),im.timer=null),im.images&&(im.images.off(),im.images=null),im.images2&&($(im.images2).off(),im.images2=null),start))with(this)props.hideonresize&&(parts.hwndcont.style.visibility="hidden"),parts.markload.style.display="none",$(parts.wndcont).css("display","block"),parts.headercont&&!props.hidehonresize&&(parts.headercont.style.visibility=""),parts.footercont&&!props.hidefonresize&&(parts.footercont.style.visibility=""),autosz.load=!0,props.onafterimgload&&(d=_uWnd.getdims(),props.onafterimgload.call(app,this,parts.wndcont,{w:d.clientW,h:d.clientH,dw:decor.w,dh:decor.h},wastm)),delaychecksize()},find:function(t){if(this.state.destroyed)return $([]);var e=$(this.parts.wndcont);return this.parts.headercont&&(e=e.add(this.parts.headercont)),this.parts.footercont&&(e=e.add(this.parts.footercont)),t?e.find(t):e},getcontent:function(t){return this.state.destroyed?null:t&&"h"==t.substr(0,1)?this.parts.headercont:t&&"f"==t.substr(0,1)?this.parts.footercont:this.parts.wndcont},content:function(t){if(!this.state.destroyed){this.xmlobj&&(this.xmlobj_ignoreabort=1,this.xmlobj.abort(),this.xmlobj=null),this._stopimgload(),this.stopautosize();var e=this.autosz,s=this.parts.wndcont,i=this.props,o=this.imgloader,a=this.parts.footercont,n=this.parts.headercont;if(this.state.loaded=!0,i.autosize&&i.waitimages>0){if(this.markload(),$(s).html(t),this.props.oncontent&&this.props.oncontent.apply(this.app,[this,s]),o.active=!0,o.stoptimer=setTimeout("var _uw=_uWnd.all["+this.idx+"]; if (_uw)_uw._stopimgload(1,1);",i.waitimages),_uWnd.waitimagesfunc||(_uWnd.waitimagesfunc=function(t){var e=t.data.imgloader;e.timer&&clearTimeout(e.timer),e.timer=setTimeout("var _uw=_uWnd.all["+t.data.idx+"]; if (_uw){_uw.imgloader.timer=null; _uw._checkimgload(1);}",10)}),o.count=0,o.images=$(s).find("img").on("error",this,_uWnd.waitimagesfunc).on("load",this,_uWnd.waitimagesfunc),$.browser&&$.browser.opera&&o.images.length>0){o.images2=[];for(var r=0;r<o.images.length;r++)o.images2[r]=$("<img>").attr("src",o.images[r].src).on("load",this,_uWnd.waitimagesfunc)[0]}this._checkimgload()}else i.autosize&&i.hideonresize&&(this.parts.hwndcont.style.visibility="hidden"),this.parts.markload.style.display="none",$(s).css("display","block").html(t),n&&(n.style.visibility=i.hidehonresize?"hidden":""),a&&(a.style.visibility=i.hidefonresize?"hidden":""),e.load=!0,i.autosize?(this.props.oncontent&&this.props.oncontent.apply(this.app,[this,s]),this.delaychecksize()):(this.design.onstopautosz(this),this.props.oncontent&&this.props.oncontent.apply(this.app,[this,s]));void 0!==$.mCustomScrollbar&&$(this.parts.wndcont).mCustomScrollbar()}},onexternalload:function(){with(this)_stopimgload(),stopautosize(),state.loaded=!0,autosz.load=!0,parts.headercont&&!props.hidehonresize&&(parts.headercont.style.visibility=""),parts.footercont&&!props.hidefonresize&&(parts.footercont.style.visibility=""),props.autosize&&delaychecksize()},stopautosize:function(){var t=this.autosz;t.inittimer&&(clearTimeout(t.inittimer),t.inittimer=null),t.timer&&(clearTimeout(t.timer),t.timer=null),t.images&&($(t.images).off(),t.images=null),t.active&&this.design.onstopautosz(this),t.active=!1},finishautosize:function(){var t=this.autosz;t.active&&(this.stopautosize(),this.resizeTo(t.tw+this.decor.w,t.th+this.decor.h,!0,1))},delaychecksize:function(t){t=t||10;var e=this.autosz;this.state.visible?(e.startonshow=0,e.inittimer&&clearTimeout(e.inittimer),e.inittimer=setTimeout("var _uw=_uWnd.all["+this.idx+"]; if (_uw)_uw.checksize();",t)):e.startonshow=1},_countbuttonwidth:function(){var t=0;for(var e in{cbut:1,mbut:1,xbut:1,rbut:1,icon:1})this.parts[e]&&(t+=this.parts[e].offsetWidth);for(var e in this.props.customButtons)t+=this.parts.custom[e].offsetWidth+this.design.custButMargin;return t},checksize:function(){var t=this.autosz,e=this.parts.wndcont;if(t.inittimer=null,!this.state.maximized&&!this.state.minimized)if(this.state.visible){t.startonshow=0,this.stopdrag(),this.stopresize(),t.load&&(t.load=!1,t.images&&($(t.images).off(),t.images=null),this.props.autosizeonimages&&(_uWnd.autosizeonimagesfunc||(_uWnd.autosizeonimagesfunc=function(t){t.data.delaychecksize()}),t.images=$(e).find("img").on("load",this,_uWnd.autosizeonimagesfunc))),t.active=!0,t.speed=1,t.speedmult=this.props.autosizestepmult,this.design.onstartautosz(this),t.timer&&(clearTimeout(t.timer),t.timer=null);var s,i,o,a,n=_uWnd.getdims(),r=10,l=10;this.props.header&&(r+=this._countbuttonwidth()),r=Math.max(r,this.minwidth),l=Math.max(l,this.minheight),0==(s=this.maxwidth)&&(s=n.clientW-this.decor.w),0==(i=this.maxheight)&&(i=n.clientH-this.decor.h),this.props.autosizewidth?($(this.parts.wndcont).css("width","10px"),o=e.scrollWidth,$(this.parts.wndcont).css({width:this.width-this.decor.w+"px"})):o=e.scrollWidth,a=e.scrollHeight+1,t.tw=Math.max(o,r),t.th=Math.max(a,l);var h=!1;t.tw>s&&(t.tw=s,t.th+=this.decor.sbh,h=!0),t.th>i&&(t.th=i,t.tw+this.decor.sbw<=s?h=!0:t.tw=s),h&&this.design.onstopautosz(this,!0),t.timer=setTimeout("try{_uWnd.all["+this.idx+"]._checksize();}catch(e){}",10)}else t.startonshow=1},_checksize:function(){this.stopdrag(),this.stopresize();var t=this.autosz,e=t.tw-(this.width-this.decor.w),s=t.th-(this.height-this.decor.h),i=this.props.autosizestep*t.speed,o=this.props.autosizestep*t.speed;if(i<=0&&(i=1),o<=0&&(o=1),t.speed*=t.speedmult,t.speedmult*=this.props.autosizestepmultmult,0!=e)e>0?i=Math.min(i,e):e<0&&(i=Math.max(-i,e)),2==this.props.autosizewidth&&0!=s?s>0?o=Math.min(o,s):s<0&&(o=Math.max(-o,s)):o=0,this.resizeTo(this.width+i,this.height+o,!0,1);else{if(0==s)return t.timer=null,t.active=!1,void this.design.onstopautosz(this);s>0?o=Math.min(o,s):s<0&&(o=Math.max(-o,s)),this.resizeTo(this.width,this.height+o,!0,1)}t.timer=setTimeout("try{_uWnd.all["+this.idx+"]._checksize();}catch(e){}",10)},closeevent:function(){this.props.onbeforeclose&&this.props.onbeforeclose.apply(this.app,[this])||this.close()},close:function(t){if(!this.state.destroyed){this.state.pendingdestroy&&(t=1);for(var e=0,s=0;s<this.childs.length;s++){var i=this.childs[s];if(i)if(i.state.destroyed)delete this.childs[s];else{if(this.state.pendingdestroy){e=1;break}i.close(),this.childs[s]&&(e=1)}}if(this.state.pendingdestroy=!0,this.xmlobj&&(this.xmlobj_ignoreabort=1,this.xmlobj.abort(),this.xmlobj=null),this.props.modal&&this.props.parent&&this.props.parent.disable(0),!t&&this.state.visible)if(1==this.hide(this.props.fadeclosetype,this.props.fadeclosespeed,!0))return;e||this._destroy()}},_destroy:function(){this.state.destroyed||(this._focus.destroy(),this.desktop&&this.desktop._removewindow(this),this.menu&&this.menu.destroy(),this.traymenu&&this.traymenu.destroy(),this.trayicon&&this.trayicon.remove(),this.top.parentNode.removeChild(this.top),this.grid&&this.grid.parentNode.removeChild(this.grid),this.tabctrl&&!this.props.notabdestroy&&this.tabctrl.destroy(),_uWnd.all[this.idx]=null,this.state.destroyed=!0,this.state.visible=!1,this.props.onclose&&this.props.onclose.apply(this.app,[this,this.idx]),this.props.parent&&this.props.parent._ondelchild(this),this.app&&this.app._ondestroywnd&&this.app._ondestroywnd(this))},_onnewchild:function(t){t&&this.childs.push(t);var e=0;this._foreachchild(function(t){e++}),this.nchilds=e,this.props.parent&&this.props.parent._onnewchild(null)},_ondelchild:function(t){for(var e=0,s=0;s<this.childs.length;s++)if(this.childs[s])if(this.childs[s]==t){if(delete this.childs[s],t.props.parent=null,!this.state.pendingdestroy)break}else e++;this.state.pendingdestroy&&0==e?this._destroy():this._onnewchild(null)}
1,minimize:function(frominit){with(this){if(state.destroyed||autosz.active||!props.min&&(!frominit||"min"!=props.initstate)||!props.header||props.modal||props.alert||props.popup)return;state.beforemin=state.maximized?"max":"",stopdrag(),stopresize(),state.maximized||state.minimized||(restRect=[xpos,ypos,width,height,props.fixed]),frominit||(sesupdate=1),props.onposchange&&!state.minimized&&props.onposchange.apply(app,[this]),state.maximized=!1,state.minimized=!0,this._foreachchild(function(t){if(t.props.min)return 1;t.state.prevvisible=t.state.visible,t.hide(0)},0),ontaskbar?frominit||(hide(0),props.notaskbar||desktop._onwndminimize(this,xpos,ypos,width,height)):(props.min&&($(parts.mbut).css("display","none"),$(parts.rbut).css("display","block")),props.max&&$(parts.xbut).css("display","block"),$(wnd).removeClass("xw-resize"),!props.fixed&&havefixed&&$(top).css("position","fixed"),design.onminimize(this),props.fixed=!0,desktop?moveTo(desktop.calcexclude(0),desktop.calcexclude(2),1):moveTo(0,0,1),resizeTo(200,30,0,1),_focus.isactive()&&(_focus.deactivate(),frominit||_uWnd.activatetopwnd(desktop)))}},maximize:function(act,frominit){with(this){if(state.destroyed||autosz.active||!props.max&&(!frominit||"max"!=props.initstate)&&(!state.minimized||"max"!=state.beforemin)||!props.header)return;if(stopdrag(),stopresize(),state.maximized||state.minimized||(restRect=[xpos,ypos,width,height,props.fixed]),frominit||(sesupdate=1),props.onposchange&&!state.maximized&&props.onposchange.apply(app,[this]),$(parts.hdr).removeClass("xw-draggable"),$(wnd).removeClass("xw-resize"),props.max&&($(parts.xbut).css("display","none"),$(parts.rbut).css("display","block")),props.min&&$(parts.mbut).css("display","block"),desktop||props.fixed||!havefixed||$(top).css("position","fixed"),desktop&&!props.fixed)moveTo(desktop.calcexclude(0),desktop.calcexclude(2),1),resizeTo(desktop.calcwidth(),desktop.calcheight(),0,1);else{var d=_uWnd.getdims();props.fixed=!0,moveTo(0,0,1),resizeTo(d.clientW,d.clientH,0,1)}state.minimized?ontaskbar?show(!1,0):this.design.onrestore(this):frominit&&show(!1,0),state.maximized=!0,state.minimized=!1,_foreachchild(function(t){if(t.props.min)return 1;t.state.prevvisible&&t.show(0,0)},0),act&&activate()}},restore:function(act){with(this){if(state.destroyed||!props.header)return;stopdrag(),stopresize(),sesupdate=1,this.props.onposchange&&(state.minimized||state.maximized)&&props.onposchange.apply(app,[this]),$(parts.rbut).css("display","none"),props.max&&$(parts.xbut).css("display","block"),state.minimized&&props.min&&$(parts.mbut).css("display","block"),props.nomove||$(parts.hdr).addClass("xw-draggable"),props.resize&&$(wnd).addClass("xw-resize"),state.minimized&&(ontaskbar?show(!1,0):this.design.onrestore(this)),state.maximized=state.minimized=!1;var r=restRect;r&&(props.fixed=r[4],!props.fixed&&havefixed&&$(top).css("position","absolute"),moveTo(r[0],r[1],1),resizeTo(r[2],r[3],0,1)),_foreachchild(function(t){if(t.props.min)return 1;t.state.prevvisible&&t.show(0,0)},0),act&&activate()}},_ondragmousemove:function(t,e,s,i){var o=_uWnd.getdims();i+=e,(s+=t)+this.width<30&&(s=30-this.width),i<-5&&(i=-5),this.desktop&&!this.props.fixed?(s>this.desktop.width-20&&(s=this.desktop.width-20),i>this.desktop.height-20&&(i=this.desktop.height-20)):this.props.fixed?(s>o.clientW-20&&(s=o.clientW-20),i>o.clientH-20&&(i=o.clientH-20)):(s>o.docW-20&&(s=o.docW-20),i>o.docH-20&&(i=o.docH-20)),this.moveTo(s,i)},onstartdrag:function(){this.design.onstartdrag(this)},onstopdrag:function(){this.design.onstopdrag(this)},_ondragmousedown:function(e){with(this){if(3==e.which&&"undefined"==typeof _uDesk)return;if(1==e.which&&e.ctrlKey&&(e.which=3),this.props.havesysmenu&&3==e.which&&!state.resizing&&!state.disabled&&!props.toolwindow)return void this.showsysmenu(e.pageX,e.pageY);if(props.nomove||state.resizing||state.maximized||state.disabled||1!=e.which)return;_drag.start(e,xpos,ypos),props.x=xpos,props.y=ypos}},stopdrag:function(){this._drag.stop()},_onrsmousemove:function(t,e,s,i,o,a,n){var r,l,h,d,u,p,c=_uWnd.getdims(),m=10,f=10;r=s,l=i,h=o,d=a,this.props.header&&(m+=this._countbuttonwidth()),m=Math.max(m,this.minwidth)+this.decor.w,f=Math.max(f,this.minheight)+this.decor.h,0==(u=this.maxwidth)?u=c.clientW:u+=this.decor.w,0==(p=this.maxheight)?p=c.clientH:p+=this.decor.h,n.indexOf("n")>=0&&((l=i+e)<0&&(l=0),(d=i+a-l)<f?l=i+a-(d=f):d>p&&(l=i+a-(d=p))),n.indexOf("s")>=0&&((d=a+e)<f?d=f:d>p&&(d=p)),n.indexOf("w")>=0&&((r=s+t)<0&&(r=0),(h=s+o-r)<m?r=s+o-(h=m):h>u&&(r=s+o-(h=u))),n.indexOf("e")>=0&&((h=o+t)<m?h=m:h>u&&(h=u)),this.moveTo(r,l),this.resizeTo(h,d)},_onrsmousedown:function(e,b){with(this){if(_drag.active||state.disabled||state.maximized||state.minimized||autosz.active||!props.resize||1!=e.which)return;props.x=xpos,props.y=ypos,this.stopautosize(),_resize.start(e,xpos,ypos,width,height,b)}},onstartrs:function(){this.design.onstartresize(this)},onstoprs:function(){this.design.onstopresize(this)},stopresize:function(){this._resize.stop()}};{const RELOAD_BUDGET=2,RELOAD_WINDOW_MS=6e4,RELOAD_MIN_INTERVAL_MS=5e3,RELOAD_STORE_KEY="uwnd:reload-guard",LOG_FORM_COOLDOWN_MS=1e4;let reloadSettled=!1,logFormShownAt=0;const readStatus=t=>{try{return Number(t&&t.status)||0}catch(t){return 0}},claimReload=()=>{const t=Date.now();let e=[];try{const s=JSON.parse(sessionStorage.getItem(RELOAD_STORE_KEY));Array.isArray(s)&&(e=s.filter(e=>Number.isFinite(e)&&t-e>=0&&t-e<RELOAD_WINDOW_MS))}catch(t){}if(e.length>=RELOAD_BUDGET)return!1;if(e.length&&t-e[e.length-1]<RELOAD_MIN_INTERVAL_MS)return!1;try{sessionStorage.setItem(RELOAD_STORE_KEY,JSON.stringify(e.concat(t)))}catch(t){}return!0};window._defAjaxError=function(t,e,s){if(this.tabctrl&&_uTabCtrl.all[this.tabctrl]?_uTab
1Ctrl.all[this.tabctrl]._onerror(this.tabid,t,e,s,this):this.wnd&&_uWnd.all[this.wnd]&&_uWnd.all[this.wnd]._onerror(t,e,s,this),"abort"===e||"aborted"===e)return;const i=readStatus(t);if("function"==typeof _show_log_form&&!this.nologform&&0!==i){const t=Date.now();if(t-logFormShownAt>LOG_FORM_COOLDOWN_MS){logFormShownAt=t;try{_show_log_form()}catch(t){}}return}this.tabctrl||this.wnd||("parsererror"!==e||0===i||i>=400?console.warn(`[uwnd/ajax] no reload for HTTP ${i} (${e})`,this.url):reloadSettled||(reloadSettled=!0,claimReload()?window.location.reload():console.warn("[uwnd/ajax] reload budget spent, staying on the page",this.url)))}}var _hookAjaxError=null;function _uAjaxRequest(t,e={}){if(!t)return null;var s=Object.assign({success:_defAjaxSuccess,error:_defAjaxError,async:1,cache:!0,dataType:"xml",type:"GET",timeout:25e3},e);return s.app&&s.app.appname&&s.app.pid>0&&(s.app=s.app.pid),s.wnd&&s.wnd.constructor==_uWnd&&(s.wnd=s.wnd.idx),s.tabctrl&&s.tabctrl.constructor==_uTabCtrl&&(s.tabctrl=s.tabctrl.idx),s.data||(s.data={}),s.data._tp_=s.dataType,s.app>0&&(s.data._ai=s.app),s.app>0&&_uApp.all[s.app]&&_uApp.all[s.app]._admpasscook&&(s.data._apc=_uApp.all[s.app]._admpasscook),s.wnd>0&&(s.data._wi=s.wnd),s.tabctrl>0&&s.tabid&&(s.data._tci=s.tabctrl,s.data._ti=s.tabid),_hookAjaxError&&!s.noerrorhook&&(s.prev_error=s.error,s.error=_hookAjaxError),s.url=t,s.app>0&&!s.nosuccesshook&&(s.prev_success=s.success,s.success=_hookAjaxSuccess),jQuery.ajax(s)}var _hookAjaxSuccess=function(t,e){this.prev_success&&(this.app>0&&"undefined"!=typeof _uApp&&this.prev_success!=_defAjaxSuccess?_uApp.all[this.app]&&!_uApp.all[this.app].exited&&this.prev_success.call(_uApp.all[this.app],t,e,this):this.prev_success.call(this,t,e))},_defAjaxSuccess=function(t,e){var s=null,i=null,o=null;"xml"==this.dataType&&(this.wnd>0&&_uWnd.all[this.wnd]&&!_uWnd.all[this.wnd].state.destroyed&&(s=_uWnd.all[this.wnd]),this.tabctrl>0&&_uTabCtrl.all[this.tabctrl]&&!_uTabCtrl.all[this.tabctrl].state.destroyed&&(o=_uTabCtrl.all[this.tabctrl]),this.app>0&&"undefined"!=typeof _uApp&&_uApp.all[this.app]&&!_uApp.all[this.app].exited&&(i=_uApp.all[this.app]),o?_uParseXML(t,o,this.tabid,i):_uParseXML(t,s,0,i))},_defAjaxFormError=function(t,e,s){if(this.tabctrl&&_uTabCtrl.all[this.tabctrl]?_uTabCtrl.all[this.tabctrl]._onerror(this.tabid,t,e,s,this):_uWnd.all[this.wnd]?._onerror(t,e,s,this),this._formobj){var i=this._formobj.onerror||this._formobj.getAttribute("onerror");if(i){if("string"==typeof i)try{i=new Function(i)}catch(t){return}if("function"==typeof i||"object"==typeof i)try{i.call(this._formobj,t,e,s,this)}catch(t){return}}}},_defAjaxFormComplete=function(t,e){if(this._formobj){var s=this._formobj.oncomplete||this._formobj.getAttribute("oncomplete");if(s){if("string"==typeof s)try{s=new Function(s)}catch(t){return}if("function"==typeof s||"object"==typeof s)try{s.call(this._formobj,t,e)}catch(t){return}}}};function _uPostForm(t,e={}){if(!t&&e&&e.url)return void _uAjaxRequest(e.url,e);let s;if(s="object"!=typeof t?$("#"+t):$(t),!s.length)return;let i=Object.assign({success:_defAjaxSuccess,error:_defAjaxFormError,complete:_defAjaxFormComplete,url:s.attr("action")||window.location.toString(),type:s.attr("method")||"GET",dataType:"xml",semantic:!1,data:{}},e);i.app&&i.app.appname&&i.app.pid>0&&(i.app=i.app.pid),!i.wnd||i.wnd.constructor!=_uWnd&&i.wnd.constructor!=_uFocus||(i.wnd=(i.wnd.owner?i.wnd.owner.idx:i.wnd.idx)||null),i.tabctrl&&i.tabctrl.constructor==_uTabCtrl&&(i.tabctrl=i.tabctrl.idx),i.data._tp_=i.dataType,i.app>0&&(i.data._ai=i.app),i.app>0&&_uApp.all[i.app]&&_uApp.all[i.app]._admpasscook&&(i.data._apc=_uApp.all[i.app]._admpasscook),i.wnd>0&&(i.data._wi=i.wnd),i.tabctrl>0&&i.tabid&&(i.data._tci=i.tabctrl,i.data._ti=i.tabid),_hookAjaxError&&!i.noerrorhook&&(i.prev_error=i.error,i.error=_hookAjaxError),i._formobj=s[0],i.app>0&&!i.nosuccesshook&&(i.prev_success=i.success,i.success=_hookAjaxSuccess),s.ajaxSubmit(i)}function _uAjaxQueue(t){this.idx=_uAjaxQueue.nextidx++,_uAjaxQueue.all[this.idx]=this,this.props=$.extend({maxsize:10,replacelast:0,onfirst:null,onbefore:null,onafter:null,onlast:null,param:null,thispar:null},t||{}),this.queue=[],this.head=0,this.inprogress=0,this.curXML=null}function includeJSfile(t,e){if(!e||!document.getElementById(e)){var s=document.createElement("script");s.src=t,e&&(s.id=e),document.head&&document.head.insertAdjacentElement("beforeEnd",s)}}_uAjaxQueue.all=[],_uAjaxQueue.nextidx=1,_uAjaxQueue.oncomplete=function(t,e){if(this.prev_complete_queue)try{this.prev_complete_queue(t,e)}catch(t){}setTimeout("var _uaq=_uAjaxQueue.all["+this.uajaxqueue+"]; if (_uaq)_uaq._oncomplete(0,'"+e+"');",100)},_uAjaxQueue.prototype={add:function(t,e){if(!t||!t.url)return-1;if(this.queue.length-this.head>=this.props.maxsize){if(!this.props.replacelast||this.props.maxsize<2)return 0;this.queue.splice(this.queue.length-1,1)}var s=$.extend({},t);return s.prev_complete_queue=s.complete,s.complete=_uAjaxQueue.oncomplete,s.uajaxqueue=this.idx,this.queue[this.queue.length]=s,e||this.start(),1},start:function(){this.inprogress||this.head>=this.queue.length||(this.inprogress=1,this.props.onfirst&&this.props.onfirst.call(this.props.thispar,this.props.param,this.queue[this.head],this),this.head--,this._oncomplete(1))},_oncomplete:function(t,e){if(this.inprogress){if(this.curXML=null,this.head++,!t&&this.props.onafter&&this.props.onafter.call(this.props.thispar,this.props.param,this.queue[this.head-1],this,e),this.head>=this.queue.length)return this.props.onlast&&this.props.onlast.call(this.props.thispar,this.props.param,this.queue[this.head-1],this,e),void this.stop();this.props.onbefore&&this.props.onbefore.call(this.props.thispar,this.props.param,this.queue[this.head],this);try{this.curXML=_uAjaxRequest(this.queue[this.head].url,this.queue[this.head]),this.curXML||_uAjaxQueue.oncomplete.call(this.queue[this.head],null,"error")}catch(t){_uAjaxQueue.oncomplete.call(this.queue[this.head],null,"error")}}},stop:function(){if(this.inprogress){if(this.curXML)try{this.curXML.abort()}catch(t){}this.curXML=null,this.queue.splice(0,this.queue.length),this.head=0,this.inprogress=0}},depth:function(){return this.inprogress?this.queue.length-this.head:0}};var _entrRm={};function _entrRem(t,e,s,i){i||(i="Are you sure?"),!_entrRm[t]&&confirm(i)&&(_entrRm[t]=1,document.getElementById(t).src=s+"/img/fr/EmnAjax.gif",_uPostForm("",{url:e}))}function _coloredTDs(t,e){}function openLayerB(t,e,s,i,o,a,n,r,l,h,d){new _uWnd(t,i,o,a,{autosize:n?1:0,modal:l?1:0,align:d||"center"},{url:s,form:e,cache:1})}function _showOnTop(t,e){var s=_uWnd.getTopZ();e?document.getElementById(t).style.zIndex=s+1:document.getElementById("outLayer"+t).style.zIndex=s+1}function encodeJS(t){return String(t).replace(/\\/g,"\\\\").replace(/\r/g,"").replace(/\n/g,"\\n").replace(/'/g,"\\'").replace(/"/g,'\\"')}function shrinkSpaces(t){return String(t).replace(/\t/g," ").replace(/^(\s+)|(\s+)$/g,"").replace(/\s{2,}/g," ")}function encodeHtmlVal(t,e){return e?String(t).replace(/'/g,"&#39;").replace(/"/g,"&quot;"):String(t).replace(/&/g,"&amp;").replace(/'/g,"&#39;").replace(/"/g,"&quot;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}function _uLoadJS(t,e,s){if("string"!=typeof t&&"number"!=typeof t)return 0;"function"==typeof e&&(e={func:e});var i=_uLoadJS._loadedJS[t];if("object"==typeof i){if(2==i[0])return s?2:(e&&e.func.call(e.thispar,"success",e.param),1);if(1==i[0])return e&&(i[i.length]=e),1;e&&(i[i.length]=e)}
1else i=[1],e&&(i[1]=e),_uLoadJS._loadedJS[t]=i;var o={url:t,oldurl:t,dataType:"script",cache:1,complete:_uLoadJS._onloadJS};$.ajax(o)}function _uLoadCSS(t){if(t&&t.length){var e="";if(t.constructor==Array)for(var s=t.length-1;s>=0;s--)/^https?:/.test(t[s])||(t[s]=location.protocol+"//"+location.host+t[s]),t[s]in _uLoadCSS._loadedCSS||(e+='<link rel="stylesheet" type="text/css" href="'+t[s]+'" media="all" />',_uLoadCSS._loadedCSS[t[s]]=[0]);else{if(/^https?:/.test(t)||(t=location.protocol+"//"+location.host+t),t in _uLoadCSS._loadedCSS)return;e='<link rel="stylesheet" type="text/css" href="'+t+'" media="all" />',_uLoadCSS._loadedCSS[t]=[0]}e.length>0&&$("head").append(e)}}function _uLoadCSSSync(t,e,s){if("string"!=typeof t&&"number"!=typeof t)return 0;"function"==typeof e&&(e={func:e});var i=_uLoadCSS._loadedCSS[t];if("object"==typeof i){if(2==i[0])return s?2:(e&&e.func.call(e.thispar,"success",e.param),1);if(1==i[0])return e&&(i[i.length]=e),1;e&&(i[i.length]=e)}else i=[1],e&&(i[1]=e),_uLoadCSS._loadedCSS[t]=i;var o={url:t,oldurl:t,dataType:"text",cache:1,success:_uLoadCSSSync._onload,error:_uLoadCSSSync._onloaderr};$.ajax(o)}function _uLoadFiles(t,e,s){if(t?"string"==typeof t&&(t=[t]):t=[],e?"string"==typeof e&&(e=[e]):e=[],t.constructor!=Array||e.constructor!=Array||0==t.length&&0==e.length)return 0;"function"==typeof s&&(s={func:s});var i,o={numleft:t.length+e.length,notify:s};for(i=0;i<t.length;i++)_uLoadJS(t[i],{thispar:o,func:_uLoadFiles._onload});for(i=0;i<e.length;i++)_uLoadCSSSync(e[i],{thispar:o,func:_uLoadFiles._onload});return 1}function dumpObject(t,e,s){var i,o=typeof t;function a(t,e){var s,i=[0,1,2,3,4,5,6,7,8,9,"a","b","c","d","e","f"],o="";for(s=0;s<e;s++)o=""+i[t%16]+o,t>>>=4;return o}switch(arguments.length<2&&(e=10),"object"==o&&(t?t.constructor==String?o="string":t.constructor==Number?o="number":t.constructor==Boolean?o="boolean":t.constructor==Array&&(o="array"):o="null"),o){case"number":case"boolean":case"null":case"undefined":return String(t);case"string":return'"'+t.replace(/([\\"])/g,"\\$1").replace(/\n/g,"\\n").replace(/([\x00-\x1f])/g,function(t,e){return"\\x"+a(e.charCodeAt(0),2)}).replace(/([\u2028\u2029])/g,function(t,e){return"\\u"+a(e.charCodeAt(0),4)})+'"';case"array":if(e<=0)return"[?]";i="";for(var n=0;n<t.length;n++)n>0&&(i+=","),i+=dumpObject(t[n]);return"["+i+"]";case"object":if(e<=0)return"{?}";
1for(var n in i="",t)if(!s||!s[n]){i&&(i+=",");try{i+=dumpObject(n)+":"+dumpObject(t[n],e-1)}catch(t){i+=dumpObject(n)+":?"}}return"{"+i+"}"}}function _uHighlightA(t,e,s){var i=$(t).find("a").get(),o=null,a=0;for(var n in i)i[n].href&&e.indexOf(i[n].href)>=0&&(!o||a<i[n].href.length)&&(o=i[n],a=i[n].href.length);o&&$(o).addClass(s)}function _uBuildMenu(t,e,s,i,o,a){var n,r,l,h,d,u,p,c;if(n=$(t)[0]){for(a=a||2e3,c=function(t){_uMENU.hideallmenus(),this.__umenu.show()},$.browser&&$.browser.msie&&(n.style.zoom="1"),l=$(t+">ul").children("li").children("ul"),r=0;r<l.length;r++)h=_ubuild_submenus(l[r]),d=p=l[r].parentNode,!e&&o&&(u=$(d).children("."+o)[0])&&(d=u),p.__umenu=new _uMENU("",{alignObj:d,align:e?"D":window._rtl?"L":"R"},{parentnode:n,hidetimer:a},h),$(p).on("mouseover",c),p.removeChild(l[r]);s&&i&&setTimeout("_uHighlightA($('"+t+"')[0],'"+s+"','"+i+"');",100)}}function _uReplaceMenu(t,e,s,i,o){var a,n,r;(a=$(t)[0])&&($.browser&&$.browser.msie&&(a.style.zoom="1"),(r=$(t).children("ul")[0])&&(o&&$(r).find("."+o).remove(),n=_ubuild_submenus(r),r.parentNode.__umenu=new _uMENU("",{},{width:"auto",horiz:e,statical:1,parentnode:a,noabs:1},n),r.parentNode.removeChild(r),s&&i&&setTimeout("_uHighlightA($('"+t+"')[0],'"+s+"','"+i+"');",100)))}function _ubuild_submenus(t){var e,s,i,o,a=$(t).children("li"),n=[];for(e=0;e<a.length;e++)(s=$(a[e]).children("ul")[0])?(i=_ubuild_submenus(s),s.parentNode.removeChild(s),o=$(a[e]).find("a").get(),n[n.length]=[$(a[e]).html(),i,o.length>0?{action:"a"}:null]):(o=$(a[e]).find("a").get(),n[n.length]=[$(a[e]).html(),o.length>0?"a":""]);return n}function uSetCookie(t){var e=encodeURIComponent(t.name);if(t.value?e+="="+encodeURIComponent(t.value):e+="=",t.days){let s=new Date;s.setDate(s.getDate()+t.days),e+=";expires="+s.toUTCString()}t.path&&(e+=";path="+t.path),t.domain&&(e+=";domain="+t.domain),document.cookie=e}function _uButton(t,e,s){let i=Object.assign({ext:0,text:"Ok",content:"s"===e?'onclick="this.disabled = this.form.checkValidity();this.form.requestSubmit();return false;"':"",style:0,buttonId:t?`id="subbut${t}"`:"",type:`type="${{s:"submit",r:"reset",b:"button"}[e]||"button"}"`,classList:[]},s);return 1===i.style&&i.classList.push("light-btn"),i.class=`class="ubtn-default ${i.classList.join(" ")}"`,`<button ${i.buttonId} ${i.class} ${i.type} ${i.content}>${i.text}</button>`}function _uButtonEn(t,e){return t instanceof Array||t instanceof NodeList?_uButtonArraySwitch(t,e):t&&t.nodeType?t.disabled=!e:void("string"==typeof t&&_uButtonStringSwitch(t,e))}function _uButtonStringSwitch(t,e){let s=/^subbut/.test(t)?t:`subbut${t}`,i=window[s]||document.getElementById(s);i&&(i.disabled=!e)}function _uButtonArraySwitch(t,e){t.forEach(t=>{const s="string"==typeof t?document.getElementById(/^subbut/.test(t)?t:`subbut${t}`):t;s&&(s.disabled=!e)})}function _uTransStr(t){var e,s,i,o,a,n,r=1,l=_uTransStr._table;if(!l)for(_uTransStr.append(_uTransStr._deftable),_uTransStr._deftable=null,l=_uTransStr._table,e=0;e<128;e++)l[e]=_uTransStr._separators[e]?" ":String.fromCharCode(e);if(null==t)return this.value="",this.length=0,this.translit="",void(this.transprops=[]);for(this.value="string"==typeof t?t:String(t),t=this.value.toLowerCase(),i=this.length=t.length,o="",a=[],e=0;e<i;e++)if(" "!=(s=l[t.charCodeAt(e)]))if(r=0,null==s)a[o.length]=e<<1,o+=t.charAt(e);else{if(1==s.length)a[o.length]=e<<1;else for(n=s.length;n>0;)a[o.length+n-1]=1+(e<<1),n--;o+=s}else r||(a[o.length]=e<<1,o+=" ",r=1);r&&o.length>0?(this.translit=o.substr(0,o.length-1),a.length=o.length-1):this.translit=o,this.transprops=a}Date.fullYearStart="20",function(){function t(t,e){Date.prototype[t]||(Date.prototype[t]=e)}t("isLeapYear",function(){var t=this.getFullYear();return t%4==0&&t%100!=0||t%400==0}),t("isWeekend",function(){return 0==this.getDay()||6==this.getDay()}),t("isWeekDay",function(){return!this.isWeekend()}),t("getDaysInMonth",function(){return[31,this.isLeapYear()?29:28,31,30,31,30,31,31,30,31,30,31][this.getMonth()]}),t("getDayName",function(t){return t?Date.abbrDayNames[this.getDay()]:Date.dayNames[this.getDay()]}),t("getMonthName",function(t){return t&&2!=t?Date.abbrMonthNames[this.getMonth()]:2==t?Date.rMonthNames[this.getMonth()]:Date.monthNames[this.getMonth()]}),t("getDayOfYear",function(){var t=new Date("1/1/"+this.getFullYear());return Math.floor((this.getTime()-t.getTime())/864e5)}),t("getWeekOfYear",function(){return Math.ceil(this.getDayOfYear()/7)}),t("setDayOfYear",function(t){return this.setMonth(0),this.setDate(t),this}),t("addYears",function(t){return this.setFullYear(this.getFullYear()+t),this}),t("addMonths",function(t){var e=this.getDate();return this.setMonth(this.getMonth()+t),e>this.getDate()&&this.addDays(-this.getDate()),this}),t("addDays",function(t){return this.setDate(this.getDate()+t),this}),t("addHours",function(t){return this.setHours(this.getHours()+t),this}),t("addMinutes",function(t){return this.setMinutes(this.getMinutes()+t),this}),t("addSeconds",function(t){return this.setSeconds(this.getSeconds()+t),this}),t("zeroTime",function(){return this.setMilliseconds(0),this.setSeconds(0),this.setMinutes(0),this.setHours(0),this});var e=function(t){return t.match(/\$[a-zA-Z]+\$/)?t:t.replace(/yyyy/g,"$yyyy$").replace(/yy/g,"$yy$").replace(/mmmm/g,"$MO$").replace(/mmm/g,"$Mo$").replace(/mm/g,"$mo$").replace(/dd/g,"$dd$")};t("asString",function(t,i){var o,a=null,n=null,r="";if(!1!==t&&(a=t||Date.udateformat),i&&(n=1==i||!0===i?Date.utimeformat:i),a&&(a=e(a),o={yyyy:this.getFullYear(),yy:(this.getFullYear()+"").substring(2),MO:this.getMonthName(0),Mo:this.getMonthName(1),MOD:this.getMonthName(2),WD:this.getDayName(0),wd:this.getDayName(1),mo:s(this.getMonth()+1),d:this.getDate(),dd:s(this.getDate())},r+=a.replace(/\$([a-zA-Z]+)\$/g,function(t,e){return o[e]})),n){r&&(r+=" ");var l=this.getHours(),h="AM";l>12?(l-=12,h="PM"):12==l&&(h="PM"),o={H:this.getHours(),HH:s(this.getHours()),h:l,hh:s(l),AP:h,mm:s(this.getMinutes()),ss:s(this.getSeconds())},r+=n.replace(/\$([a-zA-Z]+)\$/g,function(t,e){return o[e]})}return r}),Date.fromString=function(t,s,i,o){var a,n,r,l,h,d,u,p,c=o||e(Date.udateformat),m=Date.utimeformat;for(i&&(!0!==i&&1!==i&&(m=i),c+=" "+m),t=t.replace(/[\x00-\x1f]+/g," "),h={yyyy:"(\\d{4}|\\d{2})",yy:"(\\d{2}|\\d{4})",MO:'([^ 0-9@"#$%^&*(){}\\[\\]+=_\\\\|;:/?.>,<~\\-]+)',Mo:'([^ 0-9@"#$%^&*(){}\\[\\]+=_\\\\|;:/?.>,<~\\-]+)',MOD:'([^0-9@"#$%^&*(){}\\[\\]+=_\\\\|;:/?.>,<~\\-]+)',mo:"(\\d{1,2})",dd:"(\\d{1,2})",d:"(\\d{1,2})",HH:"(\\d{1,2})",hh:"(\\d{1,2})",H:"(\\d{1,2})",h:"(\\d{1,2})",AP:"(AM|PM)?",mm:"(\\d{1,2})",ss:"(\\d{1,2})?"},a=new RegExp("\\$([a-zA-Z]+)\\$","g"),n=0,l="^",s||(l+=" *"),d=[];r=a.exec(c);)r.index>n&&(l+=s?c.substr(n,r.index-n).replace(/([\\^\$*+?.|()\[\]{}])/g,"\\$1"):'[ @"#$%^&*(){}\\[\\]+=_\\\\|;:/?.>,<~\\-]+'),n=r.index+r[0].length,h[r[1]]?(l+=h[r[1]],d.push(r[1])):n=r.index;if(c.length>n&&(l+=s?c.substr(n,c.length-n).replace(/([\\^\$*+?.|()\[\]{}])/g,"\\$1"):'[ @"#$%^&*(){}\\[\\]+=_\\\\|;:/?.>,<~\\-]+'),s||(l+=" *"),l+="$",!(r=(l=new RegExp(l,"i")).exec(t)))return!1;(u=new Date).zeroTime();for(var f=u.getDate(),_=u.getMonth(),b=u.getFullYear(),g=0;g<d.length;g++)if("yyyy"==d[g]||"yy"==d[g]){if(p=parseInt(r[g+1],10),isNaN(p)||p<0)return!1;p<30?p+=2e3:p<100&&(p+=1900),b=p}else if("MO"==d[g]||"MOD"==d[g]||"Mo"==d[g]){for(p=0;p<12;p++)if(Date.abbrMonthNames[p].indexOf(r[g+1])>=0){_=p;break}if(p>=12)for(p=0;p<12;p++)if(Date.rMonthNames[p].indexOf(r[g+1])>=0){_=p;break}if(p>=12)for(p=0;p<12;p++)if(Date.monthNames[p].indexOf(r[g+1])>=0){_=p;break}if(p>=12)return!1}else if("mo"==d[g]){if(p=parseInt(r[g+1],10),isNaN(p)||p<=0||p>12)return!1;_=p-1}else if("dd"==d[g]||"d"==d[g]){if(p=parseInt(r[g+1],10),isNaN(p)||p<=0||p>31)return!1;f=p}else if("HH"==d[g]||"H"==d[g]){if(p=parseInt(r[g+1],10),isNaN(p)||p<0||p>24)return!1;u.setHours(p)}else if("hh"==d[g]||"h"==d[g]){if(p=parseInt(r[g+1],10),isNaN(p)||p<0||p>12)return!1;u.setHours(p)}else if("mm"==d[g]){if(p=parseInt(r[g+1],10),isNaN(p)||p<0||p>59)return!1;u.setMinutes(p)}
1else if("ss"==d[g]){if(p=r[g+1]&&r[g+1].length>0?parseInt(r[g+1],10):0,isNaN(p)||p<0||p>61)return!1;u.setSeconds(p)}else if("AP"==d[g]&&r[g+1]&&r[g+1].length>0)if("pm"==r[g+1].toLowerCase())u.getHours()<12&&u.addHours(12);else if("am"!=r[g+1].toLowerCase())return!1;return u.setFullYear(b),u.setMonth(_,f),u};var s=function(t){var e="0"+t;return e.substring(e.length-2)}}(),_uLoadJS._loadedJS={},_uLoadJS._onloadJS=function(t,e){var s=_uLoadJS._loadedJS[this.oldurl];s[0]="success"!=e?0:2;for(var i=1;i<s.length;i++)s[i]&&s[i].func&&s[i].func.call(s[i].thispar,e,s[i].param);s.splice(1,s.length-1)},_uLoadCSS._loadedCSS={},_uLoadCSSSync._onload=function(t,e){$("head").append('<style type="text/css" ufromurl="'+this.oldurl+'">'+t+"</style>");var s=_uLoadCSS._loadedCSS[this.oldurl];0==s[0]&&$("link[rel=stylesheet][href="+this.oldurl+"]").remove(),s[0]=2;for(var i=1;i<s.length;i++)s[i]&&s[i].func&&s[i].func.call(s[i].thispar,"success",s[i].param);s.splice(1,s.length-1)},_uLoadCSSSync._onloaderr=function(t){var e=_uLoadCSS._loadedCSS[this.oldurl];e[0]=0;for(var s=1;s<e.length;s++)e[s]&&e[s].func&&e[s].func.call(e[s].thispar,"error",e[s].param);e.splice(1,e.length-1)},_uLoadFiles._onload=function(t){this.numleft<=0||("success"!=t?this.numleft=0:this.numleft--,0==this.numleft&&this.notify&&this.notify.func&&this.notify.func.call(this.notify.thispar,t,this.notify.param))},_uTransStr.prototype={toString:function(){return this.value},_offsetprops:function(t){for(var e=this.transprops.length-1;e>=0;e--)this.transprops[e]+=2*t},splitsps:function(t){null==t&&(t=this.translit.length);for(var e,s=[],i=0,o=0;o<t-1&&(e=this.translit.indexOf(" ",i))>=0;)i!=e?(s[o]=new _uTransStr,s[o].translit=this.translit.substring(i,e),s[o].transprops=this.transprops.slice(i,e),s[o]._offsetprops(-(this.transprops[i]>>1)),s[o].value=this.value.substring(this.transprops[i]>>1,this.transprops[e]>>1),s[o].length=s[o].value.length,o++,i=e+1):i++;return(e=this.translit.length)>i&&(s[o]=new _uTransStr,s[o].translit=this.translit.substring(i),s[o].transprops=this.transprops.slice(i),s[o]._offsetprops(-(this.transprops[i]>>1)),s[o].value=this.value.substring(this.transprops[i]>>1),s[o].length=s[o].value.length),s},find:function(t,e,s){t&&t.trasprops&&t.translit||(t=new _uTransStr(t));var i,o=-1,a=t.transprops,n=this.transprops;if(e&&e>0)for(null!=s&&(o=s);o+1<n.length&&n[o+1]>>1<e;)o++;t:for(;;){if((o=this.translit.indexOf(t.translit,o+1))<0)return null;if(i=0,!(o>0&&n[o-1]==n[o])){for(;i<a.length;)if(1&n[o+i]|1&a[i])if(1&n[o+i])if(1&a[i]){for(i++;i<a.length&&a[i]==a[i-1];){if(n[o+i]!=n[o+i-1])continue t;i++}if((i<a.length||o+i<this.translit.length)&&n[o+i]==n[o+i-1])continue t}else{for(i++;i<a.length&&n[o+i]==n[o+i-1];){if(1&a[i])continue t;i++}if(o+i<this.translit.length&&n[o+i]==n[o+i-1])continue t}else for(i++;i<a.length&&a[i]==a[i-1];){if(1&n[o+i])continue t;i++}else i++;break}}return[n[o]>>1,(o+i<this.translit.length?n[o+i]>>1:this.length)-(n[o]>>1),o]}},_uTransStr._table=null,_uTransStr.append=function(t){_uTransStr._table||(_uTransStr._table=[]);for(var e=0;e<t.length;e+=2)_uTransStr._table[t[e].charCodeAt(0)]=t[e+1]},_uTransStr._separators=[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,1,0,1,1,0,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1],_uTransStr._deftable=["à","a","á","a","â","a","ã","a","ä","a","å","a","æ","ae","ç","c","è","e","é","e","ê","e","ë","e","ì","i","í","i","î","i","ï","i","ð","d","ñ","n","ò","o","ó","o","ô","o","õ","o","ö","o","ø","o","ù","u","ú","u","û","u","ü","u","ý","y","þ","th","ÿ","y","ą","a","č","c","đ","d","ę","e","ł","l","ŋ","ng","œ","oe","ş","s","š","s","ž","z","а","a","б","b","в","v","г","g","д","d","е","e","ё","yo","ж","zh","з","z","и","i","й","j","к","k","л","l","м","m","н","n","о","o","п","p","р","r","с","s","т","t","у","u","ф","f","х","kh","ц","ts","ч","ch","ш","sh","щ","shch","ъ","","ы","y","ь","'","э","e","ю","yu","я","ya","є","e","і","i","ї","yi","ґ","g","№","#"];var typeaheadUtil=function(){var t=/[ ]+/g,e=/[^ ]+/g,s=/[^\w ]/g,i=/[-~_\u2010\u2011\u2012\u2013\u2014\u2015]+/g,o=new RegExp("(\\"+["/",".","*","+","?","|","(",")","[","]","{","}","\\"].join("|\\")+")","g"),a={"а":"a","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","б":"b","ц":"c","ç":"c","д":"d","ð":"d","э":"e","е":"e","ё":"e","è":"e","é":"e","ê":"e","ë":"e","ф":"f","г":"g","х":"h","и":"i","ì":"i","í":"i","î":"i","ï":"i","ы":"i","ж":"j","к":"k","л":"l","м":"m","н":"n","ñ":"n","о":"o","ø":"o","ö":"o","õ":"o","ô":"o","ó":"o","ò":"o","п":"p","р":"r","с":"s","т":"t","у":"u","ю":"u","ü":"u","û":"u","ú":"u","ù":"u","в":"v","й":"y","ÿ":"y","ý":"y","з":"z","æ":"ae","œ":"oe","ч":"ch","ш":"sh","щ":"sch","я":"ya"},n=function(e){for(var s="",i="",o=(e=(""+e).toLowerCase()).length;o--;)i=e.charAt(o),s=(a[i]||i)+s;return s.replace(t," ")};return{escape:function(t){return t?t.replace(o,"\\$1"):""},flatten:n,tokenize:function(t){t=t.toLowerCase();var o=n(t),a=function(t){return t?t.replace(s," "):""}
1(o),r=function(t){return t?t.replace(i," "):""}(o);t!=o&&(t+=" "+o),t!=a&&(t+=" "+a),t!=r&&(t+=" "+r);for(var l=[],h={},d=e.exec(t);d;)h[d=d[0]]||(l.push(d),h[d]=!0),d=e.exec(t);return l}}}();function _uOverlay(t="defOverlay",e=.5,s="#000",i=100,o=1){$(`<div id="${t}"></div>`).css({"z-index":o,left:0,top:0,width:"100vw",height:"100vh","background-color":s,position:"fixed",opacity:e}).hide().on("mousedown",function(t){t.stopPropagation(),t.preventDefault(),_uWnd.globalmousedown()}).prependTo(document.body).fadeIn(i)}function _uAudioPlayer(t,e){const s=document.createElement("audio");s.controls="controls",s.controlsList="nodownload";const i=document.createElement("source");i.src=t.url,s.appendChild(i),document.getElementById(e).appendChild(s)}function _uVideoPlayer(t,e,s){var i=$("#"+e)[0];if(i){var o="",a=0,n=0;switch(!0){case!!t.url.match(/youtube\.com|youtu\.be/i):n=a=1,(r=t.url.match(/v=([^\s\&\;\?]+)|be\/([^\s\&\;\?]+)/))&&(r[1]||r[2])&&(o="https://youtube.com/embed/"+(r[1]||r[2])+"?rel=0&showinfo=0&modestbranding=0&theme=light&autohide=1&html5=1");break;case!!t.url.match(/rutube\.ru/i):n=1,(r=t.url.match(/v=([^\s\&\;]+)|\/video\/(.+)\//))&&(r[1]||r[2])&&(o="https://video.rutube.ru/"+(r[1]||r[2]));break;case!!t.url.match(/dailymotion\.com|dai\.ly/i):n=a=1,(r=t.url.match(/video\/(.*?)_|ly\/(.*)$/))&&(r[1]||r[2])&&(o="//dailymotion.com/embed/video/"+(r[1]||r[2]));break;case!!t.url.match(/mail\.ru/i):n=a=1,(r=t.url.match(/\.ru\/(.*?\/)video\/(.*?\.html)/))&&r[1]&&r[2]&&(o="//videoapi.my.mail.ru/videos/embed/"+r[1]+r[2]);break;case!!t.url.match(/vimeo\.com/i):n=1,(r=t.url.match(/\/([\d]+)/))&&r[1]&&(o="https://vimeo.com/moogaloop.swf?clip_id="+r[1]+"&show_title=1&show_byline=0&show_portrait=0&fullscreen=1&autoplay=0");break;case!!t.url.match(/metacafe\.com/i):var r;n=a=1,(r=t.url.match(/watch\/([\d]+.+)/))&&r[1]&&(o="//metacafe.com/embed/"+r[1]);break;case!!t.url.match(/coub\.com/i):n=a=1,o=t.url.replace(/^.+:(\/\/.+\/)view(\/.+)$/,"$1embed$2?muted=false&autostart=false&originalSize=false&startWithHD=false")}var l="";if(o&&o.length>1){var h=t.width?t.width:640,d=t.height?t.height:360;if("object"==typeof swfobject&&swfobject.embedSWF)return void swfobject.embedSWF(o,e,h,d,"10","",{},{allowFullScreen:"true",wmode:"transparent",quality:"high"},{align:"middle"});l=a?'<iframe src="{{src}}" width={{width}} height={{height}} frameborder=0 \t\t\twebkitAllowFullScreen mozallowfullscreen allowfullscreen ></iframe>'.render({src:o,width:h,height:d}):'<object allowfullscreen="true" type="application/x-shockwave-flash" width={{width}} height={{height}} data="{{data}}">\t\t\t\t<param name="movie" value="{{data}}" />\t\t\t\t<param name="wmode" value="transparent">\t\t\t</object>'.render({width:h,height:d,data:o})}else l=n?'<span style="border-bottom:1px dashed red;text-align:center;">Incorrect video URL.</span>':'<span style="border-bottom:1px dashed red;text-align:center;">Not supported video service. Please use YouTube.com for your video files.</span>';$(i).html(l)}else{if(("number"!=typeof s||isNaN(s))&&(s=0),s>=10)return;setTimeout("_uVideoPlayer("+dumpObject(t)+","+dumpObject(e)+","+(s+1)+");",100)}}function _uPageMenu(t,e,s){var i,o=Math.floor(t/e);if(t%e!=0&&o++,o<=1)return{pages:[1],start_idx:0,curpage:1,numpages:o};if((s<=0||s>o)&&(s=1),6!=o){i=[1,2],s-2>3&&i.push(0);for(var a=s-2<=3?3:s-2,n=s+2>=o?o:s+2;a<=n;a++)i.push(a);s+2<o-2&&i.push(0);for(a=s+3>=o-1?s+3:o-1;a<=o;a++)i.push(a)}else i=[1,2,3,4,5,6];return{pages:i,start_idx:(s-1)*e,curpage:s,numpages:o}}function convertSize(t){return t>1073741824?(t/1073741824).toFixed(2)+" Gb":t>1048576?(t/1048576).toFixed(2)+" Mb":(t/1024).toFixed(2)+" Kb"}function isES6(){try{return Function("() => {};"),!0}catch(t){return!1}}function uDebounce(t,e=300){let s;return function(...i){clearTimeout(s),s=setTimeout(()=>t.apply(this,i),e)}}$.fn.imgload=function(t){var e={container:window,holder:"data-path-holder",targets:this,speed:1500};t&&$.extend(e,t),$(e.targets).on("load",function(){$(this).animate({opacity:1},e.speed)}),$(e.container).on("scroll",function(){$(e.targets).each(function(t,s){var i=$(s),o=$(window);i.attr(e.holder)&&(Math.abs(o.scrollTop()+o.height()/2-Math.round(i.offset().top))<o.height()||Math.abs(o.scrollTop()-i.offset().top)<i.height()+10)&&i.css("opacity",0).attr("src",i.attr(e.holder)).removeAttr(e.holder)})}),$(e.container).trigger("scroll")};
1class _uWndToast{_className="cp-alert";constructor({className:t="cp-alert"}){this._config={w:414,h:72,tm:3e3,noscale:1,pad:0,align:"start"},this._className=t}show(t,e,{type:s,topclass:i=[],w:o=this._config.w,h:a,...n}={}){const r=[this._className,...i];s&&r.push(`${this._className}-with-icon`,`${this._className}-${s}`);const l=a||this._measureHeight(t,e,o,r.includes(`${this._className}-with-icon`));return _uWnd.alert(e,t,{...this._config,...n,topclass:r,w:o,h:l})}success(t,e){return this.show(t,e,{type:"success"})}error(t,e){return this.show(t,e,{type:"error",tm:6e3})}warning(t,e){return this.show(t,e,{type:"warning"})}info(t,e){return this.show(t,e,{type:"info"})}_measureHeight(t,e,s,i=!1){const o=document.createElement("div");if(o.className=`${this._className}-measure`,o.style.setProperty("--measure-width",`${s}px`),t){const e=document.createElement("div");e.className="alert-measure-title",e.innerHTML=t,e.classList.toggle("with-icon",i),o.append(e)}if(e){const s=document.createElement("div");s.className="alert-measure-message",e instanceof HTMLElement?s.append(e):s.innerHTML=e,s.classList.toggle("with-title",t),s.classList.toggle("with-icon",i),o.append(s)}document.body.append(o);const a=o.offsetHeight;return o.remove(),a}}window.__IN_PANEL?(window.uCoz??={},window.uCoz.toast=new _uWndToast({className:"cp-alert"})):window.uToast=new _uWndToast({className:"uwnd-toast"});

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.