Activity gui should update every 15 seconds

This commit is contained in:
Jordan Sherer 2018-07-09 20:51:42 -04:00
parent cd9079e7ff
commit 9907a80136
2 changed files with 22 additions and 15 deletions

View File

@ -3854,6 +3854,7 @@ void MainWindow::guiUpdate()
//To keep calling Fox, Hound must reactivate Enable Tx at least once every 2 minutes //To keep calling Fox, Hound must reactivate Enable Tx at least once every 2 minutes
if(tHound >= 120 and m_ntx==1) auto_tx_mode(false); if(tHound >= 120 and m_ntx==1) auto_tx_mode(false);
} }
if(m_auto and m_mode=="Echo" and m_bEchoTxOK) { if(m_auto and m_mode=="Echo" and m_bEchoTxOK) {
progressBar.setMaximum(6); progressBar.setMaximum(6);
progressBar.setValue(int(m_s6)); progressBar.setValue(int(m_s6));
@ -3931,19 +3932,14 @@ void MainWindow::guiUpdate()
if(!m_monitoring and !m_diskData) { if(!m_monitoring and !m_diskData) {
ui->signal_meter_widget->setValue(0,0); ui->signal_meter_widget->setValue(0,0);
} }
m_sec0=nsec; m_sec0=nsec;
displayDialFrequency (); displayDialFrequency ();
}
// TODO: jsherer - is this the right place? if(nsec % 15 == 0){
update_dynamic_property (ui->startTxButton, "transmitting", m_transmitting); displayActivity();
}
if(ui->tableWidgetCalls->selectedItems().isEmpty() && ui->tableWidgetRXAll->selectedItems().isEmpty()){
ui->replyMacroButton->setDisabled(true);
ui->snrMacroButton->setDisabled(true);
} else {
ui->replyMacroButton->setDisabled(false);
ui->snrMacroButton->setDisabled(false);
} }
m_iptt0=g_iptt; m_iptt0=g_iptt;
@ -7617,11 +7613,10 @@ void MainWindow::postDecode (bool is_new, QString const& message)
, QChar {'?'} == decode.mid (has_seconds ? 24 + 21 : 22 + 21, 1) , QChar {'?'} == decode.mid (has_seconds ? 24 + 21 : 22 + 21, 1)
, m_diskData); , m_diskData);
} }
}
void MainWindow::displayActivity(){
// RX Activity
// TODO: jsherer - keep track of selection
int selectedOffset = -1; int selectedOffset = -1;
auto selectedItems = ui->tableWidgetRXAll->selectedItems(); auto selectedItems = ui->tableWidgetRXAll->selectedItems();
if(!selectedItems.isEmpty()){ if(!selectedItems.isEmpty()){
@ -7706,7 +7701,7 @@ void MainWindow::postDecode (bool is_new, QString const& message)
ui->tableWidgetRXAll->resizeColumnToContents(0); ui->tableWidgetRXAll->resizeColumnToContents(0);
ui->tableWidgetRXAll->resizeColumnToContents(1); //resizeColumnsToContents(); ui->tableWidgetRXAll->resizeColumnToContents(1); //resizeColumnsToContents();
// TODO: jsherer - keep track of selection // Call Activity
QString selectedCall; QString selectedCall;
auto selectedCalls = ui->tableWidgetCalls->selectedItems(); auto selectedCalls = ui->tableWidgetCalls->selectedItems();
if(!selectedCalls.isEmpty()){ if(!selectedCalls.isEmpty()){
@ -7746,6 +7741,17 @@ void MainWindow::postDecode (bool is_new, QString const& message)
block = logRxTxMessageText(d.utcTimestamp, d.isFree, d.text, d.freq, false, block); block = logRxTxMessageText(d.utcTimestamp, d.isFree, d.text, d.freq, false, block);
m_rxFrameBlockNumbers[freq] = block; m_rxFrameBlockNumbers[freq] = block;
} }
// Transmit Activity
update_dynamic_property (ui->startTxButton, "transmitting", m_transmitting);
if(ui->tableWidgetCalls->selectedItems().isEmpty() && ui->tableWidgetRXAll->selectedItems().isEmpty()){
ui->replyMacroButton->setDisabled(true);
ui->snrMacroButton->setDisabled(true);
} else {
ui->replyMacroButton->setDisabled(false);
ui->snrMacroButton->setDisabled(false);
}
} }
void MainWindow::postWSPRDecode (bool is_new, QStringList parts) void MainWindow::postWSPRDecode (bool is_new, QStringList parts)

View File

@ -738,6 +738,7 @@ private:
void locationChange(QString const& location); void locationChange(QString const& location);
void replayDecodes (); void replayDecodes ();
void postDecode (bool is_new, QString const& message); void postDecode (bool is_new, QString const& message);
void displayActivity();
void postWSPRDecode (bool is_new, QStringList message_parts); void postWSPRDecode (bool is_new, QStringList message_parts);
void enable_DXCC_entity (bool on); void enable_DXCC_entity (bool on);
void switch_mode (Mode); void switch_mode (Mode);