mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2025-03-24 13:08:34 -04:00
Merge branch 'sfox4' into sfox4_b2_otp
This commit is contained in:
commit
2886979717
@ -567,11 +567,11 @@ void DisplayText::setHighlightedHoundText(QString t) {
|
||||
set_colours(m_config, &bg, &fg, types);
|
||||
// t is multiple lines of text, each line is a hound calling
|
||||
// iterate through each line and highlight the callsign
|
||||
auto lines = t.split(QChar('\n'), Qt::SkipEmptyParts);
|
||||
auto lines = t.split(QChar('\n'), SkipEmptyParts);
|
||||
clear();
|
||||
foreach (auto line, lines)
|
||||
{
|
||||
auto fields = line.split(QChar(' '), Qt::SkipEmptyParts);
|
||||
auto fields = line.split(QChar(' '), SkipEmptyParts);
|
||||
insertText(line, bg, fg, fields.first(), QString{});
|
||||
}
|
||||
}
|
||||
|
@ -4007,16 +4007,22 @@ void MainWindow::queueActiveWindowHound2(QString line) {
|
||||
// houndcall rpt grid
|
||||
if (w[7].contains(grid_regexp)) grid = w[7];
|
||||
if (w[7].contains(non_r_db_regexp)) {
|
||||
LOG_INFO(QString("%1 called with signal report %2").arg(caller).arg(w[7]));
|
||||
LOG_INFO(QString("ActiveStations Window click: %1 called with signal report %2").arg(caller).arg(w[7]));
|
||||
}
|
||||
if (caller.length() > 2) {
|
||||
// make sure it's not already in the queue
|
||||
for ( QString hs : m_houndQueue) {
|
||||
if (hs.startsWith(caller)) {
|
||||
LOG_INFO(QString("%1 already in queue. Skipping").arg(hs));
|
||||
//LOG_INFO(QString("ActiveStations Window click: %1 already in queue. Skipping").arg(hs));
|
||||
return;
|
||||
}
|
||||
}
|
||||
// make sure caller is not in fox queue either
|
||||
if(m_foxQSO.contains(caller)) {
|
||||
//LOG_INFO(QString("ActiveStations Window click: %1 already in progress. Skipping").arg(caller));
|
||||
return;
|
||||
}
|
||||
|
||||
QString caller_rpt = (caller+" ").mid(0,12)+db;
|
||||
if (m_houndQueue.count() < MAX_HOUNDS_IN_QUEUE) {
|
||||
// add it to the queue
|
||||
@ -4024,9 +4030,10 @@ void MainWindow::queueActiveWindowHound2(QString line) {
|
||||
refreshHoundQueueDisplay();
|
||||
// TODO: remove from active stations window too?
|
||||
}
|
||||
removeHoundFromCallingList(caller);
|
||||
}
|
||||
} else {
|
||||
LOG_INFO(QString("queueActiveWindowHound2 - skipping %1").arg(line));
|
||||
LOG_INFO(QString("ActiveStations Window click: skipping %1").arg(line));
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -4637,7 +4644,7 @@ void MainWindow::auto_sequence (DecodedText const& message, unsigned start_toler
|
||||
}
|
||||
if (m_auto
|
||||
&& (m_QSOProgress==REPLYING or (!ui->tx1->isEnabled () and m_QSOProgress==REPORT))
|
||||
&& qAbs (ui->TxFreqSpinBox->value () - df) <= int (stop_tolerance)
|
||||
&& !m_config.superFox() && (SpecOp::HOUND != m_specOp) && qAbs (ui->TxFreqSpinBox->value () - df) <= int (stop_tolerance) //
|
||||
&& message_words.at (2) != "DE"
|
||||
&& !message_words.at (2).contains (QRegularExpression {"(^(CQ|QRZ))|" + m_baseCall})
|
||||
&& message_words.at (3).contains (Radio::base_callsign (ui->dxCallEntry->text ()))) {
|
||||
@ -10306,6 +10313,17 @@ QString MainWindow::sortHoundCalls(QString t, int isort, int max_dB)
|
||||
return m_houndCallers;
|
||||
}
|
||||
|
||||
void MainWindow::removeHoundFromCallingList(QString callsign)
|
||||
{
|
||||
QString text = m_houndCallers;
|
||||
QRegularExpression re = QRegularExpression("^" + callsign + "[^\\n]+\\n", QRegularExpression::MultilineOption);
|
||||
text.remove(re);
|
||||
if (text != m_houndCallers) {
|
||||
m_nSortedHounds--;
|
||||
m_houndCallers = text;
|
||||
ui->decodedTextBrowser->setHighlightedHoundText(m_houndCallers);
|
||||
}
|
||||
}
|
||||
//------------------------------------------------------------------------------
|
||||
void MainWindow::selectHound(QString line, bool bTopQueue)
|
||||
{
|
||||
|
@ -876,6 +876,7 @@ private:
|
||||
QChar current_submode () const; // returns QChar {0} if submode is not appropriate
|
||||
void write_transmit_entry (QString const& file_name);
|
||||
void selectHound(QString t, bool bTopQueue);
|
||||
void removeHoundFromCallingList(QString callsign);
|
||||
void houndCallers();
|
||||
void updateFoxQSOsInProgressDisplay();
|
||||
void foxQueueTopCallCommand();
|
||||
|
@ -2348,7 +2348,7 @@ Double-click to reset to the standard 73 message</string>
|
||||
<string>Random</string>
|
||||
</property>
|
||||
<property name="maxVisibleItems">
|
||||
<number>5</number>
|
||||
<number>8</number>
|
||||
</property>
|
||||
<item>
|
||||
<property name="text">
|
||||
|
Loading…
Reference in New Issue
Block a user