1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2026-06-07 08:24:43 -04:00

DeviceSourceAPI code cleanup

This commit is contained in:
f4exb
2017-10-31 08:35:27 +01:00
parent a61bb04dac
commit e30050f018
3 changed files with 3 additions and 187 deletions
+3 -3
View File
@@ -330,7 +330,7 @@ void MainWindow::removeLastDevice()
ui->tabSpectra->removeTab(ui->tabSpectra->count() - 1);
// deletes old UI and input object
m_deviceUIs.back()->m_deviceSourceAPI->freeChannels(); // destroys the channel instances
m_deviceUIs.back()->freeChannels(); // destroys the channel instances
m_deviceUIs.back()->m_deviceSourceAPI->getSampleSource()->setMessageQueueToGUI(0); // have source stop sending messages to the GUI
m_deviceUIs.back()->m_deviceSourceAPI->getPluginInterface()->deleteSampleSourcePluginInstanceGUI(
m_deviceUIs.back()->m_deviceSourceAPI->getSampleSourcePluginInstanceGUI());
@@ -479,7 +479,7 @@ void MainWindow::loadPresetSettings(const Preset* preset, int tabIndex)
{
deviceUI->m_spectrumGUI->deserialize(preset->getSpectrumConfig());
deviceUI->m_deviceSourceAPI->loadSourceSettings(preset);
deviceUI->m_deviceSourceAPI->loadChannelSettings(preset, m_pluginManager->getPluginAPI());
deviceUI->loadChannelSettings(preset, m_pluginManager->getPluginAPI());
}
else if (deviceUI->m_deviceSinkEngine) // sink device
{
@@ -507,7 +507,7 @@ void MainWindow::savePresetSettings(Preset* preset, int tabIndex)
{
preset->setSpectrumConfig(deviceUI->m_spectrumGUI->serialize());
preset->clearChannels();
deviceUI->m_deviceSourceAPI->saveChannelSettings(preset);
deviceUI->saveChannelSettings(preset);
deviceUI->m_deviceSourceAPI->saveSourceSettings(preset);
}
else if (deviceUI->m_deviceSinkEngine) // sink device