mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-05-11 02:19:01 +08:00
Add a method to get the id of the current user profile
CURA-1668
This commit is contained in:
parent
cc7369c594
commit
8608468802
@ -205,6 +205,13 @@ class MachineManagerModel(QObject):
|
|||||||
def isGlobalStackValid(self):
|
def isGlobalStackValid(self):
|
||||||
return self._global_stack_valid
|
return self._global_stack_valid
|
||||||
|
|
||||||
|
@pyqtProperty(str, notify = globalContainerChanged)
|
||||||
|
def activeUserProfileId(self):
|
||||||
|
if self._global_container_stack:
|
||||||
|
return self._global_container_stack.getTop().getId()
|
||||||
|
|
||||||
|
return ""
|
||||||
|
|
||||||
@pyqtProperty(str, notify = globalContainerChanged)
|
@pyqtProperty(str, notify = globalContainerChanged)
|
||||||
def activeMachineName(self):
|
def activeMachineName(self):
|
||||||
if self._global_container_stack:
|
if self._global_container_stack:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user