Fix: bed leveling for UM+

CURA-4844
This commit is contained in:
Aleksei S 2018-03-29 11:53:31 +02:00
parent 70f867c4f1
commit 290adbd906
5 changed files with 57 additions and 2 deletions

View file

@ -42,6 +42,14 @@ class USBPrinterOutputDeviceManager(QObject, OutputDevicePlugin):
# Because the model needs to be created in the same thread as the QMLEngine, we use a signal.
self.addUSBOutputDeviceSignal.connect(self.addOutputDevice)
Application.getInstance().globalContainerStackChanged.connect(self.updateUSBPrinterOutputDevices)
# The method updates/reset the USB settings for all connected USB devices
def updateUSBPrinterOutputDevices(self):
for key, device in self._usb_output_devices.items():
if isinstance(device, USBPrinterOutputDevice.USBPrinterOutputDevice):
device.resetDeviceSettings()
def start(self):
self._check_updates = True
self._update_thread.start()