mirror of
https://github.com/f4exb/sdrangel.git
synced 2026-06-12 10:48:42 -04:00
Multi device support: commented out code cleanup
This commit is contained in:
@@ -202,7 +202,6 @@ void MainWindow::addDevice()
|
||||
bool sampleSourceSignalsBlocked = m_deviceUIs.back()->m_samplingDeviceControl->getDeviceSelector()->blockSignals(true);
|
||||
m_pluginManager->fillSampleSourceSelector(m_deviceUIs.back()->m_samplingDeviceControl->getDeviceSelector());
|
||||
|
||||
// connect(m_deviceUIs.back()->m_samplingDeviceControl->getDeviceSelector(), SIGNAL(currentIndexChanged(int)), this, SLOT(on_sampleSource_currentIndexChanged(int)));
|
||||
connect(m_deviceUIs.back()->m_samplingDeviceControl->getDeviceSelectionConfirm(), SIGNAL(clicked(bool)), this, SLOT(on_sampleSource_confirmClicked(bool)));
|
||||
|
||||
m_deviceUIs.back()->m_samplingDeviceControl->getDeviceSelector()->blockSignals(sampleSourceSignalsBlocked);
|
||||
@@ -277,21 +276,6 @@ void MainWindow::setInputGUI(int deviceTabIndex, QWidget* gui, const QString& so
|
||||
}
|
||||
|
||||
ui->tabInputsView->setCurrentIndex(deviceTabIndex);
|
||||
|
||||
|
||||
// if (deviceTabIndex < ui->tabInputsView->count())
|
||||
// {
|
||||
// qDebug("MainWindow::setInputGUI: tab device index %d replace", deviceTabIndex);
|
||||
// ui->tabInputsView->removeTab(deviceTabIndex);
|
||||
// ui->tabInputsView->insertTab(deviceTabIndex, gui, tabNameCStr);
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// qDebug("MainWindow::setInputGUI: tab device index %d add", deviceTabIndex);
|
||||
// ui->tabInputsView->addTab(gui, tabNameCStr);
|
||||
// }
|
||||
|
||||
// ui->tabInputsView->setTabToolTip(deviceTabIndex, sourceDisplayName);
|
||||
}
|
||||
|
||||
void MainWindow::loadSettings()
|
||||
@@ -675,11 +659,8 @@ void MainWindow::on_sampleSource_currentIndexChanged(int index)
|
||||
qDebug("MainWindow::on_sampleSource_currentIndexChanged: tab at %d", currentSourceTabIndex);
|
||||
DeviceUISet *deviceUI = m_deviceUIs[currentSourceTabIndex];
|
||||
deviceUI->m_deviceAPI->saveSourceSettings(m_settings.getWorkingPreset());
|
||||
//deviceUI->m_pluginManager->saveSourceSettings(m_settings.getWorkingPreset());
|
||||
m_pluginManager->selectSampleSourceByIndex(deviceUI->m_samplingDeviceControl->getDeviceSelector()->currentIndex(), deviceUI->m_deviceAPI);
|
||||
m_settings.setSourceIndex(deviceUI->m_samplingDeviceControl->getDeviceSelector()->currentIndex());
|
||||
|
||||
//deviceUI->m_pluginManager->loadSourceSettings(m_settings.getWorkingPreset());
|
||||
deviceUI->m_deviceAPI->loadSourceSettings(m_settings.getWorkingPreset());
|
||||
}
|
||||
}
|
||||
@@ -694,11 +675,8 @@ void MainWindow::on_sampleSource_confirmClicked(bool checked)
|
||||
qDebug("MainWindow::on_sampleSource_currentIndexChanged: tab at %d", currentSourceTabIndex);
|
||||
DeviceUISet *deviceUI = m_deviceUIs[currentSourceTabIndex];
|
||||
deviceUI->m_deviceAPI->saveSourceSettings(m_settings.getWorkingPreset());
|
||||
//deviceUI->m_pluginManager->saveSourceSettings(m_settings.getWorkingPreset());
|
||||
m_pluginManager->selectSampleSourceByIndex(deviceUI->m_samplingDeviceControl->getDeviceSelector()->currentIndex(), deviceUI->m_deviceAPI);
|
||||
m_settings.setSourceIndex(deviceUI->m_samplingDeviceControl->getDeviceSelector()->currentIndex());
|
||||
|
||||
//deviceUI->m_pluginManager->loadSourceSettings(m_settings.getWorkingPreset());
|
||||
deviceUI->m_deviceAPI->loadSourceSettings(m_settings.getWorkingPreset());
|
||||
}
|
||||
}
|
||||
@@ -748,7 +726,6 @@ MainWindow::DeviceUISet::DeviceUISet(QTimer& timer)
|
||||
m_samplingDeviceControl = new SamplingDeviceControl;
|
||||
m_deviceEngine = 0;
|
||||
m_deviceAPI = 0;
|
||||
// m_pluginManager = 0;
|
||||
|
||||
// m_spectrum needs to have its font to be set since it cannot be inherited from the main window
|
||||
QFont font;
|
||||
|
||||
Reference in New Issue
Block a user