diff --git a/cura/Settings/CuraContainerRegistry.py b/cura/Settings/CuraContainerRegistry.py index 543678ee22..3590d70602 100644 --- a/cura/Settings/CuraContainerRegistry.py +++ b/cura/Settings/CuraContainerRegistry.py @@ -454,16 +454,14 @@ class CuraContainerRegistry(ContainerRegistry): material_id = "default" if machine.material.getId() not in ("empty", "empty_material"): - # TODO: find the ID that's suitable for this extruder - pass + material_id = machine.material.getId() else: material_id = "empty_material" extruder_stack.setMaterialById(material_id) quality_id = "default" if machine.quality.getId() not in ("empty", "empty_quality"): - # TODO: find the ID that's suitable for this extruder - pass + quality_id = machine.quality.getId() else: quality_id = "empty_quality" extruder_stack.setQualityById(quality_id) diff --git a/cura/Settings/CuraContainerStack.py b/cura/Settings/CuraContainerStack.py index 156883ade3..f0cec3c450 100755 --- a/cura/Settings/CuraContainerStack.py +++ b/cura/Settings/CuraContainerStack.py @@ -121,7 +121,7 @@ class CuraContainerStack(ContainerStack): # # \throws Exceptions.InvalidContainerError Raised when no container could be found with the specified ID. def setQualityById(self, new_quality_id: str) -> None: - quality = self._empty_instance_container + quality = self._empty_quality if new_quality_id == "default": new_quality = self.findDefaultQuality() if new_quality: @@ -159,7 +159,7 @@ class CuraContainerStack(ContainerStack): # # \throws Exceptions.InvalidContainerError Raised when no container could be found with the specified ID. def setMaterialById(self, new_material_id: str) -> None: - material = self._empty_instance_container + material = self._empty_material if new_material_id == "default": new_material = self.findDefaultMaterial() if new_material: @@ -197,7 +197,7 @@ class CuraContainerStack(ContainerStack): # # \throws Exceptions.InvalidContainerError Raised when no container could be found with the specified ID. def setVariantById(self, new_variant_id: str) -> None: - variant = self._empty_instance_container + variant = self._empty_variant if new_variant_id == "default": new_variant = self.findDefaultVariant() if new_variant: