mirror of
https://github.com/f4exb/sdrangel.git
synced 2025-04-04 18:48:34 -04:00
Removed main window references from plugin manager
This commit is contained in:
parent
ab9474a65f
commit
14b7406ea9
@ -457,13 +457,13 @@ 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->m_pluginAPI));
|
||||
deviceUI->m_deviceSourceAPI->loadChannelSettings(preset, m_pluginManager->getPluginAPI());
|
||||
}
|
||||
else if (deviceUI->m_deviceSinkEngine) // sink device
|
||||
{
|
||||
deviceUI->m_spectrumGUI->deserialize(preset->getSpectrumConfig());
|
||||
deviceUI->m_deviceSinkAPI->loadSinkSettings(preset);
|
||||
deviceUI->m_deviceSinkAPI->loadChannelSettings(preset, &(m_pluginManager->m_pluginAPI));
|
||||
deviceUI->m_deviceSinkAPI->loadChannelSettings(preset, m_pluginManager->getPluginAPI());
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -14,31 +14,31 @@
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>. //
|
||||
///////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include <plugin/plugininstancegui.h>
|
||||
#include "device/devicesourceapi.h"
|
||||
#include "device/devicesinkapi.h"
|
||||
#include <QApplication>
|
||||
#include <QPluginLoader>
|
||||
#include <QComboBox>
|
||||
#include <QDebug>
|
||||
|
||||
#include <cstdio>
|
||||
|
||||
#include "plugin/pluginmanager.h"
|
||||
#include <plugin/plugininstancegui.h>
|
||||
#include "device/devicesourceapi.h"
|
||||
#include "device/devicesinkapi.h"
|
||||
#include "settings/preset.h"
|
||||
#include "mainwindow.h"
|
||||
#include "gui/glspectrum.h"
|
||||
#include "util/message.h"
|
||||
|
||||
#include <QDebug>
|
||||
#include "dsp/dspdevicesourceengine.h"
|
||||
#include "dsp/dspdevicesinkengine.h"
|
||||
|
||||
#include "plugin/pluginmanager.h"
|
||||
|
||||
const QString PluginManager::m_sdrDaemonHardwareID = "SDRdaemonSource";
|
||||
const QString PluginManager::m_sdrDaemonDeviceTypeID = "sdrangel.samplesource.sdrdaemonsource";
|
||||
const QString PluginManager::m_fileSourceHardwareID = "FileSource";
|
||||
const QString PluginManager::m_fileSourceDeviceTypeID = "sdrangel.samplesource.filesource";
|
||||
const QString PluginManager::m_fileSinkDeviceTypeID = "sdrangel.samplesink.filesink";
|
||||
|
||||
PluginManager::PluginManager(MainWindow* mainWindow, QObject* parent) :
|
||||
PluginManager::PluginManager(QObject* parent) :
|
||||
QObject(parent),
|
||||
m_pluginAPI(this)
|
||||
{
|
||||
|
@ -11,7 +11,6 @@
|
||||
class QComboBox;
|
||||
class QPluginLoader;
|
||||
class Preset;
|
||||
class MainWindow;
|
||||
class Message;
|
||||
class MessageQueue;
|
||||
class DeviceSourceAPI;
|
||||
@ -36,9 +35,10 @@ public:
|
||||
|
||||
typedef QList<Plugin> Plugins;
|
||||
|
||||
explicit PluginManager(MainWindow* mainWindow, QObject* parent = NULL);
|
||||
explicit PluginManager(QObject* parent = 0);
|
||||
~PluginManager();
|
||||
|
||||
PluginAPI *getPluginAPI() { return &m_pluginAPI; }
|
||||
void loadPlugins();
|
||||
const Plugins& getPlugins() const { return m_plugins; }
|
||||
|
||||
@ -134,8 +134,6 @@ private:
|
||||
static const QString m_fileSinkDeviceTypeID; //!< FileSink sink plugin ID
|
||||
|
||||
void loadPlugins(const QDir& dir);
|
||||
|
||||
friend class MainWindow;
|
||||
};
|
||||
|
||||
static inline bool operator<(const PluginManager::Plugin& a, const PluginManager::Plugin& b)
|
||||
|
Loading…
Reference in New Issue
Block a user