From 0ca143199dbb5c5ccd2ca3208e39901d75287af5 Mon Sep 17 00:00:00 2001 From: Thomas Kriechbaumer Date: Sun, 1 Apr 2018 17:38:50 +0200 Subject: [PATCH] fix message box progress --- DuetRRFOutputDevice.py | 11 +++++------ plugin.json | 2 +- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/DuetRRFOutputDevice.py b/DuetRRFOutputDevice.py index 26fb795..b00ce61 100644 --- a/DuetRRFOutputDevice.py +++ b/DuetRRFOutputDevice.py @@ -226,8 +226,7 @@ def onUploadDone(self): Logger.log("d", self._name_id + " | Simulating...") if self._message: self._message.hide() - text = catalog.i18nc("@info:progress", "Simulating print on {}").format(self._name) - self._message = Message(text, 0, False, -1) + self._message = Message(catalog.i18nc("@info:progress", "Simulating print on {}").format(self._name), 0, False, -1) self._message.show() self._send('gcode', [("gcode", "M37 S1")], self.onReadyToPrint) @@ -238,7 +237,7 @@ def onUploadDone(self): if self._message: self._message.hide() text = "Uploaded file {} to {}.".format(os.path.basename(self._fileName), self._name) - self._message = Message(catalog.i18nc("@info:status", text), 0, False, -1) + self._message = Message(catalog.i18nc("@info:status", text), 0, False) self._message.addAction("open_browser", catalog.i18nc("@action:button", "Open Browser"), "globe", catalog.i18nc("@info:tooltip", "Open browser to DuetWebControl.")) self._message.actionTriggered.connect(self._onMessageActionTriggered) self._message.show() @@ -266,7 +265,7 @@ def onPrintStarted(self): if self._message: self._message.hide() text = "Print started on {} with file {}".format(self._name, self._fileName) - self._message = Message(catalog.i18nc("@info:status", text), 0, False, -1) + self._message = Message(catalog.i18nc("@info:status", text), 0, False) self._message.addAction("open_browser", catalog.i18nc("@action:button", "Open Browser"), "globe", catalog.i18nc("@info:tooltip", "Open browser to DuetWebControl.")) self._message.actionTriggered.connect(self._onMessageActionTriggered) self._message.show() @@ -336,7 +335,7 @@ def onReported(self): self._message.hide() text = "Simulation performed on {} with file {}:\n\n{}".format(self._name, self._fileName, reply_body) - self._message = Message(catalog.i18nc("@info:status", text), 0, False, -1) + self._message = Message(catalog.i18nc("@info:status", text), 0, False) self._message.addAction("open_browser", catalog.i18nc("@action:button", "Open Browser"), "globe", catalog.i18nc("@info:tooltip", "Open browser to DuetWebControl.")) self._message.actionTriggered.connect(self._onMessageActionTriggered) self._message.show() @@ -380,7 +379,7 @@ def _onNetworkError(self, errorCode): errorString = self._reply.errorString() else: errorString = '' - message = Message(catalog.i18nc("@info:status", "There was a network error: {} {}").format(errorCode, errorString), 0, False, -1) + message = Message(catalog.i18nc("@info:status", "There was a network error: {} {}").format(errorCode, errorString), 0, False) message.show() self.writeError.emit(self) diff --git a/plugin.json b/plugin.json index 0f065be..5d7a94a 100644 --- a/plugin.json +++ b/plugin.json @@ -2,6 +2,6 @@ "name": "DuetRRF", "author": "Thomas Kriechbaumer", "description": "Provides direct upload of gcode to DuetRRF.", - "version": "0.0.14", + "version": "0.0.15", "api": 4 }