Properly fallback to global if no extruders

This fixes the extruderValue function for printers such as the Ultimaker 2+.
This commit is contained in:
Ghostkeeper 2016-08-05 11:36:16 +02:00
parent 6cf8536404
commit a46f6cc14d
No known key found for this signature in database
GPG key ID: 701948C5954A7385

View file

@ -328,8 +328,9 @@ class ExtruderManager(QObject):
if extruder:
value = extruder.getRawProperty(key, "value")
if isinstance(value, UM.Settings.SettingFunction):
value = value(extruder)
if isinstance(value, UM.Settings.SettingFunction):
value = value(extruder)
else: #Just a value from global.
value = UM.Application.getInstance().getGlobalContainerStack().getProperty(key, "value")
return value