diff --git a/plugins/channelrx/chanalyzer/chanalyzergui.cpp b/plugins/channelrx/chanalyzer/chanalyzergui.cpp index dbb6c9e6d..55a922cf1 100644 --- a/plugins/channelrx/chanalyzer/chanalyzergui.cpp +++ b/plugins/channelrx/chanalyzer/chanalyzergui.cpp @@ -29,7 +29,7 @@ #include "plugin/pluginapi.h" #include "util/simpleserializer.h" #include "util/db.h" -#include "mainwindow.h" +#include "maincore.h" #include "ui_chanalyzergui.h" #include "chanalyzer.h" @@ -392,9 +392,9 @@ ChannelAnalyzerGUI::ChannelAnalyzerGUI(PluginAPI* pluginAPI, DeviceUISet *device ui->glSpectrum->setSsbSpectrum(false); ui->glSpectrum->setLsbDisplay(false); - ui->glSpectrum->connectTimer(MainWindow::getInstance()->getMasterTimer()); - ui->glScope->connectTimer(MainWindow::getInstance()->getMasterTimer()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + ui->glSpectrum->connectTimer(MainCore::instance()->getMasterTimer()); + ui->glScope->connectTimer(MainCore::instance()->getMasterTimer()); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); m_channelMarker.blockSignals(true); m_channelMarker.setColor(Qt::gray); diff --git a/plugins/channelrx/demodam/amdemodgui.cpp b/plugins/channelrx/demodam/amdemodgui.cpp index bcefce9ac..f806ffd03 100644 --- a/plugins/channelrx/demodam/amdemodgui.cpp +++ b/plugins/channelrx/demodam/amdemodgui.cpp @@ -31,9 +31,9 @@ #include "gui/basicchannelsettingsdialog.h" #include "gui/devicestreamselectiondialog.h" #include "dsp/dspengine.h" -#include "mainwindow.h" #include "gui/crightclickenabler.h" #include "gui/audioselectdialog.h" +#include "maincore.h" #include "amdemod.h" @@ -247,7 +247,7 @@ AMDemodGUI::AMDemodGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, BasebandS m_amDemod = reinterpret_cast(rxChannel); //new AMDemod(m_deviceUISet->m_deviceSourceAPI); m_amDemod->setMessageQueueToGUI(getInputMessageQueue()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); // 50 ms + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); // 50 ms CRightClickEnabler *audioMuteRightClickEnabler = new CRightClickEnabler(ui->audioMute); connect(audioMuteRightClickEnabler, SIGNAL(rightClick(const QPoint &)), this, SLOT(audioSelect())); diff --git a/plugins/channelrx/demodatv/atvdemodgui.cpp b/plugins/channelrx/demodatv/atvdemodgui.cpp index c310670ec..fcdd6c851 100644 --- a/plugins/channelrx/demodatv/atvdemodgui.cpp +++ b/plugins/channelrx/demodatv/atvdemodgui.cpp @@ -28,7 +28,7 @@ #include "util/simpleserializer.h" #include "util/db.h" #include "dsp/dspengine.h" -#include "mainwindow.h" +#include "maincore.h" #include "atvdemod.h" @@ -227,8 +227,8 @@ ATVDemodGUI::ATVDemodGUI(PluginAPI* objPluginAPI, DeviceUISet *deviceUISet, Base m_atvDemod->setScopeSink(m_scopeVis); m_atvDemod->setTVScreen(ui->screenTV); - ui->glScope->connectTimer(MainWindow::getInstance()->getMasterTimer()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); // 50 ms + ui->glScope->connectTimer(MainCore::instance()->getMasterTimer()); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); // 50 ms ui->deltaFrequencyLabel->setText(QString("%1f").arg(QChar(0x94, 0x03))); ui->deltaFrequency->setColorMapper(ColorMapper(ColorMapper::GrayGold)); diff --git a/plugins/channelrx/demodbfm/bfmdemodgui.cpp b/plugins/channelrx/demodbfm/bfmdemodgui.cpp index 039d313f4..c4ad2408b 100644 --- a/plugins/channelrx/demodbfm/bfmdemodgui.cpp +++ b/plugins/channelrx/demodbfm/bfmdemodgui.cpp @@ -37,7 +37,7 @@ #include "gui/devicestreamselectiondialog.h" #include "gui/crightclickenabler.h" #include "gui/audioselectdialog.h" -#include "mainwindow.h" +#include "maincore.h" #include "bfmdemodreport.h" #include "bfmdemodsettings.h" @@ -385,7 +385,7 @@ BFMDemodGUI::BFMDemodGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, Baseban FFTWindow::BlackmanHarris, false // logarithmic scale ); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); m_channelMarker.blockSignals(true); m_channelMarker.setColor(m_settings.m_rgbColor); diff --git a/plugins/channelrx/demoddsd/dsddemodgui.cpp b/plugins/channelrx/demoddsd/dsddemodgui.cpp index 70490c71c..8b6ecc342 100644 --- a/plugins/channelrx/demoddsd/dsddemodgui.cpp +++ b/plugins/channelrx/demoddsd/dsddemodgui.cpp @@ -30,7 +30,7 @@ #include "gui/crightclickenabler.h" #include "gui/audioselectdialog.h" #include "dsp/dspengine.h" -#include "mainwindow.h" +#include "maincore.h" #include "dsddemodbaudrates.h" #include "dsddemod.h" @@ -349,7 +349,7 @@ DSDDemodGUI::DSDDemodGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, Baseban m_dsdDemod->setScopeXYSink(m_scopeVisXY); m_dsdDemod->setMessageQueueToGUI(getInputMessageQueue()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); ui->audioMute->setStyleSheet("QToolButton { background:rgb(79,79,79); }"); @@ -387,8 +387,8 @@ DSDDemodGUI::~DSDDemodGUI() void DSDDemodGUI::updateMyPosition() { - float latitude = MainWindow::getInstance()->getMainSettings().getLatitude(); - float longitude = MainWindow::getInstance()->getMainSettings().getLongitude(); + float latitude = MainCore::instance()->getSettings().getLatitude(); + float longitude = MainCore::instance()->getSettings().getLongitude(); if ((m_myLatitude != latitude) || (m_myLongitude != longitude)) { diff --git a/plugins/channelrx/demodfreedv/freedvdemodgui.cpp b/plugins/channelrx/demodfreedv/freedvdemodgui.cpp index 2c74f52f4..d8b7f826f 100644 --- a/plugins/channelrx/demodfreedv/freedvdemodgui.cpp +++ b/plugins/channelrx/demodfreedv/freedvdemodgui.cpp @@ -32,7 +32,7 @@ #include "util/db.h" #include "gui/crightclickenabler.h" #include "gui/audioselectdialog.h" -#include "mainwindow.h" +#include "maincore.h" #include "ui_freedvdemodgui.h" #include "freedvdemod.h" @@ -267,9 +267,9 @@ FreeDVDemodGUI::FreeDVDemodGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, B ui->glSpectrum->setDisplayWaterfall(true); ui->glSpectrum->setDisplayMaxHold(true); ui->glSpectrum->setSsbSpectrum(true); - ui->glSpectrum->connectTimer(MainWindow::getInstance()->getMasterTimer()); + ui->glSpectrum->connectTimer(MainCore::instance()->getMasterTimer()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); CRightClickEnabler *audioMuteRightClickEnabler = new CRightClickEnabler(ui->audioMute); connect(audioMuteRightClickEnabler, SIGNAL(rightClick(const QPoint &)), this, SLOT(audioSelect())); diff --git a/plugins/channelrx/demodnfm/nfmdemodgui.cpp b/plugins/channelrx/demodnfm/nfmdemodgui.cpp index 08963b9fc..6dd33e67a 100644 --- a/plugins/channelrx/demodnfm/nfmdemodgui.cpp +++ b/plugins/channelrx/demodnfm/nfmdemodgui.cpp @@ -12,7 +12,7 @@ #include "gui/crightclickenabler.h" #include "gui/audioselectdialog.h" #include "dsp/dspengine.h" -#include "mainwindow.h" +#include "maincore.h" #include "nfmdemodreport.h" #include "nfmdemod.h" @@ -274,7 +274,7 @@ NFMDemodGUI::NFMDemodGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, Baseban m_nfmDemod = reinterpret_cast(rxChannel); //new NFMDemod(m_deviceUISet->m_deviceSourceAPI); m_nfmDemod->setMessageQueueToGUI(getInputMessageQueue()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); CRightClickEnabler *audioMuteRightClickEnabler = new CRightClickEnabler(ui->audioMute); connect(audioMuteRightClickEnabler, SIGNAL(rightClick(const QPoint &)), this, SLOT(audioSelect())); diff --git a/plugins/channelrx/demodssb/ssbdemodgui.cpp b/plugins/channelrx/demodssb/ssbdemodgui.cpp index de80982aa..edd3d72b1 100644 --- a/plugins/channelrx/demodssb/ssbdemodgui.cpp +++ b/plugins/channelrx/demodssb/ssbdemodgui.cpp @@ -16,7 +16,7 @@ #include "util/db.h" #include "gui/crightclickenabler.h" #include "gui/audioselectdialog.h" -#include "mainwindow.h" +#include "maincore.h" #include "ssbdemod.h" SSBDemodGUI* SSBDemodGUI::create(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, BasebandSampleSink *rxChannel) @@ -305,9 +305,9 @@ SSBDemodGUI::SSBDemodGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, Baseban ui->glSpectrum->setDisplayWaterfall(true); ui->glSpectrum->setDisplayMaxHold(true); ui->glSpectrum->setSsbSpectrum(true); - ui->glSpectrum->connectTimer(MainWindow::getInstance()->getMasterTimer()); + ui->glSpectrum->connectTimer(MainCore::instance()->getMasterTimer()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); m_channelMarker.blockSignals(true); m_channelMarker.setColor(Qt::green); diff --git a/plugins/channelrx/demodwfm/wfmdemodgui.cpp b/plugins/channelrx/demodwfm/wfmdemodgui.cpp index 16ec4b152..1d203a784 100644 --- a/plugins/channelrx/demodwfm/wfmdemodgui.cpp +++ b/plugins/channelrx/demodwfm/wfmdemodgui.cpp @@ -15,7 +15,7 @@ #include "gui/devicestreamselectiondialog.h" #include "gui/crightclickenabler.h" #include "gui/audioselectdialog.h" -#include "mainwindow.h" +#include "maincore.h" #include "wfmdemod.h" @@ -210,7 +210,7 @@ WFMDemodGUI::WFMDemodGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, Baseban m_wfmDemod = (WFMDemod*) rxChannel; //new WFMDemod(m_deviceUISet->m_deviceSourceAPI); m_wfmDemod->setMessageQueueToGUI(getInputMessageQueue()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); CRightClickEnabler *audioMuteRightClickEnabler = new CRightClickEnabler(ui->audioMute); connect(audioMuteRightClickEnabler, SIGNAL(rightClick(const QPoint &)), this, SLOT(audioSelect())); diff --git a/plugins/channelrx/freqtracker/freqtrackergui.cpp b/plugins/channelrx/freqtracker/freqtrackergui.cpp index 7d6f45e53..def0b96ab 100644 --- a/plugins/channelrx/freqtracker/freqtrackergui.cpp +++ b/plugins/channelrx/freqtracker/freqtrackergui.cpp @@ -31,9 +31,9 @@ #include "gui/basicchannelsettingsdialog.h" #include "gui/devicestreamselectiondialog.h" #include "dsp/dspengine.h" -#include "mainwindow.h" #include "gui/crightclickenabler.h" #include "gui/audioselectdialog.h" +#include "maincore.h" #include "freqtracker.h" #include "freqtrackerreport.h" @@ -301,7 +301,7 @@ FreqTrackerGUI::FreqTrackerGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, B m_freqTracker = reinterpret_cast(rxChannel); //new FreqTracker(m_deviceUISet->m_deviceSourceAPI); m_freqTracker->setMessageQueueToGUI(getInputMessageQueue()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); // 50 ms + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); // 50 ms ui->deltaFrequencyLabel->setText(QString("%1f").arg(QChar(0x94, 0x03))); ui->deltaFrequency->setColorMapper(ColorMapper(ColorMapper::GrayGold)); diff --git a/plugins/channelrx/udpsink/udpsinkgui.cpp b/plugins/channelrx/udpsink/udpsinkgui.cpp index 638177259..cc2dfbd41 100644 --- a/plugins/channelrx/udpsink/udpsinkgui.cpp +++ b/plugins/channelrx/udpsink/udpsinkgui.cpp @@ -25,7 +25,7 @@ #include "gui/basicchannelsettingsdialog.h" #include "gui/devicestreamselectiondialog.h" #include "ui_udpsinkgui.h" -#include "mainwindow.h" +#include "maincore.h" #include "udpsink.h" #include "udpsinkgui.h" @@ -177,8 +177,8 @@ UDPSinkGUI::UDPSinkGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, BasebandS false // logarithmic scale ); - ui->glSpectrum->connectTimer(MainWindow::getInstance()->getMasterTimer()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + ui->glSpectrum->connectTimer(MainCore::instance()->getMasterTimer()); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); m_channelMarker.blockSignals(true); m_channelMarker.setBandwidth(16000); diff --git a/plugins/channeltx/mod802.15.4/ieee_802_15_4_modgui.cpp b/plugins/channeltx/mod802.15.4/ieee_802_15_4_modgui.cpp index 68239bbb4..ff9067a3d 100644 --- a/plugins/channeltx/mod802.15.4/ieee_802_15_4_modgui.cpp +++ b/plugins/channeltx/mod802.15.4/ieee_802_15_4_modgui.cpp @@ -34,7 +34,7 @@ #include "gui/crightclickenabler.h" #include "gui/basicchannelsettingsdialog.h" #include "gui/devicestreamselectiondialog.h" -#include "mainwindow.h" +#include "maincore.h" #include "ui_ieee_802_15_4_modgui.h" #include "ieee_802_15_4_modgui.h" @@ -338,12 +338,12 @@ IEEE_802_15_4_ModGUI::IEEE_802_15_4_ModGUI(PluginAPI* pluginAPI, DeviceUISet *de m_IEEE_802_15_4_Mod = (IEEE_802_15_4_Mod*) channelTx; m_IEEE_802_15_4_Mod->setMessageQueueToGUI(getInputMessageQueue()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); m_scopeVis = new ScopeVis(ui->glScope); m_IEEE_802_15_4_Mod->setScopeSink(m_scopeVis); - ui->glScope->connectTimer(MainWindow::getInstance()->getMasterTimer()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); // 50 ms + ui->glScope->connectTimer(MainCore::instance()->getMasterTimer()); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); // 50 ms ui->scopeGUI->setBuddies(m_scopeVis->getInputMessageQueue(), m_scopeVis, ui->glScope); // Scope settings to display the IQ waveforms @@ -385,7 +385,7 @@ IEEE_802_15_4_ModGUI::IEEE_802_15_4_ModGUI(PluginAPI* pluginAPI, DeviceUISet *de ui->glSpectrum->setDisplayWaterfall(false); ui->glSpectrum->setDisplayMaxHold(false); ui->glSpectrum->setDisplayHistogram(false); - ui->glSpectrum->connectTimer(MainWindow::getInstance()->getMasterTimer()); + ui->glSpectrum->connectTimer(MainCore::instance()->getMasterTimer()); CRightClickEnabler *repeatRightClickEnabler = new CRightClickEnabler(ui->repeat); connect(repeatRightClickEnabler, SIGNAL(rightClick(const QPoint &)), this, SLOT(repeatSelect())); diff --git a/plugins/channeltx/modam/ammodgui.cpp b/plugins/channeltx/modam/ammodgui.cpp index a6ce632ae..b99fe7305 100644 --- a/plugins/channeltx/modam/ammodgui.cpp +++ b/plugins/channeltx/modam/ammodgui.cpp @@ -32,7 +32,7 @@ #include "gui/audioselectdialog.h" #include "gui/basicchannelsettingsdialog.h" #include "gui/devicestreamselectiondialog.h" -#include "mainwindow.h" +#include "maincore.h" #include "ui_ammodgui.h" #include "ammodgui.h" @@ -339,7 +339,7 @@ AMModGUI::AMModGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, BasebandSampl m_amMod = (AMMod*) channelTx; //new AMMod(m_deviceUISet->m_deviceSinkAPI); m_amMod->setMessageQueueToGUI(getInputMessageQueue()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); CRightClickEnabler *audioMuteRightClickEnabler = new CRightClickEnabler(ui->mic); connect(audioMuteRightClickEnabler, SIGNAL(rightClick(const QPoint &)), this, SLOT(audioSelect())); diff --git a/plugins/channeltx/modatv/atvmodgui.cpp b/plugins/channeltx/modatv/atvmodgui.cpp index 255822c5e..5bc8b1ea1 100644 --- a/plugins/channeltx/modatv/atvmodgui.cpp +++ b/plugins/channeltx/modatv/atvmodgui.cpp @@ -31,7 +31,7 @@ #include "util/db.h" #include "gui/basicchannelsettingsdialog.h" #include "gui/devicestreamselectiondialog.h" -#include "mainwindow.h" +#include "maincore.h" #include "ui_atvmodgui.h" #include "atvmodgui.h" @@ -72,7 +72,7 @@ ATVModGUI::ATVModGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, BasebandSam m_atvMod->setMessageQueueToGUI(getInputMessageQueue()); m_atvMod->propagateMessageQueueToGUI(); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); ui->deltaFrequencyLabel->setText(QString("%1f").arg(QChar(0x94, 0x03))); ui->deltaFrequency->setColorMapper(ColorMapper(ColorMapper::GrayGold)); diff --git a/plugins/channeltx/modfreedv/freedvmodgui.cpp b/plugins/channeltx/modfreedv/freedvmodgui.cpp index afef3f2dd..b5d2fb7c7 100644 --- a/plugins/channeltx/modfreedv/freedvmodgui.cpp +++ b/plugins/channeltx/modfreedv/freedvmodgui.cpp @@ -35,7 +35,7 @@ #include "gui/audioselectdialog.h" #include "gui/basicchannelsettingsdialog.h" #include "gui/devicestreamselectiondialog.h" -#include "mainwindow.h" +#include "maincore.h" #include "ui_freedvmodgui.h" FreeDVModGUI* FreeDVModGUI::create(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, BasebandSampleSource *channelTx) @@ -361,9 +361,9 @@ FreeDVModGUI::FreeDVModGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, Baseb ui->glSpectrum->setDisplayWaterfall(true); ui->glSpectrum->setDisplayMaxHold(true); ui->glSpectrum->setSsbSpectrum(true); - ui->glSpectrum->connectTimer(MainWindow::getInstance()->getMasterTimer()); + ui->glSpectrum->connectTimer(MainCore::instance()->getMasterTimer()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); CRightClickEnabler *audioMuteRightClickEnabler = new CRightClickEnabler(ui->mic); connect(audioMuteRightClickEnabler, SIGNAL(rightClick(const QPoint &)), this, SLOT(audioSelect())); diff --git a/plugins/channeltx/modnfm/nfmmodgui.cpp b/plugins/channeltx/modnfm/nfmmodgui.cpp index 48a1ce28c..606b6fe41 100644 --- a/plugins/channeltx/modnfm/nfmmodgui.cpp +++ b/plugins/channeltx/modnfm/nfmmodgui.cpp @@ -31,7 +31,7 @@ #include "gui/audioselectdialog.h" #include "gui/basicchannelsettingsdialog.h" #include "gui/devicestreamselectiondialog.h" -#include "mainwindow.h" +#include "maincore.h" #include "ui_nfmmodgui.h" #include "nfmmodgui.h" @@ -368,7 +368,7 @@ NFMModGUI::NFMModGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, BasebandSam m_nfmMod = (NFMMod*) channelTx; //new NFMMod(m_deviceUISet->m_deviceSinkAPI); m_nfmMod->setMessageQueueToGUI(getInputMessageQueue()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); CRightClickEnabler *audioMuteRightClickEnabler = new CRightClickEnabler(ui->mic); connect(audioMuteRightClickEnabler, SIGNAL(rightClick(const QPoint &)), this, SLOT(audioSelect())); diff --git a/plugins/channeltx/modpacket/packetmodgui.cpp b/plugins/channeltx/modpacket/packetmodgui.cpp index 19b8b4076..82bed0f53 100644 --- a/plugins/channeltx/modpacket/packetmodgui.cpp +++ b/plugins/channeltx/modpacket/packetmodgui.cpp @@ -33,7 +33,7 @@ #include "gui/basicchannelsettingsdialog.h" #include "gui/devicestreamselectiondialog.h" #include "gui/fmpreemphasisdialog.h" -#include "mainwindow.h" +#include "maincore.h" #include "ui_packetmodgui.h" #include "packetmodgui.h" @@ -208,8 +208,8 @@ void PacketModGUI::on_packet_editingFinished() void PacketModGUI::on_insertPosition_clicked(bool checked) { - float latitude = MainWindow::getInstance()->getMainSettings().getLatitude(); - float longitude = MainWindow::getInstance()->getMainSettings().getLongitude(); + float latitude = MainCore::instance()->getSettings().getLatitude(); + float longitude = MainCore::instance()->getSettings().getLongitude(); int latDeg, latMin, latFrac, latNorth; int longDeg, longMin, longFrac, longEast; @@ -406,7 +406,7 @@ PacketModGUI::PacketModGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, Baseb m_packetMod = (PacketMod*) channelTx; m_packetMod->setMessageQueueToGUI(getInputMessageQueue()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); m_spectrumVis = m_packetMod->getSpectrumVis(); m_spectrumVis->setGLSpectrum(ui->glSpectrum); @@ -420,7 +420,7 @@ PacketModGUI::PacketModGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, Baseb ui->glSpectrum->setDisplayWaterfall(false); ui->glSpectrum->setDisplayMaxHold(false); ui->glSpectrum->setDisplayHistogram(false); - ui->glSpectrum->connectTimer(MainWindow::getInstance()->getMasterTimer()); + ui->glSpectrum->connectTimer(MainCore::instance()->getMasterTimer()); CRightClickEnabler *repeatRightClickEnabler = new CRightClickEnabler(ui->repeat); connect(repeatRightClickEnabler, SIGNAL(rightClick(const QPoint &)), this, SLOT(repeatSelect())); diff --git a/plugins/channeltx/modssb/ssbmodgui.cpp b/plugins/channeltx/modssb/ssbmodgui.cpp index 8419bd35d..5178c1772 100644 --- a/plugins/channeltx/modssb/ssbmodgui.cpp +++ b/plugins/channeltx/modssb/ssbmodgui.cpp @@ -36,7 +36,7 @@ #include "gui/audioselectdialog.h" #include "gui/basicchannelsettingsdialog.h" #include "gui/devicestreamselectiondialog.h" -#include "mainwindow.h" +#include "maincore.h" SSBModGUI* SSBModGUI::create(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, BasebandSampleSource *channelTx) { @@ -412,9 +412,9 @@ SSBModGUI::SSBModGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, BasebandSam ui->glSpectrum->setDisplayWaterfall(true); ui->glSpectrum->setDisplayMaxHold(true); ui->glSpectrum->setSsbSpectrum(true); - ui->glSpectrum->connectTimer(MainWindow::getInstance()->getMasterTimer()); + ui->glSpectrum->connectTimer(MainCore::instance()->getMasterTimer()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); CRightClickEnabler *audioMuteRightClickEnabler = new CRightClickEnabler(ui->mic); connect(audioMuteRightClickEnabler, SIGNAL(rightClick(const QPoint &)), this, SLOT(audioSelect())); diff --git a/plugins/channeltx/modwfm/wfmmodgui.cpp b/plugins/channeltx/modwfm/wfmmodgui.cpp index f7f30225c..7886aea7e 100644 --- a/plugins/channeltx/modwfm/wfmmodgui.cpp +++ b/plugins/channeltx/modwfm/wfmmodgui.cpp @@ -32,7 +32,7 @@ #include "gui/audioselectdialog.h" #include "gui/basicchannelsettingsdialog.h" #include "gui/devicestreamselectiondialog.h" -#include "mainwindow.h" +#include "maincore.h" #include "ui_wfmmodgui.h" #include "wfmmodgui.h" @@ -357,7 +357,7 @@ WFMModGUI::WFMModGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, BasebandSam m_wfmMod = (WFMMod*) channelTx; //new WFMMod(m_deviceUISet->m_deviceSinkAPI); m_wfmMod->setMessageQueueToGUI(getInputMessageQueue()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); CRightClickEnabler *audioMuteRightClickEnabler = new CRightClickEnabler(ui->mic); connect(audioMuteRightClickEnabler, SIGNAL(rightClick(const QPoint &)), this, SLOT(audioSelect())); diff --git a/plugins/channeltx/udpsource/udpsourcegui.cpp b/plugins/channeltx/udpsource/udpsourcegui.cpp index d939191e8..46a724307 100644 --- a/plugins/channeltx/udpsource/udpsourcegui.cpp +++ b/plugins/channeltx/udpsource/udpsourcegui.cpp @@ -25,7 +25,7 @@ #include "gui/basicchannelsettingsdialog.h" #include "gui/devicestreamselectiondialog.h" #include "plugin/pluginapi.h" -#include "mainwindow.h" +#include "maincore.h" #include "ui_udpsourcegui.h" @@ -135,8 +135,8 @@ UDPSourceGUI::UDPSourceGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, Baseb false // logarithmic scale ); - ui->glSpectrum->connectTimer(MainWindow::getInstance()->getMasterTimer()); - connect(&MainWindow::getInstance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); + ui->glSpectrum->connectTimer(MainCore::instance()->getMasterTimer()); + connect(&MainCore::instance()->getMasterTimer(), SIGNAL(timeout()), this, SLOT(tick())); m_channelMarker.blockSignals(true); m_channelMarker.setBandwidth(16000); diff --git a/plugins/feature/rigctlserver/rigctlservergui.cpp b/plugins/feature/rigctlserver/rigctlservergui.cpp index d096ffeea..4075fabf8 100644 --- a/plugins/feature/rigctlserver/rigctlservergui.cpp +++ b/plugins/feature/rigctlserver/rigctlservergui.cpp @@ -20,8 +20,8 @@ #include "feature/featureuiset.h" #include "gui/basicfeaturesettingsdialog.h" -#include "mainwindow.h" -#include "device/deviceuiset.h" +#include "device/deviceset.h" +#include "maincore.h" #include "ui_rigctlservergui.h" #include "rigctlserver.h" @@ -165,18 +165,18 @@ void RigCtlServerGUI::displaySettings() void RigCtlServerGUI::updateDeviceSetList() { - MainWindow *mainWindow = MainWindow::getInstance(); - std::vector& deviceUISets = mainWindow->getDeviceUISets(); - std::vector::const_iterator it = deviceUISets.begin(); + MainCore *mainCore = MainCore::instance(); + std::vector& deviceSets = mainCore->getDeviceSets(); + std::vector::const_iterator it = deviceSets.begin(); ui->device->blockSignals(true); ui->device->clear(); unsigned int deviceIndex = 0; - for (; it != deviceUISets.end(); ++it, deviceIndex++) + for (; it != deviceSets.end(); ++it, deviceIndex++) { - DSPDeviceSourceEngine *deviceSourceEngine = (*it)->m_deviceSourceEngine; + DSPDeviceSourceEngine *deviceSourceEngine = (*it)->m_deviceSourceEngine; DSPDeviceSinkEngine *deviceSinkEngine = (*it)->m_deviceSinkEngine; DSPDeviceMIMOEngine *deviceMIMOEngine = (*it)->m_deviceMIMOEngine; @@ -187,7 +187,7 @@ void RigCtlServerGUI::updateDeviceSetList() int newDeviceIndex; - if (it != deviceUISets.begin()) + if (it != deviceSets.begin()) { if (m_settings.m_deviceIndex < 0) { ui->device->setCurrentIndex(0); @@ -226,10 +226,10 @@ bool RigCtlServerGUI::updateChannelList() } else { - MainWindow *mainWindow = MainWindow::getInstance(); - std::vector& deviceUISets = mainWindow->getDeviceUISets(); - DeviceUISet *deviceUISet = deviceUISets[m_settings.m_deviceIndex]; - int nbChannels = deviceUISet->getNumberOfChannels(); + MainCore *mainCore = MainCore::instance(); + std::vector& deviceSets = mainCore->getDeviceSets(); + DeviceSet *deviceSet = deviceSets[m_settings.m_deviceIndex]; + int nbChannels = deviceSet->getNumberOfChannels(); for (int ch = 0; ch < nbChannels; ch++) { ui->channel->addItem(QString("%1").arg(ch), ch); diff --git a/plugins/feature/simpleptt/simplepttgui.cpp b/plugins/feature/simpleptt/simplepttgui.cpp index 349063aa0..4b65aac22 100644 --- a/plugins/feature/simpleptt/simplepttgui.cpp +++ b/plugins/feature/simpleptt/simplepttgui.cpp @@ -19,8 +19,8 @@ #include "feature/featureuiset.h" #include "gui/basicfeaturesettingsdialog.h" -#include "mainwindow.h" -#include "device/deviceuiset.h" +#include "device/deviceset.h" +#include "maincore.h" #include "ui_simplepttgui.h" #include "simplepttreport.h" @@ -180,9 +180,9 @@ void SimplePTTGUI::displaySettings() void SimplePTTGUI::updateDeviceSetLists() { - MainWindow *mainWindow = MainWindow::getInstance(); - std::vector& deviceUISets = mainWindow->getDeviceUISets(); - std::vector::const_iterator it = deviceUISets.begin(); + MainCore *mainCore = MainCore::instance(); + std::vector& deviceSets = mainCore->getDeviceSets(); + std::vector::const_iterator it = deviceSets.begin(); ui->rxDevice->blockSignals(true); ui->txDevice->blockSignals(true); @@ -193,7 +193,7 @@ void SimplePTTGUI::updateDeviceSetLists() unsigned int rxIndex = 0; unsigned int txIndex = 0; - for (; it != deviceUISets.end(); ++it, deviceIndex++) + for (; it != deviceSets.end(); ++it, deviceIndex++) { DSPDeviceSourceEngine *deviceSourceEngine = (*it)->m_deviceSourceEngine; DSPDeviceSinkEngine *deviceSinkEngine = (*it)->m_deviceSinkEngine;