mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-12 20:59:02 +08:00
CURA-4400 fix setting extruder number on a group printed with mixed extruders
This commit is contained in:
parent
98b0559c9a
commit
6909c9263a
@ -109,10 +109,6 @@ class CuraActions(QObject):
|
|||||||
|
|
||||||
nodes_to_change = []
|
nodes_to_change = []
|
||||||
for node in Selection.getAllSelectedObjects():
|
for node in Selection.getAllSelectedObjects():
|
||||||
# Do not change any nodes that already have the right extruder set.
|
|
||||||
if node.callDecoration("getActiveExtruder") == extruder_id:
|
|
||||||
continue
|
|
||||||
|
|
||||||
# If the node is a group, apply the active extruder to all children of the group.
|
# If the node is a group, apply the active extruder to all children of the group.
|
||||||
if node.callDecoration("isGroup"):
|
if node.callDecoration("isGroup"):
|
||||||
for grouped_node in BreadthFirstIterator(node):
|
for grouped_node in BreadthFirstIterator(node):
|
||||||
@ -125,6 +121,10 @@ class CuraActions(QObject):
|
|||||||
nodes_to_change.append(grouped_node)
|
nodes_to_change.append(grouped_node)
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
# Do not change any nodes that already have the right extruder set.
|
||||||
|
if node.callDecoration("getActiveExtruder") == extruder_id:
|
||||||
|
continue
|
||||||
|
|
||||||
nodes_to_change.append(node)
|
nodes_to_change.append(node)
|
||||||
|
|
||||||
if not nodes_to_change:
|
if not nodes_to_change:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user