Don't enabled thermostat settings before connect

This commit is contained in:
atse 2023-07-31 13:25:37 +08:00 committed by Tse Kwok Yan
parent d6082d7e62
commit 3e9e16758a
3 changed files with 5 additions and 0 deletions

View File

@ -382,6 +382,7 @@ class MainWindow(QtWidgets.QMainWindow, Ui_MainWindow):
self.graph_group.setEnabled(result)
self.fan_group.setEnabled(result)
self.report_group.setEnabled(result)
self.thermostat_settings.setEnabled(result)
self.host_set_line.setEnabled(not result)
self.port_set_spin.setEnabled(not result)

View File

@ -248,6 +248,9 @@
</item>
<item>
<widget class="QToolButton" name="thermostat_settings">
<property name="enabled">
<bool>false</bool>
</property>
<property name="text">
<string notr="true">⚙</string>
</property>

View File

@ -117,6 +117,7 @@ class Ui_MainWindow(object):
self.status_lbl.setObjectName("status_lbl")
self.settings_layout.addWidget(self.status_lbl)
self.thermostat_settings = QtWidgets.QToolButton(parent=self.bottom_settings_group)
self.thermostat_settings.setEnabled(False)
self.thermostat_settings.setText("")
self.thermostat_settings.setPopupMode(QtWidgets.QToolButton.ToolButtonPopupMode.InstantPopup)
self.thermostat_settings.setObjectName("thermostat_settings")