MCPcopy Index your code
hub / github.com/bqplot/bqplot / syncModelToBrush

Method syncModelToBrush

js/src/BrushSelector.ts:476–495  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

474 }
475
476 private syncModelToBrush() {
477 // Move and redraw the brush selector, preventing move events to be triggered
478 this.ignoreBrushEvents = true;
479 try {
480 if (this.model.get('selected')) {
481 const range = this.model
482 .get('selected')
483 .map((v) => this.scale.scale(v))
484 .sort(sort);
485
486 this.brush.move(this.d3el, range);
487 } else {
488 this.brush.move(this.d3el, null);
489 }
490
491 this.d3el.call(this.brush);
492 } finally {
493 this.ignoreBrushEvents = false;
494 }
495 }
496
497 reset() {}
498

Callers 2

selected_changedMethod · 0.95
relayoutMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected