mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 22:47:29 -06:00
Send setting extruder only when extruder is valid
Apparently hasProperty always returns True. Fine. I'll just check the values then... Contributes to issue CURA-2011.
This commit is contained in:
parent
b21a1f311a
commit
c2201eb814
1 changed files with 3 additions and 2 deletions
|
@ -227,10 +227,11 @@ class StartSliceJob(Job):
|
|||
# global_inherits_stack property.
|
||||
def _buildGlobalInheritsStackMessage(self, stack):
|
||||
for key in stack.getAllKeys():
|
||||
if stack.hasProperty(key, "global_inherits_stack"):
|
||||
extruder = int(stack.getProperty(key, "global_inherits_stack"))
|
||||
if extruder >= 0: #Set to a specific extruder.
|
||||
setting_extruder = self._slice_message.addRepeatedMessage("global_inherits_stack")
|
||||
setting_extruder.name = key
|
||||
setting_extruder.extruder = int(stack.getProperty(key, "global_inherits_stack"))
|
||||
setting_extruder.extruder = extruder
|
||||
|
||||
## Check if a node has per object settings and ensure that they are set correctly in the message
|
||||
# \param node \type{SceneNode} Node to check.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue