diff --git a/re/graphingwindow.cpp b/re/graphingwindow.cpp index 41d8505..0ab6952 100644 --- a/re/graphingwindow.cpp +++ b/re/graphingwindow.cpp @@ -81,7 +81,7 @@ GraphingWindow::GraphingWindow(const QVector *frames, QWidget *parent) selectedPen.setWidth(1); selectedPen.setColor(Qt::blue); - ui->graphingView->setAttribute(Qt::WA_AcceptTouchEvents); + //ui->graphingView->setAttribute(Qt::WA_AcceptTouchEvents); if (useOpenGL) { diff --git a/re/newgraphdialog.cpp b/re/newgraphdialog.cpp index 1e13110..1ee0227 100644 --- a/re/newgraphdialog.cpp +++ b/re/newgraphdialog.cpp @@ -93,8 +93,8 @@ void NewGraphDialog::checkSignalAgreement() GraphParams testingParams; bool bAgree = true; bool sigSigned = false; - DBC_SIGNAL *sig; - DBC_MESSAGE *msg; + DBC_SIGNAL *sig = nullptr; + DBC_MESSAGE *msg = nullptr; if (dbcHandler == nullptr) return; if (dbcHandler->getFileCount() == 0) return; @@ -104,6 +104,11 @@ void NewGraphDialog::checkSignalAgreement() { sig = msg->sigHandler->findSignalByName(ui->cbSignals->currentText()); } + else + { + ui->lblMsgStatus->setText("Msg ID doesn't exist in DBC"); + return; + } if (sig) { @@ -125,6 +130,12 @@ void NewGraphDialog::checkSignalAgreement() if (testingParams.startBit != sig->startBit) bAgree = false; if (testingParams.numBits != sig->signalSize) bAgree = false; } + else + { + ui->lblMsgStatus->setText("Signal name doesn't exist in DBC"); + return; + } + if (bAgree) { ui->lblMsgStatus->setText("Graph params match this signal");