mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-14 01:25:51 +08:00
Add "machine" metadata entry when setting the next stack for an extruder
This commit is contained in:
parent
0c232c9462
commit
df8bba6c96
@ -26,6 +26,10 @@ class ExtruderStack(CuraContainerStack):
|
||||
def setNextStack(self, stack: ContainerStack) -> None:
|
||||
super().setNextStack(stack)
|
||||
stack.addExtruder(self)
|
||||
if not self.getMetaDataEntry("machine"):
|
||||
self.addMetaDataEntry("machine", stack.id)
|
||||
else:
|
||||
self.setMetaDataEntry("machine", stack.id)
|
||||
|
||||
@override(ContainerStack)
|
||||
def getProperty(self, key: str, property_name: str) -> Any:
|
||||
|
Loading…
x
Reference in New Issue
Block a user