mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-11-02 20:52:20 -07:00
Merge branch '3.4'
This commit is contained in:
commit
4157636552
4 changed files with 8 additions and 9 deletions
|
|
@ -39,8 +39,8 @@ from . import Exceptions
|
||||||
# This also means that operations on the stack that modifies the container ordering is prohibited and
|
# This also means that operations on the stack that modifies the container ordering is prohibited and
|
||||||
# will raise an exception.
|
# will raise an exception.
|
||||||
class CuraContainerStack(ContainerStack):
|
class CuraContainerStack(ContainerStack):
|
||||||
def __init__(self, container_id: str, *args, **kwargs):
|
def __init__(self, container_id: str):
|
||||||
super().__init__(container_id, *args, **kwargs)
|
super().__init__(container_id)
|
||||||
|
|
||||||
self._container_registry = ContainerRegistry.getInstance()
|
self._container_registry = ContainerRegistry.getInstance()
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -98,8 +98,7 @@ class CuraStackBuilder:
|
||||||
position = position,
|
position = position,
|
||||||
variant_container = extruder_variant_container,
|
variant_container = extruder_variant_container,
|
||||||
material_container = material_container,
|
material_container = material_container,
|
||||||
quality_container = application.empty_quality_container,
|
quality_container = application.empty_quality_container
|
||||||
global_stack = new_global_stack,
|
|
||||||
)
|
)
|
||||||
new_extruder.setNextStack(new_global_stack)
|
new_extruder.setNextStack(new_global_stack)
|
||||||
new_global_stack.addExtruder(new_extruder)
|
new_global_stack.addExtruder(new_extruder)
|
||||||
|
|
@ -138,7 +137,7 @@ class CuraStackBuilder:
|
||||||
@classmethod
|
@classmethod
|
||||||
def createExtruderStack(cls, new_stack_id: str, extruder_definition: DefinitionContainerInterface, machine_definition_id: str,
|
def createExtruderStack(cls, new_stack_id: str, extruder_definition: DefinitionContainerInterface, machine_definition_id: str,
|
||||||
position: int,
|
position: int,
|
||||||
variant_container, material_container, quality_container, global_stack) -> ExtruderStack:
|
variant_container, material_container, quality_container) -> ExtruderStack:
|
||||||
from cura.CuraApplication import CuraApplication
|
from cura.CuraApplication import CuraApplication
|
||||||
application = CuraApplication.getInstance()
|
application = CuraApplication.getInstance()
|
||||||
registry = application.getContainerRegistry()
|
registry = application.getContainerRegistry()
|
||||||
|
|
|
||||||
|
|
@ -25,8 +25,8 @@ if TYPE_CHECKING:
|
||||||
#
|
#
|
||||||
#
|
#
|
||||||
class ExtruderStack(CuraContainerStack):
|
class ExtruderStack(CuraContainerStack):
|
||||||
def __init__(self, container_id: str, *args, **kwargs):
|
def __init__(self, container_id: str):
|
||||||
super().__init__(container_id, *args, **kwargs)
|
super().__init__(container_id)
|
||||||
|
|
||||||
self.addMetaDataEntry("type", "extruder_train") # For backward compatibility
|
self.addMetaDataEntry("type", "extruder_train") # For backward compatibility
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -23,8 +23,8 @@ from .CuraContainerStack import CuraContainerStack
|
||||||
## Represents the Global or Machine stack and its related containers.
|
## Represents the Global or Machine stack and its related containers.
|
||||||
#
|
#
|
||||||
class GlobalStack(CuraContainerStack):
|
class GlobalStack(CuraContainerStack):
|
||||||
def __init__(self, container_id: str, *args, **kwargs):
|
def __init__(self, container_id: str):
|
||||||
super().__init__(container_id, *args, **kwargs)
|
super().__init__(container_id)
|
||||||
|
|
||||||
self.addMetaDataEntry("type", "machine") # For backward compatibility
|
self.addMetaDataEntry("type", "machine") # For backward compatibility
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue