diff options
author | fieldOfView <aldo@fieldofview.com> | 2018-03-16 16:38:56 +0300 |
---|---|---|
committer | fieldOfView <aldo@fieldofview.com> | 2018-03-16 16:38:56 +0300 |
commit | 78a7299fc59b8b665e49d370512442c02c2efadb (patch) | |
tree | fa049663ebad3a8e5d9ddd668f6a8ae627b09acc /plugins/SupportEraser | |
parent | 83168886d6cfafffc88ec9d7c55770f8631c3afe (diff) |
Maintain a selection when removing a mesh, so the tool stays active
Diffstat (limited to 'plugins/SupportEraser')
-rw-r--r-- | plugins/SupportEraser/SupportEraser.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/plugins/SupportEraser/SupportEraser.py b/plugins/SupportEraser/SupportEraser.py index 22dd9b6d9c..8f89d212d0 100644 --- a/plugins/SupportEraser/SupportEraser.py +++ b/plugins/SupportEraser/SupportEraser.py @@ -126,9 +126,16 @@ class SupportEraser(Tool): Application.getInstance().getController().getScene().sceneChanged.emit(node) def _removeEraserMesh(self, node: CuraSceneNode): + parent = node.getParent() + if parent == self._controller.getScene().getRoot(): + parent = None + op = RemoveSceneNodeOperation(node) op.push() + if parent and not Selection.isSelected(parent): + Selection.add(parent) + Application.getInstance().getController().getScene().sceneChanged.emit(node) def _updateEnabled(self): |