Progress!

Masked error caused by saving dbc while editor is open that causes
msg IDs to go crazy by making editor modal, but that affects all
other windows, so might be a better fix.

Added new value type of VALUE_STRING, probably better named
ENUMERATED_STRING, and it uses the table in the editor to define
the enum.

Fixed a bug in the signal viewer load when a signal is not matched
(I found it by renaming a signal and then loading)
This commit is contained in:
Andy Huska
2022-09-20 16:23:18 -05:00
parent 536122f3b5
commit e6058ead34
6 changed files with 34 additions and 7 deletions
+8 -1
View File
@@ -34,6 +34,7 @@ DBCSignalEditor::DBCSignalEditor(QWidget *parent) :
ui->comboType->addItem("SINGLE PRECISION");
ui->comboType->addItem("DOUBLE PRECISION");
ui->comboType->addItem("STRING");
ui->comboType->addItem("ENUMERATED STRING");
ui->bitfield->setMode(GridMode::SIGNAL_VIEW);
@@ -84,7 +85,10 @@ DBCSignalEditor::DBCSignalEditor(QWidget *parent) :
break;
case 4:
currentSignal->valType = STRING;
break;
break;
case 5:
currentSignal->valType = VALUE_STRING;
break;
}
dbcFile->setDirtyFlag();
fillSignalForm(currentSignal);
@@ -577,6 +581,9 @@ void DBCSignalEditor::fillSignalForm(DBC_SIGNAL *sig)
case STRING:
ui->comboType->setCurrentIndex(4);
break;
case VALUE_STRING:
ui->comboType->setCurrentIndex(5);
break;
}
for (int i = 0; i < ui->comboReceiver->count(); i++)