From bc87f18ada4e367ca180c4b81b53de9f0d6c36cb Mon Sep 17 00:00:00 2001 From: Michael Carpenter Date: Tue, 5 Aug 2014 06:30:07 -0400 Subject: [PATCH] Interrogation: Notify the user when interrogation fails, but allow them to continue. --- core/src/mainwindow.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/core/src/mainwindow.cpp b/core/src/mainwindow.cpp index 4b753ac..41063c4 100644 --- a/core/src/mainwindow.cpp +++ b/core/src/mainwindow.cpp @@ -1469,9 +1469,11 @@ void MainWindow::interrogationComplete() QLOG_INFO() << "Interrogation complete"; if (m_interrogationFailureCount > 0) { - QMessageBox::information(0,"Error","Something has gone serious wrong, one of the commands timed out during interrogation. This should be properly investigated before continuing"); - emsComms->disconnectSerial(); - return; + if (QMessageBox::question(this,"Error","One of the commands has failed during interrogation. This could be a sign of a more serious problem, Do you wish to continue?",QMessageBox::Yes,QMessageBox::No) != QMessageBox::Yes) + { + emsComms->disconnectSerial(); + return; + } } else { @@ -1892,6 +1894,7 @@ void MainWindow::commandFailed(int sequencenumber,unsigned short errornum) { //interrogateTaskFail(int) catches this case. //if (progressView) progressView->taskFail(sequencenumber); + m_interrogationFailureCount++; } }