Mercurial > hg > svgui
diff widgets/PluginParameterBox.h @ 1581:11660e0c896f audio-source-refactor
Use shared_ptr for plugin instances throughout; also descriptors are copyable
author | Chris Cannam |
---|---|
date | Fri, 20 Mar 2020 16:31:23 +0000 |
parents | 05d614f6e46d |
children | 7eb595837eaa |
line wrap: on
line diff
--- a/widgets/PluginParameterBox.h Fri Jan 24 15:11:08 2020 +0000 +++ b/widgets/PluginParameterBox.h Fri Mar 20 16:31:23 2020 +0000 @@ -32,10 +32,11 @@ Q_OBJECT public: - PluginParameterBox(Vamp::PluginBase *, QWidget *parent = 0); + PluginParameterBox(std::shared_ptr<Vamp::PluginBase>, + QWidget *parent = 0); ~PluginParameterBox(); - Vamp::PluginBase *getPlugin() { return m_plugin; } + std::shared_ptr<Vamp::PluginBase> getPlugin() { return m_plugin; } signals: void pluginConfigurationChanged(QString); @@ -51,7 +52,7 @@ void updateProgramCombo(); QGridLayout *m_layout; - Vamp::PluginBase *m_plugin; + std::shared_ptr<Vamp::PluginBase> m_plugin; struct ParamRec { AudioDial *dial;