From 0e07395f2bf4f84a7aecaf0833d916e1c3357a53 Mon Sep 17 00:00:00 2001 From: Joe Taylor Date: Fri, 14 May 2021 14:49:14 -0400 Subject: [PATCH] Double-click on Erase button will now clear the Band Map and Messages windows. --- map65/mainwindow.cpp | 8 +++++++- map65/mainwindow.h | 1 + 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/map65/mainwindow.cpp b/map65/mainwindow.cpp index 5dffcc5fc..9c6cec7ef 100644 --- a/map65/mainwindow.cpp +++ b/map65/mainwindow.cpp @@ -1460,11 +1460,17 @@ void MainWindow::readFromStdout() //readFromStdout } } -void MainWindow::on_EraseButton_clicked() //Erase +void MainWindow::on_EraseButton_clicked() { + qint64 ms=QDateTime::currentMSecsSinceEpoch(); ui->decodedTextBrowser->clear(); + if((ms-m_msErase)<500) { + on_actionErase_Band_Map_and_Messages_triggered(); + } + m_msErase=ms; } + void MainWindow::decodeBusy(bool b) //decodeBusy() { m_decoderBusy=b; diff --git a/map65/mainwindow.h b/map65/mainwindow.h index 10dfe5a3b..2165ac619 100644 --- a/map65/mainwindow.h +++ b/map65/mainwindow.h @@ -140,6 +140,7 @@ private slots: private: Ui::MainWindow *ui; + qint64 m_msErase; qint32 m_nDevIn; qint32 m_nDevOut; qint32 m_idInt;