mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-14 23:25:53 +08:00
Fix quality_group is None check in _setQualityGroup()
CURA-5423
This commit is contained in:
parent
77826b5a7d
commit
7cf2832183
@ -1032,6 +1032,10 @@ class MachineManager(QObject):
|
|||||||
self.activeQualityChangesGroupChanged.emit()
|
self.activeQualityChangesGroupChanged.emit()
|
||||||
|
|
||||||
def _setQualityGroup(self, quality_group, empty_quality_changes: bool = True) -> None:
|
def _setQualityGroup(self, quality_group, empty_quality_changes: bool = True) -> None:
|
||||||
|
if quality_group is None:
|
||||||
|
self._setEmptyQuality()
|
||||||
|
return
|
||||||
|
|
||||||
if quality_group.node_for_global.getContainer() is None:
|
if quality_group.node_for_global.getContainer() is None:
|
||||||
return
|
return
|
||||||
for node in quality_group.nodes_for_extruders.values():
|
for node in quality_group.nodes_for_extruders.values():
|
||||||
@ -1042,10 +1046,6 @@ class MachineManager(QObject):
|
|||||||
if empty_quality_changes:
|
if empty_quality_changes:
|
||||||
self._current_quality_changes_group = None
|
self._current_quality_changes_group = None
|
||||||
|
|
||||||
if quality_group is None:
|
|
||||||
self._setEmptyQuality()
|
|
||||||
return
|
|
||||||
|
|
||||||
# Set quality and quality_changes for the GlobalStack
|
# Set quality and quality_changes for the GlobalStack
|
||||||
self._global_container_stack.quality = quality_group.node_for_global.getContainer()
|
self._global_container_stack.quality = quality_group.node_for_global.getContainer()
|
||||||
if empty_quality_changes:
|
if empty_quality_changes:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user