Fix Issue#1241

When a Block node was deleted its linked blocks were not unlinked
which caused a crash when the user tried to select a linked block.
This fixes the issue by ensuring all links are removed when a Block
node is delete.

Undo/redo is also supported.
This commit is contained in:
Thomas Wilshaw
2020-09-29 18:27:30 +01:00
parent fec9774935
commit e09afd7f68
2 changed files with 19 additions and 0 deletions
+1
View File
@@ -112,6 +112,7 @@ private:
NodeGraph* graph_;
QList<Node*> nodes_;
QList<NodeEdgePtr> edges_;
QMap<Block*, QList<Block*>> linked_blocks_;
};
class NodeRemoveWithExclusiveDeps : public UndoCommand {