kopia lustrzana https://gitlab.com/eliggett/wfview
Force queue parent to be wfmain()
rodzic
6150ffb320
commit
a8815c5afd
|
@ -12,7 +12,7 @@ bandbuttons::bandbuttons(QWidget *parent) :
|
|||
ui->bandStkCWBtn->setVisible(false);
|
||||
this->setWindowTitle("Band Switcher");
|
||||
this->setObjectName("bandButtons");
|
||||
queue = cachingQueue::getInstance(this);
|
||||
queue = cachingQueue::getInstance();
|
||||
connect(queue, SIGNAL(rigCapsUpdated(rigCapabilities*)), this, SLOT(receiveRigCaps(rigCapabilities*)));
|
||||
connect(queue,SIGNAL(cacheUpdated(cacheItem)),this,SLOT(receiveCache(cacheItem)));
|
||||
|
||||
|
|
|
@ -19,7 +19,7 @@ cwSender::cwSender(QWidget *parent) :
|
|||
this->setToolTipDuration(3000);
|
||||
connect(ui->textToSendEdit->lineEdit(), &QLineEdit::textEdited, this, &cwSender::textChanged);
|
||||
this->setObjectName("CW Sender");
|
||||
queue = cachingQueue::getInstance(this);
|
||||
queue = cachingQueue::getInstance();
|
||||
|
||||
connect(this, &cwSender::sendCW, queue, [=](const QString &cwMessage) {
|
||||
queue->add(priorityImmediate,queueItem(funcSendCW,QVariant::fromValue<QString>(cwMessage)));
|
||||
|
|
|
@ -9,7 +9,7 @@ frequencyinputwidget::frequencyinputwidget(QWidget *parent) :
|
|||
this->setWindowTitle("Frequency Input");
|
||||
ui->freqMhzLineEdit->setValidator( new QDoubleValidator(0, 100, 6, this));
|
||||
this->setObjectName("freq Input");
|
||||
queue = cachingQueue::getInstance(this);
|
||||
queue = cachingQueue::getInstance();
|
||||
}
|
||||
|
||||
frequencyinputwidget::~frequencyinputwidget()
|
||||
|
|
|
@ -18,7 +18,7 @@ memories::memories(bool isAdmin, bool slowLoad, QWidget *parent) :
|
|||
progress = new QProgressBar(this);
|
||||
statusBar->addWidget(progress,1);
|
||||
this->setObjectName("memories");
|
||||
queue = cachingQueue::getInstance(this);
|
||||
queue = cachingQueue::getInstance();
|
||||
rigCaps = queue->getRigCaps();
|
||||
if (!isAdmin)
|
||||
{
|
||||
|
|
|
@ -18,7 +18,7 @@ pttyHandler::pttyHandler(QString pty, QObject* parent) : QObject(parent)
|
|||
//constructor
|
||||
|
||||
this->setObjectName("pttyHandler");
|
||||
queue = cachingQueue::getInstance(this);
|
||||
queue = cachingQueue::getInstance();
|
||||
connect(queue, SIGNAL(rigCapsUpdated(rigCapabilities*)), this, SLOT(receiveRigCaps(rigCapabilities*)));
|
||||
rigCaps = queue->getRigCaps();
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@ repeaterSetup::repeaterSetup(QWidget *parent) :
|
|||
ui->setupUi(this);
|
||||
|
||||
this->setObjectName("RepeaterSetup");
|
||||
queue = cachingQueue::getInstance(this);
|
||||
queue = cachingQueue::getInstance();
|
||||
connect(queue, SIGNAL(rigCapsUpdated(rigCapabilities*)), this, SLOT(receiveRigCaps(rigCapabilities*)));
|
||||
|
||||
ui->autoTrackLiveBtn->setEnabled(false); // until we set split enabled.
|
||||
|
@ -24,11 +24,7 @@ repeaterSetup::~repeaterSetup()
|
|||
{
|
||||
// Trying this for more consistent destruction
|
||||
delete ui;
|
||||
if(queue) {
|
||||
qDebug() << "Deleting the queue from within repeaterSetup.";
|
||||
queue->deleteLater();
|
||||
queue=nullptr;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void repeaterSetup::populateTones()
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
rigCommander::rigCommander(QObject* parent) : QObject(parent)
|
||||
{
|
||||
qInfo(logRig()) << "creating instance of rigCommander()";
|
||||
queue = cachingQueue::getInstance(this);
|
||||
queue = cachingQueue::getInstance();
|
||||
|
||||
}
|
||||
|
||||
|
@ -22,7 +22,7 @@ rigCommander::rigCommander(quint8 guid[GUIDLEN], QObject* parent) : QObject(pare
|
|||
qInfo(logRig()) << "creating instance of rigCommander(guid)";
|
||||
memcpy(this->guid, guid, GUIDLEN);
|
||||
// Add some commands that is a minimum for rig detection
|
||||
queue = cachingQueue::getInstance(this);
|
||||
queue = cachingQueue::getInstance();
|
||||
}
|
||||
|
||||
rigCommander::~rigCommander()
|
||||
|
|
|
@ -320,7 +320,7 @@ rigCtlClient::rigCtlClient(int socketId, rigCtlD* parent) : QObject(parent)
|
|||
{
|
||||
|
||||
this->setObjectName("RigCtlD");
|
||||
queue = cachingQueue::getInstance(this);
|
||||
queue = cachingQueue::getInstance();
|
||||
connect(queue, SIGNAL(rigCapsUpdated(rigCapabilities*)), this, SLOT(receiveRigCaps(rigCapabilities*)));
|
||||
rigCaps = queue->getRigCaps();
|
||||
commandBuffer.clear();
|
||||
|
|
|
@ -113,7 +113,7 @@ void tciServer::init(quint16 port) {
|
|||
}
|
||||
|
||||
this->setObjectName("TCI Server");
|
||||
queue = cachingQueue::getInstance(this);
|
||||
queue = cachingQueue::getInstance();
|
||||
rigCaps = queue->getRigCaps();
|
||||
|
||||
connect(queue,SIGNAL(cacheUpdated(cacheItem)),this,SLOT(receiveCache(cacheItem)));
|
||||
|
|
|
@ -427,6 +427,13 @@ wfmain::~wfmain()
|
|||
#endif
|
||||
|
||||
logStream->flush();
|
||||
|
||||
// As this is the end of everything, finally delete the queue.
|
||||
if(queue) {
|
||||
qDebug() << "Deleting the queue from within wfmain().";
|
||||
queue->deleteLater();
|
||||
queue=nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
void wfmain::closeEvent(QCloseEvent *event)
|
||||
|
|
Ładowanie…
Reference in New Issue