From 003120d99844f70c846f1f8d1421ccdcab98e26b Mon Sep 17 00:00:00 2001 From: Jordan Sherer Date: Fri, 7 Sep 2018 11:20:10 -0400 Subject: [PATCH] Dummy Data on Startup --- mainwindow.cpp | 26 ++++++++++++++++++-------- 1 file changed, 18 insertions(+), 8 deletions(-) diff --git a/mainwindow.cpp b/mainwindow.cpp index 301654c..3b80343 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -1147,14 +1147,15 @@ MainWindow::MainWindow(QDir const& temp_directory, bool multiple, connect(ui->extFreeTextMsgEdit, &QTableWidget::customContextMenuRequested, this, [this, clearAction2, clearActionAll, restoreAction](QPoint const &point){ QMenu * menu = new QMenu(ui->extFreeTextMsgEdit); - buildEditMenu(ui->extFreeTextMsgEdit, menu); - - menu->addSeparator(); - restoreAction->setDisabled(m_lastTxMessage.isEmpty()); menu->addAction(restoreAction); menu->addSeparator(); + + buildEditMenu(ui->extFreeTextMsgEdit, menu); + + menu->addSeparator(); + menu->addAction(clearAction2); menu->addAction(clearActionAll); @@ -1335,11 +1336,20 @@ void MainWindow::not_GA_warning_message () } void MainWindow::initializeDummyData(){ + if(!QApplication::applicationName().contains("dummy")){ + return; + } auto dt = QDateTime::currentDateTimeUtc().addSecs(-300); - CallDetail cd = {}; - cd.call = "OH8STN"; - cd.utcTimestamp = dt; - logCallActivity(cd, false); + CallDetail cd1 = {}; + cd1.call = "KN4CRD"; + cd1.utcTimestamp = dt; + logCallActivity(cd1, false); + + CallDetail cd2 = {}; + cd2.call = "KN4CRD/P"; + cd2.utcTimestamp = dt; + logCallActivity(cd2, false); + displayActivity(true); }