Skip to Content

JavaScript File

URL: https://catalog.tools/.s/src/uwnd.min.js?v=151233
HTTP Status: 200 OK
MIME Type: text/javascript
Last Modified: Mon, 15 Apr 2024 09:33:31 GMT
Download Time: Less than a second
Cookies: None
Size: 206 KB
HTTP Headers:  7 headers
Links In:  1 pages
Links Out:  0 links
Images:  0 images
CSS:  0 files
JavaScript:  0 files
OK Issues: No issues found

1function _uFocus(t){t||(t={}

2),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||{}

3),this.destroyed=0,_uFocus.globalset||(_uFocus.globalset=!0,$(document).on("keydown keyup keypress",_uFocus._onkey)),2==this._tp&&_uFocus.glisteners.push(this)}

4function _uGetOffset(t){if(!t)return{left:0,top:0}

5;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}

6}

7function _uMenu(t,e,s){this.init(t,e,s)}

8function _uMENU(t,e={}

9,s={}

10,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}

11,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}

12,s),this.state={visible:!1,init:!1,destroyed:!1}

13,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}

14,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}

15);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"}

16);var n=document.createElement("div");a.appendChild(n),this.menu=n,this.havefixed=1,this.props.noabs||($(a).css({position:"absolute",zIndex:this.zpos}

17),$(n).css({position:"absolute",zIndex:2,left:0}

18)),$(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 m=_uMENU.all["+this.idx+"]; if (m)m.init1();",10)}

19function _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}

20,s||{}

21),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()}

22)):this.props.wnd&&$(this.props.wnd.parts.wndcont).on("scroll",this,(function(t){t.data.destroyed||t.data.hidelist()}

23))):(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()}

24))):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}

25this.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");h.id="_ucombolist"+this.idx,this.toplist=h,$(h).css({position:"absolute",zIndex:5,display:"none"}

26),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)}

27)).on("keyup",this,(function(t){return t.data.onkeyup(t)}

28)),$(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=[]}

29function _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}

30,s||{}

31),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)}

32)):this.props.wnd&&$(this.props.wnd.parts.wndcont).on("scroll",this,(function(t){t.data.destroyed||t.data.onblur(null)}

33))):(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)}

34))):(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}

35),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)}

36)).on("blur",this,(function(t){return t.data.onblur(t)}

37)).on("keydown",this,(function(t){return t.data.onkeydown(t)}

38)).on("mousedown",this,(function(t){_uSuggestList.ignoreclick=t.data}

39)).on("keyup",this,(function(t){return t.data.onkeyup(t)}

40)),_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)}

...

</html>