mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-15 01:26:01 +08:00
Added isConnecting
CURA-1339
This commit is contained in:
parent
e5adea4ab2
commit
623596ca59
@ -22,6 +22,7 @@ class PrinterOutputDevice(OutputDevice, QObject):
|
|||||||
self._head_y = 0
|
self._head_y = 0
|
||||||
self._head_z = 0
|
self._head_z = 0
|
||||||
self._connected = False
|
self._connected = False
|
||||||
|
self._connecting = False
|
||||||
|
|
||||||
def requestWrite(self, node, file_name = None, filter_by_machine = False):
|
def requestWrite(self, node, file_name = None, filter_by_machine = False):
|
||||||
raise NotImplementedError("requestWrite needs to be implemented")
|
raise NotImplementedError("requestWrite needs to be implemented")
|
||||||
@ -38,6 +39,7 @@ class PrinterOutputDevice(OutputDevice, QObject):
|
|||||||
headPositionChanged = pyqtSignal()
|
headPositionChanged = pyqtSignal()
|
||||||
|
|
||||||
conectedChanged = pyqtSignal()
|
conectedChanged = pyqtSignal()
|
||||||
|
connectingChanged = pyqtSignal()
|
||||||
|
|
||||||
## Get the bed temperature of the bed (if any)
|
## Get the bed temperature of the bed (if any)
|
||||||
# This function is "final" (do not re-implement)
|
# This function is "final" (do not re-implement)
|
||||||
@ -107,6 +109,10 @@ class PrinterOutputDevice(OutputDevice, QObject):
|
|||||||
def connected(self):
|
def connected(self):
|
||||||
return self._connected
|
return self._connected
|
||||||
|
|
||||||
|
@pyqtProperty(bool, notify = connectingChanged)
|
||||||
|
def isConnecting(self):
|
||||||
|
return self._connecting
|
||||||
|
|
||||||
## Ensure that close gets called when object is destroyed
|
## Ensure that close gets called when object is destroyed
|
||||||
def __del__(self):
|
def __del__(self):
|
||||||
self.close()
|
self.close()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user