Home | History | Annotate | Download | only in chromium-trace

Lines Matching refs:dispatchChangeEvent

352 !1}d.prototype={__proto__:base.EventTarget.prototype,setWhenPossible:function(a){this.pendingSetFunction_=a},get isAttachedToDocument_(){var a=this.parentEl_;if(void 0!==a){for(;a.parentNode;)a=a.parentNode;return a==this.parentEl_.ownerDocument}},onResize_:function(){this.dispatchChangeEvent()},checkForAttach_:function(){if(this.isAttachedToDocument_&&0!=this.clientWidth){this.iframe_||(this.iframe_=document.createElement("iframe"),this.iframe_.style.cssText="position:absolute;width:100%;height:0;border:0;visibility:hidden;",
353 this.parentEl_.appendChild(this.iframe_),this.iframe_.contentWindow.addEventListener("resize",this.onResize_));var a=this.parentEl_.clientWidth+"x"+this.parentEl_.clientHeight;if(this.pendingSetFunction_){this.lastSize_=a;try{this.pendingSetFunction_()}catch(c){console.log("While running setWhenPossible:",c.message?c.message+"\n"+c.stack:c.stack)}this.pendingSetFunction_=void 0}window.clearInterval(this.checkForAttachInterval_);this.checkForAttachInterval_=void 0}},dispatchChangeEvent:function(){base.dispatchSimpleEvent(this,
355 this.xViewVectorToWorld(a.panX);this.panY=a.panY},onModelTrackControllerScroll_:function(a){this.panY_=this.modelTrackContainer_.scrollTop},set modelTrackContainer(a){this.modelTrackContainer_&&this.modelTrackContainer_.removeEventListener("scroll",this.onModelTrackControllerScroll_);this.modelTrackContainer_=a;this.modelTrackContainer_.addEventListener("scroll",this.onModelTrackControllerScroll_)},get scaleX(){return this.scaleX_},set scaleX(a){this.scaleX_!=a&&(this.scaleX_=a,this.dispatchChangeEvent())},
356 get panX(){return this.panX_},set panX(a){this.panX_!=a&&(this.panX_=a,this.dispatchChangeEvent())},get panY(){return this.panY_},set panY(a){this.panY_=a;this.modelTrackContainer_.scrollTop=a},setPanAndScale:function(a,c){if(this.scaleX_!=c||this.panX_!=a)this.scaleX_=c,this.panX_=a,this.dispatchChangeEvent()},xWorldToView:function(a){return(a+this.panX_)*this.scaleX_},xWorldVectorToView:function(a){return a*this.scaleX_},xViewToWorld:function(a){return a/this.scaleX_-this.panX_},xViewVectorToWorld:function(a){return a/
358 set gridEnabled(a){this.gridEnabled_!=a&&(this.gridEnabled_=a&&!0,this.dispatchChangeEvent())},get gridTimebase(){return this.gridTimebase_},set gridTimebase(a){this.gridTimebase_!=a&&(this.gridTimebase_=a,this.dispatchChangeEvent())},get gridStep(){return this.gridStep_},applyTransformToCanvas:function(a){a.transform(this.scaleX_,0,0,1,this.panX_*this.scaleX_,0)},addMarker:function(a){a=new b(this,a);this.markers.push(a);this.dispatchChangeEvent();this.dispatchMarkersChangeEvent_();return a},removeMarker:function(a){for(var c=
359 0;c<this.markers.length;++c)if(this.markers[c]===a)return this.markers.splice(c,1),this.dispatchChangeEvent(),this.dispatchMarkersChangeEvent_(),!0},findMarkerNear:function(a,c){for(var b=this.xViewVectorToWorld(c),d=0;d<this.markers.length;++d)if(Math.abs(this.markers[d].positionWorld-a)<=b)return this.markers[d]},drawGridLines:function(a,c,b){if(this.gridEnabled){var d=this.gridTimebase;for(a.beginPath();d<b;){if(d>=c){var g=this.xWorldToView(d);a.moveTo(g,0);a.lineTo(g,a.canvas.height)}d+=this.gridStep}a.strokeStyle=
360 "rgba(255,0,0,0.25)";a.stroke()}},drawMarkerArrows:function(a,c,b,d){for(var g=0;g<this.markers.length;++g)this.markers[g].drawTriangle_(a,c,b,a.canvas.height,d,this)},drawMarkerLines:function(a,c,b){for(var d=0;d<this.markers.length;++d)this.markers[d].drawLine(a,c,b,a.canvas.height,this)}};b.prototype={get positionWorld(){return this.positionWorld_},set positionWorld(a){this.positionWorld_=a;this.viewport_.dispatchChangeEvent()},set selected(a){this.selected_=a;this.viewport_.dispatchChangeEvent()},
448 "expanded",!0);this.updateContents_()},get expanded(){return this.expandEl_.classList.contains("expand-button-expanded")},set expanded(b){b=!!b;this.expandEl_.classList.contains("expand-button-expanded")!==b&&(b?(this.classList.add("expanded"),this.expandEl_.classList.add("expand-button-expanded")):(this.classList.remove("expanded"),this.expandEl_.classList.remove("expand-button-expanded")),this.viewport_.dispatchChangeEvent(),this.processBase_&&(new a(this.processBase_.model)).setSettingFor(this.processBase_,
492 get selection(){return this.selection_},set selection(a){if(!(a instanceof d))throw Error("Expected Selection");var b;for(b=0;b<this.selection_.length;b++)this.selection_[b].selected=!1;this.selection_.clear();this.selection_.addSelection(a);base.dispatchSimpleEvent(this,"selectionChange");for(b=0;b<this.selection_.length;b++)this.selection_[b].selected=!0;this.selection_.length&&this.selection_[0].track&&this.selection_[0].track.scrollIntoViewIfNeeded();this.viewport_.dispatchChangeEvent()},hideDragBox_:function(){this.dragBox_.style.left=