All Downloads are FREE. Search and download functionalities are using the official Maven repository.

ber-security.graylog.graylog-plugin-correlation-count.6.0.0.source-code.bb1365c0983ce5ad50060b24788b9630.js Maven / Gradle / Ivy

There is a newer version: 5.1.3
Show newest version
(()=>{var F=(c,u)=>()=>(u||c((u={exports:{}}).exports,u),u.exports);var j=F((k,T)=>{ace.define("ace/ext/command_bar",["require","exports","module","ace/tooltip","ace/lib/event_emitter","ace/lib/lang","ace/lib/dom","ace/lib/oop","ace/lib/useragent"],function(c,u,R){var P=this&&this.__values||function(o){var t=typeof Symbol=="function"&&Symbol.iterator,e=t&&o[t],i=0;if(e)return e.call(o);if(o&&typeof o.length=="number")return{next:function(){return o&&i>=o.length&&(o=void 0),{value:o&&o[i++],done:!o}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},E=c("../tooltip").Tooltip,A=c("../lib/event_emitter").EventEmitter,C=c("../lib/lang"),f=c("../lib/dom"),N=c("../lib/oop"),O=c("../lib/useragent"),a="command_bar_tooltip_button",_="command_bar_button_value",M="command_bar_button_caption",b="command_bar_keybinding",d="command_bar_tooltip",w="MoreOptionsButton",x=100,D=4,S=function(o,t){return t.row>o.row||t.row===o.row&&t.column>o.column?o:t},$={Ctrl:{mac:"^"},Option:{mac:"\u2325"},Command:{mac:"\u2318"},Cmd:{mac:"\u2318"},Shift:"\u21E7",Left:"\u2190",Right:"\u2192",Up:"\u2191",Down:"\u2193"},L=function(){function o(t,e){var i,l;e=e||{},this.parentNode=t,this.tooltip=new E(this.parentNode),this.moreOptions=new E(this.parentNode),this.maxElementsOnTooltip=e.maxElementsOnTooltip||D,this.$alwaysShow=e.alwaysShow||!1,this.eventListeners={},this.elements={},this.commands={},this.tooltipEl=f.buildDom(["div",{class:d}],this.tooltip.getElement()),this.moreOptionsEl=f.buildDom(["div",{class:d+" tooltip_more_options"}],this.moreOptions.getElement()),this.$showTooltipTimer=C.delayedCall(this.$showTooltip.bind(this),e.showDelay||x),this.$hideTooltipTimer=C.delayedCall(this.$hideTooltip.bind(this),e.hideDelay||x),this.$tooltipEnter=this.$tooltipEnter.bind(this),this.$onMouseMove=this.$onMouseMove.bind(this),this.$onChangeScroll=this.$onChangeScroll.bind(this),this.$onEditorChangeSession=this.$onEditorChangeSession.bind(this),this.$scheduleTooltipForHide=this.$scheduleTooltipForHide.bind(this),this.$preventMouseEvent=this.$preventMouseEvent.bind(this);try{for(var s=P(["mousedown","mouseup","click"]),n=s.next();!n.done;n=s.next()){var r=n.value;this.tooltip.getElement().addEventListener(r,this.$preventMouseEvent),this.moreOptions.getElement().addEventListener(r,this.$preventMouseEvent)}}catch(p){i={error:p}}finally{try{n&&!n.done&&(l=s.return)&&l.call(s)}finally{if(i)throw i.error}}}return o.prototype.registerCommand=function(t,e){var i=Object.keys(this.commands).length=g.top&&n.top<=g.bottom&&n.left>=g.left+t.gutterWidth&&n.left<=g.right;if(!H&&this.isShown()){this.$hideTooltip();return}else if(H&&!this.isShown()&&this.getAlwaysShow()){this.$showTooltip();return}var m=n.top-r.offsetHeight,v=Math.min(p-r.offsetWidth,n.left),I=m>=0&&m+r.offsetHeight<=h&&v>=0&&v+r.offsetWidth<=p;if(!I){this.$hideTooltip();return}if(this.tooltip.setPosition(v,m),this.isMoreOptionsShown()){m=m+r.offsetHeight,v=this.elements[w].getBoundingClientRect().left;var y=this.moreOptions.getElement(),h=window.innerHeight;m+y.offsetHeight>h&&(m-=r.offsetHeight+y.offsetHeight),v+y.offsetWidth>p&&(v=p-y.offsetWidth),this.moreOptions.setPosition(v,m)}}}},o.prototype.update=function(){Object.keys(this.elements).forEach(this.$updateElement.bind(this))},o.prototype.detach=function(){this.tooltip.hide(),this.moreOptions.hide(),this.$updateOnHoverHandlers(!1),this.editor&&(this.editor.off("changeSession",this.$onEditorChangeSession),this.editor.session&&(this.editor.session.off("changeScrollLeft",this.$onChangeScroll),this.editor.session.off("changeScrollTop",this.$onChangeScroll))),this.$mouseInTooltip=!1,this.editor=null},o.prototype.destroy=function(){this.tooltip&&this.moreOptions&&(this.detach(),this.tooltip.destroy(),this.moreOptions.destroy()),this.eventListeners={},this.commands={},this.elements={},this.tooltip=this.moreOptions=this.parentNode=null},o.prototype.$createCommand=function(t,e,i){var l=i?this.tooltipEl:this.moreOptionsEl,s=[],n=e.bindKey;n&&(typeof n=="object"&&(n=O.isMac?n.mac:n.win),n=n.split("|")[0],s=n.split("-"),s=s.map(function(h){if($[h]){if(typeof $[h]=="string")return $[h];if(O.isMac&&$[h].mac)return $[h].mac}return h}));var r;i&&e.iconCssClass?r=["div",{class:["ace_icon_svg",e.iconCssClass].join(" "),"aria-label":e.name+" ("+e.bindKey+")"}]:(r=[["div",{class:_}],["div",{class:M},e.name]],s.length&&r.push(["div",{class:b},s.map(function(h){return["div",h]})])),f.buildDom(["div",{class:[a,e.cssClass||""].join(" "),ref:t},r],l,this.elements),this.commands[t]=e;var p=function(h){this.editor&&this.editor.focus(),this.$shouldHideMoreOptions=this.isMoreOptionsShown(),!this.elements[t].disabled&&e.exec&&e.exec(this.editor),this.$shouldHideMoreOptions&&this.$setMoreOptionsVisibility(!1),this.update(),h.preventDefault()}.bind(this);this.eventListeners[t]=p,this.elements[t].addEventListener("click",p.bind(this)),this.$updateElement(t)},o.prototype.$setMoreOptionsVisibility=function(t){t?(this.moreOptions.setTheme(this.editor.renderer.theme),this.moreOptions.setClassName(d+"_wrapper"),this.moreOptions.show(),this.update(),this.updatePosition()):this.moreOptions.hide()},o.prototype.$onEditorChangeSession=function(t){t.oldSession&&(t.oldSession.off("changeScrollTop",this.$onChangeScroll),t.oldSession.off("changeScrollLeft",this.$onChangeScroll)),this.detach()},o.prototype.$onChangeScroll=function(){this.editor.renderer&&(this.isShown()||this.getAlwaysShow())&&this.editor.renderer.once("afterRender",this.updatePosition.bind(this))},o.prototype.$onMouseMove=function(t){if(!this.$mouseInTooltip){var e=this.editor.getCursorPosition(),i=this.editor.renderer.textToScreenCoordinates(e.row,e.column),l=this.editor.renderer.lineHeight,s=t.clientY>=i.pageY&&t.clientY




© 2015 - 2024 Weber Informatics LLC | Privacy Policy