Thu, 01 Aug 2019 20:24:41 +0200
MicroPythonReplWidget: made the connect button more intelligent.
eric6/MicroPython/MicroPythonReplWidget.py | file | annotate | diff | comparison | revisions |
--- a/eric6/MicroPython/MicroPythonReplWidget.py Wed Jul 31 20:41:39 2019 +0200 +++ b/eric6/MicroPython/MicroPythonReplWidget.py Thu Aug 01 20:24:41 2019 +0200 @@ -310,6 +310,8 @@ self.__device = MicroPythonDevices.getDevice(deviceType, self) self.__device.setButtons() + + self.connectButton.setEnabled(bool(deviceType)) @pyqtSlot() def on_checkButton_clicked(self): @@ -463,6 +465,14 @@ """ if self.__connected: self.__disconnectFromDevice() + + self.replButton.setChecked(False) + if self.filesButton.isChecked(): + self.on_filesButton_clicked(False) + self.filesButton.setChecked(False) + if self.chartButton.isChecked(): + self.on_chartButton_clicked(False) + self.chartButton.setChecked(False) else: self.__connectToDevice()