Merge branch 'master' into QT6.2

half-duplex
Phil Taylor 2021-08-28 00:22:38 +01:00
commit b7407fc108
8 zmienionych plików z 28 dodań i 20 usunięć

6
.gitmodules vendored
Wyświetl plik

@ -1,6 +0,0 @@
[submodule "opus-tools"]
path = opus-tools
url = https://github.com/xiph/opus-tools.git
[submodule "rtaudio"]
path = rtaudio
url = https://github.com/thestk/rtaudio.git

Wyświetl plik

@ -12,7 +12,7 @@ aboutbox::aboutbox(QWidget *parent) :
ui->logoBtn->setIcon(QIcon(":resources/wfview.png"));
ui->logoBtn->setStyleSheet("Text-align:left");
ui->topText->setText("wfview version 1.1");
ui->topText->setText("wfview version 1.2a");
QString head = QString("<html><head></head><body>");
QString copyright = QString("Copyright 2017-2021 Elliott H. Liggett, W6EL. All rights reserved. wfview source code is <a href=\"https://gitlab.com/eliggett/wfview/-/blob/master/LICENSE\">licensed</a> under the GNU GPLv3.");

@ -1 +0,0 @@
Subproject commit ae5d6d59e82ef40300a4dece7897499685f87184

Wyświetl plik

@ -8,6 +8,7 @@
#include <fcntl.h>
#include <sys/ioctl.h>
#include <unistd.h>
#include <errno.h>
#endif
// Copyright 2017-2021 Elliott H. Liggett & Phil Taylor

@ -1 +0,0 @@
Subproject commit c9bf99d414cf81d19ef0ddd00212a4a58ccd99c6

Wyświetl plik

@ -404,9 +404,11 @@ void udpServer::controlReceived()
inAudio.samplerate = current->rxSampleRate;
rxaudio = new audioHandler();
rxAudioThread = new QThread(this);
rxaudio->moveToThread(rxAudioThread);
rxaudio->moveToThread(rxAudioThread);
rxAudioThread->start(QThread::TimeCriticalPriority);
connect(this, SIGNAL(setupRxAudio(audioSetup)), rxaudio, SLOT(init(audioSetup)));

Wyświetl plik

@ -689,14 +689,11 @@ void wfmain::setupMainUI()
ui->meter2selectionCombo->addItem("Center", meterCenter);
ui->meter2Widget->hide();
#ifdef QT_DEBUG
// Experimental feature:
ui->meter2selectionCombo->show();
ui->meter2selectionCombo->setCurrentIndex((int)prefs.meter2Type);
ui->secondaryMeterSelectionLabel->show();
#else
ui->meter2selectionCombo->hide();
ui->secondaryMeterSelectionLabel->hide();
#endif
// Future ideas:
//ui->meter2selectionCombo->addItem("Transmit Audio", meterTxMod);
@ -1266,6 +1263,7 @@ void wfmain::setDefPrefs()
defPrefs.wftheme = static_cast<int>(QCPColorGradient::gpJet);
defPrefs.confirmExit = true;
defPrefs.confirmPowerOff = true;
defPrefs.meter2Type = meterNone;
udpDefPrefs.ipAddress = QString("");
udpDefPrefs.controlLANPort = 50001;
@ -1299,7 +1297,7 @@ void wfmain::loadSettings()
setWindowState(Qt::WindowActive); // Works around QT bug to returns window+keyboard focus.
prefs.confirmExit = settings->value("ConfirmExit", defPrefs.confirmExit).toBool();
prefs.confirmPowerOff = settings->value("ConfirmPowerOff", defPrefs.confirmPowerOff).toBool();
prefs.meter2Type = static_cast<meterKind>(settings->value("Meter2Type", defPrefs.meter2Type).toInt());
settings->endGroup();
// Load color schemes:
@ -1600,6 +1598,7 @@ void wfmain::saveSettings()
settings->setValue("WFLength", prefs.wflength);
settings->setValue("ConfirmExit", prefs.confirmExit);
settings->setValue("ConfirmPowerOff", prefs.confirmPowerOff);
settings->setValue("Meter2Type", (int)prefs.meter2Type);
settings->endGroup();
// Radio and Comms: C-IV addr, port to use
@ -3033,6 +3032,18 @@ void wfmain::receiveRigID(rigCapabilities rigCaps)
// recalculate command timing now that we know the rig better:
calculateTimingParameters();
initPeriodicCommands();
// Set the second meter here as I suspect we need to be connected for it to work?
for (int i = 0; i < ui->meter2selectionCombo->count(); i++)
{
if (static_cast<meterKind>(ui->meter2selectionCombo->itemData(i).toInt()) == prefs.meter2Type)
{
// I thought that setCurrentIndex() would call the activated() function for the combobox
// but it doesn't, so call it manually.
ui->meter2selectionCombo->setCurrentIndex(i);
on_meter2selectionCombo_activated(i);
}
}
}
}
@ -3248,9 +3259,9 @@ void wfmain::receiveSpectrumData(QByteArray spectrum, double startFreq, double e
void wfmain::receiveSpectrumMode(spectrumMode spectMode)
{
for(int i=0; i < ui->spectrumModeCombo->count(); i++)
for (int i = 0; i < ui->spectrumModeCombo->count(); i++)
{
if(static_cast<spectrumMode>(ui->spectrumModeCombo->itemData(i).toInt()) == spectMode)
if (static_cast<spectrumMode>(ui->spectrumModeCombo->itemData(i).toInt()) == spectMode)
{
ui->spectrumModeCombo->blockSignals(true);
ui->spectrumModeCombo->setCurrentIndex(i);
@ -5271,7 +5282,6 @@ void wfmain::on_meter2selectionCombo_activated(int index)
meterKind oldMeterType;
newMeterType = static_cast<meterKind>(ui->meter2selectionCombo->currentData().toInt());
oldMeterType = ui->meter2Widget->getMeterType();
if(newMeterType == oldMeterType)
return;
@ -5289,6 +5299,8 @@ void wfmain::on_meter2selectionCombo_activated(int index)
ui->meter2Widget->setMeterType(newMeterType);
insertPeriodicCommandUnique(newCmd);
}
prefs.meter2Type = newMeterType;
(void)index;
}

Wyświetl plik

@ -704,6 +704,7 @@ private:
int wftheme;
bool confirmExit;
bool confirmPowerOff;
meterKind meter2Type;
// plot scheme
} prefs;