mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 22:47:29 -06:00
Fix flashing "default" firmware
The url is not QUrl encoded if the "default" firmware is flashed
This commit is contained in:
parent
7e90546163
commit
65ada30c9c
1 changed files with 5 additions and 2 deletions
|
@ -127,8 +127,11 @@ class USBPrinterOutputDevice(PrinterOutputDevice):
|
|||
|
||||
@pyqtSlot(str)
|
||||
def updateFirmware(self, file):
|
||||
# the file path is qurl encoded.
|
||||
self._firmware_location = QUrl(file).toLocalFile()
|
||||
# the file path could be qurl encoded.
|
||||
if file[:7] == "file://":
|
||||
self._firmware_location = QUrl(file).toLocalFile()
|
||||
else:
|
||||
self._firmware_location = file
|
||||
self.showFirmwareInterface()
|
||||
self.setFirmwareUpdateState(FirmwareUpdateState.updating)
|
||||
self._update_firmware_thread.start()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue