From 1d4dbcc99004e8e530fbb1d25e3e70e5468978df Mon Sep 17 00:00:00 2001 From: Jaime van Kessel Date: Thu, 16 Jul 2015 11:12:52 +0200 Subject: [PATCH] Delting now correctly deletes the group --- cura/CuraApplication.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 55d54d5716..e7eb9e2725 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -251,9 +251,16 @@ class CuraApplication(QtApplication): if not object and object_id != 0: #Workaround for tool handles overlapping the selected object object = Selection.getSelectedObject(0) - + if object: - op = RemoveSceneNodeOperation(object) + if object.getParent(): + group_node = object.getParent() + if not group_node.callDecoration("isGroup"): + op = RemoveSceneNodeOperation(object) + else: + while group_node.getParent().callDecoration("isGroup"): + group_node = group_node.getParent() + op = RemoveSceneNodeOperation(group_node) op.push() self.setPlatformActivity(False)