From dd12715489ec235e916cde6db9f71537843efc4c Mon Sep 17 00:00:00 2001 From: mcyph <20507948+mcyph@users.noreply.github.com> Date: Sun, 11 Apr 2021 14:33:07 +1000 Subject: [PATCH] bugfix for cell validation/invalidation --- src/mxgraph/view/graph/mxGraphView.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/mxgraph/view/graph/mxGraphView.ts b/src/mxgraph/view/graph/mxGraphView.ts index e755da856..e2d41f9bf 100644 --- a/src/mxgraph/view/graph/mxGraphView.ts +++ b/src/mxgraph/view/graph/mxGraphView.ts @@ -561,6 +561,8 @@ class mxGraphView extends mxEventSource { this.invalidate(model.getEdgeAt(cell, i), recurse, includeEdges); } } + + cell.invalidating = false; } } @@ -845,6 +847,7 @@ class mxGraphView extends mxEventSource { // validateCell(cell: mxCell, visible?: boolean): void; validateCell(cell: mxCell | null=null, visible: boolean = true): mxCell | null { + if (cell != null) { visible = visible && (this.graph).isCellVisible(cell); const state = this.getState(cell, visible); @@ -876,6 +879,7 @@ class mxGraphView extends mxEventSource { */ // validateCellState(cell: mxCell, recurse?: boolean): void; validateCellState(cell: mxCell, recurse: boolean = true): mxCellState | null { + let state: mxCellState | null = null; if (cell != null) { @@ -939,6 +943,7 @@ class mxGraphView extends mxEventSource { */ // updateCellState(state: mxCellState): void; updateCellState(state: mxCellState) { + const absoluteOffset = state.absoluteOffset; const origin = state.origin;