Add address property to ClusterUM3OutputDevice

This was necessary because it was the only way to get the address (NetworkPrinterDevice and PrinterOutputDevice returned empty strings)

Contributes to CL-1222
This commit is contained in:
Ian Paschal 2019-02-06 12:01:42 +01:00
parent 01ca3546aa
commit b1104124f3

View file

@ -252,6 +252,11 @@ class ClusterUM3OutputDevice(NetworkedPrinterOutputDevice):
self._compressing_gcode = False
self._sending_gcode = False
## The IP address of the printer.
@pyqtProperty(str, constant = True)
def address(self) -> str:
return self._address
def _onUploadPrintJobProgress(self, bytes_sent: int, bytes_total: int) -> None:
if bytes_total > 0:
new_progress = bytes_sent / bytes_total * 100