diff --git a/sdrbase/mainwindow.cpp b/sdrbase/mainwindow.cpp index ca55331c1..5965c23f1 100644 --- a/sdrbase/mainwindow.cpp +++ b/sdrbase/mainwindow.cpp @@ -140,6 +140,12 @@ MainWindow::MainWindow(QWidget* parent) : exit(0); } + QWidget *gui; + PluginInstanceUI *pluginGUI = m_deviceUIs.back()->m_deviceSourceAPI->getPluginInterface()->createSampleSourcePluginInstanceGUI( + m_deviceUIs.back()->m_deviceSourceAPI->getSampleSourceId(), &gui, m_deviceUIs.back()->m_deviceSourceAPI); + m_deviceUIs.back()->m_deviceSourceAPI->setSampleSourcePluginInstanceUI(pluginGUI); + m_deviceUIs.back()->m_deviceSourceAPI->setInputGUI(gui, m_deviceUIs.back()->m_deviceSourceAPI->getSampleSourceDisplayName()); + m_deviceUIs.back()->m_deviceSourceAPI->setBuddyLeader(true); // the first device is always the leader bool sampleSourceSignalsBlocked = m_deviceUIs.back()->m_samplingDeviceControl->getDeviceSelector()->blockSignals(true); diff --git a/sdrbase/plugin/pluginmanager.cpp b/sdrbase/plugin/pluginmanager.cpp index 2fd0f358b..2b7a0b986 100644 --- a/sdrbase/plugin/pluginmanager.cpp +++ b/sdrbase/plugin/pluginmanager.cpp @@ -390,11 +390,13 @@ int PluginManager::selectSampleSourceByIndex(int index, DeviceSourceAPI *deviceA deviceAPI->setHardwareId(m_sampleSourceDevices[index].m_hadrwareId); deviceAPI->setSampleSourceId(m_sampleSourceDevices[index].m_deviceId); deviceAPI->setSampleSourceSerial(m_sampleSourceDevices[index].m_deviceSerial); + deviceAPI->setSampleSourceDisplayName(m_sampleSourceDevices[index].m_displayName); + deviceAPI->setSampleSourcePluginInterface(m_sampleSourceDevices[index].m_plugin); - QWidget *gui; - PluginInstanceUI *pluginGUI = m_sampleSourceDevices[index].m_plugin->createSampleSourcePluginInstanceGUI(m_sampleSourceDevices[index].m_deviceId, &gui, deviceAPI); - deviceAPI->setSampleSourcePluginInstanceUI(pluginGUI); - deviceAPI->setInputGUI(gui, m_sampleSourceDevices[index].m_displayName); +// QWidget *gui; +// PluginInstanceUI *pluginGUI = m_sampleSourceDevices[index].m_plugin->createSampleSourcePluginInstanceGUI(m_sampleSourceDevices[index].m_deviceId, &gui, deviceAPI); +// deviceAPI->setSampleSourcePluginInstanceUI(pluginGUI); +// deviceAPI->setInputGUI(gui, m_sampleSourceDevices[index].m_displayName); return index; }