(selection: Set<string>)
| 570 | } |
| 571 | |
| 572 | private attachSelection(selection: Set<string>): Array<GraphNode> { |
| 573 | if (!(selection instanceof Set)) return new Array<GraphNode>(); |
| 574 | this.nodeSelectionHandler.clear(); |
| 575 | const selected = [ |
| 576 | ...this.graph.nodes(node => |
| 577 | selection.has(this.state.selection.stringKey(node)) |
| 578 | && (!this.state.hideDead || node.isLive())) |
| 579 | ]; |
| 580 | this.nodeSelectionHandler.select(selected, true, false); |
| 581 | return selected; |
| 582 | } |
| 583 | |
| 584 | private viewSelection(): void { |
| 585 | let minX; |