diff --git a/widgets/mainwindow.cpp b/widgets/mainwindow.cpp index 3b7601fa5..6119584ac 100644 --- a/widgets/mainwindow.cpp +++ b/widgets/mainwindow.cpp @@ -1961,9 +1961,9 @@ void MainWindow::on_autoButton_clicked (bool checked) && CALLING == m_QSOProgress) { m_bAutoReply = false; // ready for next m_bCallingCQ = true; // allows tail-enders to be picked up - ui->respondComboBox->setStyleSheet ("QCheckBox{color:red}"); +// ui->respondComboBox->setBackgroundRole(QPalette::BrightText); } else { - ui->respondComboBox->setStyleSheet(""); +// ui->respondComboBox->setBackgroundRole(QPalette::Text); } if (!checked) m_bCallingCQ = false; statusUpdate (); @@ -3521,15 +3521,13 @@ void MainWindow::readFromStdout() //readFromStdout for_us = false; } } - qDebug() << "aa" << m_bCallingCQ << m_bAutoReply << for_us; if(m_bCallingCQ && !m_bAutoReply && for_us && SpecOp::FOX > m_config.special_op_id()) { if(ui->respondComboBox->currentText()=="CQ: First") { m_bDoubleClicked=true; m_bAutoReply = true; processMessage (decodedtext); - ui->respondComboBox->setStyleSheet(""); +// ui->respondComboBox->setBackgroundRole(QPalette::Text); } - qDebug() << "bb" << m_bCallingCQ << m_bAutoReply << for_us; if(ui->respondComboBox->currentText()=="CQ: Max Pts") { QString deCall; QString deGrid; @@ -3541,9 +3539,21 @@ void MainWindow::readFromStdout() //readFromStdout const_cast ((deGrid + " ").left(6).toLatin1 ().constData ()),&utch, &nAz,&nEl,&nDmiles,&nDkm,&nHotAz,&nHotABetter,(FCL)6,(FCL)6); int npts=int((500+nDkm)/500); - if(npts>m_maxPoints) m_maxPoints=npts; - qDebug() << "cc" << decodedtext.string().mid(24,-1).trimmed() - << deGrid << nDkm << npts << m_maxPoints; +// qDebug() << "aa" << decodedtext.string().mid(24,-1).trimmed() +// << deGrid << nDkm << npts << m_maxPoints; + if(npts>m_maxPoints) { + m_maxPoints=npts; + m_deCall=deCall; + m_deGrid=deGrid; + m_bDoubleClicked=true; +// m_bAutoReply = true; +// qDebug() << "bb" << m_bDoubleClicked << m_bAutoReply; + ui->dxCallEntry->setText(deCall); + ui->dxGridEntry->setText(deGrid); + genStdMsgs("-10"); + setTxMsg(3); + } +// qDebug() << "cc" << m_deCall << m_deGrid << npts << m_maxPoints; } } } @@ -4200,9 +4210,9 @@ void MainWindow::guiUpdate() m_maxPoints=-1; if(m_mode=="FT8" or m_mode=="FT4") { if(m_bCallingCQ && ui->respondComboBox->isVisible() && ui->respondComboBox->currentText()!="None") { - ui->respondComboBox->setStyleSheet("QCheckBox{color:red}"); +// ui->respondComboBox->setBackgroundRole(QPalette::BrightText); } else { - ui->respondComboBox->setStyleSheet(""); +// ui->respondComboBox->setBackgroundRole(QPalette::Text); } } @@ -7134,7 +7144,7 @@ void MainWindow::on_stopTxButton_clicked() //Stop Tx m_bCallingCQ = false; m_bAutoReply = false; // ready for next m_maxPoints=-1; - ui->respondComboBox->setStyleSheet (""); +// ui->respondComboBox->setBackgroundRole(QPalette::Text); } void MainWindow::rigOpen () @@ -7372,6 +7382,13 @@ void MainWindow::transmit (double snr) true, false, snr, m_TRperiod); } + if((m_mode=="FT4" or m_mode=="FT8") and m_maxPoints>0 and SpecOp::NA_VHF==m_config.special_op_id()) { + qDebug() << "dd" << m_maxPoints << m_deCall << m_deGrid; + ui->dxCallEntry->setText(m_deCall); + ui->dxGridEntry->setText(m_deGrid); + genStdMsgs("-10"); + } + if (m_mode == "FT8") { // toneSpacing=12000.0/1920.0; toneSpacing=-3; @@ -8573,10 +8590,10 @@ void MainWindow::on_respondComboBox_currentIndexChanged (int n) { if(n>0) { if(m_auto && m_QSOProgress == CALLING) { - ui->respondComboBox->setStyleSheet ("QCheckBox{color:red}"); +// ui->respondComboBox->setBackgroundRole(QPalette::BrightText); } } else { - ui->respondComboBox->setStyleSheet (""); +// ui->respondComboBox->setBackgroundRole(QPalette::Text); } } diff --git a/widgets/mainwindow.h b/widgets/mainwindow.h index 34a898aaf..59b23f49c 100644 --- a/widgets/mainwindow.h +++ b/widgets/mainwindow.h @@ -641,6 +641,8 @@ private: QString m_fileDateTime; QString m_inQSOwith; QString m_BestCQpriority; + QString m_deCall; + QString m_deGrid; QSet m_pfx; QSet m_sfx;