mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-14 13:46:01 +08:00
Simplify the numUserSettings count
This commit is contained in:
parent
6da5216cac
commit
55dacee45f
@ -399,8 +399,7 @@ class MachineManager(QObject):
|
|||||||
def numUserSettings(self) -> int:
|
def numUserSettings(self) -> int:
|
||||||
if not self._global_container_stack:
|
if not self._global_container_stack:
|
||||||
return 0
|
return 0
|
||||||
num_user_settings = 0
|
num_user_settings = self._global_container_stack.getTop().getNumInstances()
|
||||||
num_user_settings += self._global_container_stack.getTop().getNumInstances()
|
|
||||||
stacks = self._global_container_stack.extruderList
|
stacks = self._global_container_stack.extruderList
|
||||||
for stack in stacks:
|
for stack in stacks:
|
||||||
num_user_settings += stack.getTop().getNumInstances()
|
num_user_settings += stack.getTop().getNumInstances()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user