mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 14:37:29 -06:00
CURA-5334 factor out the need for material_diameter in machine definition for getDefaultMaterial
This commit is contained in:
parent
f775ce815d
commit
44e9d1e334
4 changed files with 15 additions and 10 deletions
|
@ -141,7 +141,6 @@ class MachineSettingsAction(MachineAction):
|
|||
|
||||
# Set the material container for each extruder to a sane default
|
||||
material_manager = self._application.getMaterialManager()
|
||||
material_node = material_manager.getDefaultMaterial(self._global_container_stack, None)
|
||||
|
||||
else:
|
||||
# The metadata entry is stored in an ini, and ini files are parsed as strings only.
|
||||
|
@ -151,6 +150,8 @@ class MachineSettingsAction(MachineAction):
|
|||
|
||||
# set materials
|
||||
for position in extruder_positions:
|
||||
if has_materials:
|
||||
material_node = material_manager.getDefaultMaterial(self._global_container_stack, position, None)
|
||||
machine_manager.setMaterial(position, material_node)
|
||||
|
||||
self._application.globalContainerStackChanged.emit()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue