mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-06-04 11:14:21 +08:00
Ungroupning with nested groups now works correctly
This commit is contained in:
parent
49cb12bda1
commit
cc2f0fc009
@ -437,11 +437,12 @@ class CuraApplication(QtApplication):
|
|||||||
@pyqtSlot()
|
@pyqtSlot()
|
||||||
def ungroupSelected(self):
|
def ungroupSelected(self):
|
||||||
ungrouped_nodes = []
|
ungrouped_nodes = []
|
||||||
for node in Selection.getAllSelectedObjects():
|
selected_objects = Selection.getAllSelectedObjects()[:] #clone the list
|
||||||
|
for node in selected_objects:
|
||||||
if node.callDecoration("isGroup" ):
|
if node.callDecoration("isGroup" ):
|
||||||
children_to_move = []
|
children_to_move = []
|
||||||
for child in node.getChildren():
|
for child in node.getChildren():
|
||||||
if child.getMeshData() is not None:
|
if type(child) is SceneNode:
|
||||||
children_to_move.append(child)
|
children_to_move.append(child)
|
||||||
|
|
||||||
for child in children_to_move:
|
for child in children_to_move:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user