mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-13 02:58:59 +08:00
Start overriding getProperty in GlobalStack
Since we have the "resolve" property, we should transparently handle it so lookup can just use "value". Contributes to CURA-3497
This commit is contained in:
parent
0656dd53c3
commit
4904e449a0
@ -12,6 +12,14 @@ class GlobalStack(ContainerStack):
|
|||||||
def __init__(self, container_id, *args, **kwargs):
|
def __init__(self, container_id, *args, **kwargs):
|
||||||
super().__init__(container_id, *args, **kwargs)
|
super().__init__(container_id, *args, **kwargs)
|
||||||
|
|
||||||
|
def getProperty(self, key, property_name):
|
||||||
|
if property_name == "value":
|
||||||
|
resolve = super().getProperty(key, "resolve")
|
||||||
|
if resolve:
|
||||||
|
return resolve
|
||||||
|
|
||||||
|
return super().getProperty(key, property_name)
|
||||||
|
|
||||||
def setNextStack(self, next_stack):
|
def setNextStack(self, next_stack):
|
||||||
raise CannotSetNextStackError("Global stack cannot have a next stack!")
|
raise CannotSetNextStackError("Global stack cannot have a next stack!")
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user