SDRplay: changed placement of input object creation in the GUI

pull/27/head
f4exb 2017-04-14 02:22:37 +02:00
rodzic 00cf437bf2
commit c8146808a2
1 zmienionych plików z 3 dodań i 4 usunięć

Wyświetl plik

@ -34,6 +34,9 @@ SDRPlayGui::SDRPlayGui(DeviceSourceAPI *deviceAPI, QWidget* parent) :
ui(new Ui::SDRPlayGui),
m_deviceAPI(deviceAPI)
{
m_sampleSource = new SDRPlayInput(m_deviceAPI);
m_deviceAPI->setSource(m_sampleSource);
ui->setupUi(this);
ui->centerFrequency->setColorMapper(ColorMapper(ColorMapper::ReverseGold));
ui->centerFrequency->setValueRange(7, 10U, 12000U);
@ -68,11 +71,7 @@ SDRPlayGui::SDRPlayGui(DeviceSourceAPI *deviceAPI, QWidget* parent) :
displaySettings();
m_sampleSource = new SDRPlayInput(m_deviceAPI);
m_deviceAPI->setSource(m_sampleSource);
connect(m_sampleSource->getOutputMessageQueueToGUI(), SIGNAL(messageEnqueued()), this, SLOT(handleSourceMessages()));
m_deviceAPI->setSource(m_sampleSource);
char recFileNameCStr[30];
sprintf(recFileNameCStr, "test_%d.sdriq", m_deviceAPI->getDeviceUID());