mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-13 20:16:02 +08:00
PrinterOutput now keeps track of camera state
CURA-2411
This commit is contained in:
parent
8aa5ea5864
commit
e77d7f1f20
@ -49,6 +49,8 @@ class PrinterOutputDevice(QObject, OutputDevice):
|
|||||||
self._printer_state = ""
|
self._printer_state = ""
|
||||||
self._printer_type = "unknown"
|
self._printer_type = "unknown"
|
||||||
|
|
||||||
|
self._camera_active = False
|
||||||
|
|
||||||
def requestWrite(self, nodes, file_name = None, filter_by_machine = False):
|
def requestWrite(self, nodes, file_name = None, filter_by_machine = False):
|
||||||
raise NotImplementedError("requestWrite needs to be implemented")
|
raise NotImplementedError("requestWrite needs to be implemented")
|
||||||
|
|
||||||
@ -136,6 +138,7 @@ class PrinterOutputDevice(QObject, OutputDevice):
|
|||||||
|
|
||||||
@pyqtSlot()
|
@pyqtSlot()
|
||||||
def startCamera(self):
|
def startCamera(self):
|
||||||
|
self._camera_active = True
|
||||||
self._startCamera()
|
self._startCamera()
|
||||||
|
|
||||||
def _startCamera(self):
|
def _startCamera(self):
|
||||||
@ -143,6 +146,7 @@ class PrinterOutputDevice(QObject, OutputDevice):
|
|||||||
|
|
||||||
@pyqtSlot()
|
@pyqtSlot()
|
||||||
def stopCamera(self):
|
def stopCamera(self):
|
||||||
|
self._camera_active = False
|
||||||
self._stopCamera()
|
self._stopCamera()
|
||||||
|
|
||||||
def _stopCamera(self):
|
def _stopCamera(self):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user