Sensor ui refactoring

This commit is contained in:
elecpower
2021-02-01 06:39:51 +11:00
parent 7db1009002
commit 5ac380360d
10 changed files with 319 additions and 365 deletions
+5
View File
@@ -45,6 +45,11 @@ class AutoCheckBox: public QCheckBox
updateValue();
}
void setEnabled(bool enabled)
{
QCheckBox::setEnabled(enabled);
}
void updateValue()
{
lock = true;
+6 -1
View File
@@ -71,10 +71,13 @@ class AutoLineEdit: public QLineEdit
lock = false;
}
signals:
void currentDataChanged();
protected slots:
void onEdited()
{
if (lock)
if ((panel && panel->lock) || lock)
return;
if (field)
@@ -86,6 +89,8 @@ class AutoLineEdit: public QLineEdit
if (panel)
emit panel->modified();
emit currentDataChanged();
}
protected: