mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-11-25 01:18:38 -05:00
Removed the destroy method from ChannelGUI interface
This commit is contained in:
parent
b85419c56a
commit
704eb403d1
@ -56,9 +56,8 @@ public:
|
||||
ContextMenuChannelSettings
|
||||
};
|
||||
|
||||
ChannelGUI(QWidget *parent = nullptr);
|
||||
virtual ~ChannelGUI();
|
||||
virtual void destroy() = 0;
|
||||
explicit ChannelGUI(QWidget *parent = nullptr);
|
||||
~ChannelGUI() override;
|
||||
|
||||
virtual void resetToDefaults() = 0;
|
||||
// Data saved in the derived settings
|
||||
|
@ -166,7 +166,7 @@ void DeviceUISet::freeChannels()
|
||||
for(int i = 0; i < m_channelInstanceRegistrations.count(); i++)
|
||||
{
|
||||
qDebug("DeviceUISet::freeChannels: destroying channel [%s]", qPrintable(m_channelInstanceRegistrations[i].m_channelAPI->getURI()));
|
||||
m_channelInstanceRegistrations[i].m_gui->destroy();
|
||||
delete m_channelInstanceRegistrations[i].m_gui;
|
||||
delete m_channelInstanceRegistrations[i].m_channelAPI;
|
||||
}
|
||||
|
||||
@ -181,7 +181,7 @@ void DeviceUISet::deleteChannel(int channelIndex)
|
||||
qDebug("DeviceUISet::deleteChannel: delete channel [%s] at %d",
|
||||
qPrintable(m_channelInstanceRegistrations[channelIndex].m_channelAPI->getURI()),
|
||||
channelIndex);
|
||||
m_channelInstanceRegistrations[channelIndex].m_gui->destroy();
|
||||
delete m_channelInstanceRegistrations[channelIndex].m_gui;
|
||||
delete m_channelInstanceRegistrations[channelIndex].m_channelAPI;
|
||||
m_channelInstanceRegistrations.removeAt(channelIndex);
|
||||
}
|
||||
@ -320,7 +320,7 @@ void DeviceUISet::loadRxChannelSettings(const Preset *preset, PluginAPI *pluginA
|
||||
qDebug("DeviceUISet::loadRxChannelSettings: destroying old channel [%s]",
|
||||
qPrintable(m_channelInstanceRegistrations[i].m_channelAPI->getURI()));
|
||||
m_channelInstanceRegistrations[i].m_channelAPI->setMessageQueueToGUI(nullptr); // have channel stop sending messages to its GUI
|
||||
m_channelInstanceRegistrations[i].m_gui->destroy();
|
||||
delete m_channelInstanceRegistrations[i].m_gui;
|
||||
delete m_channelInstanceRegistrations[i].m_channelAPI;
|
||||
}
|
||||
|
||||
@ -449,7 +449,7 @@ void DeviceUISet::loadTxChannelSettings(const Preset *preset, PluginAPI *pluginA
|
||||
qDebug("DeviceUISet::loadTxChannelSettings: destroying old channel [%s]",
|
||||
qPrintable(m_channelInstanceRegistrations[i].m_channelAPI->getURI()));
|
||||
m_channelInstanceRegistrations[i].m_channelAPI->setMessageQueueToGUI(nullptr); // have channel stop sending messages to its GUI
|
||||
m_channelInstanceRegistrations[i].m_gui->destroy();
|
||||
delete m_channelInstanceRegistrations[i].m_gui;
|
||||
delete m_channelInstanceRegistrations[i].m_channelAPI;
|
||||
}
|
||||
|
||||
@ -575,7 +575,7 @@ void DeviceUISet::loadMIMOChannelSettings(const Preset *preset, PluginAPI *plugi
|
||||
{
|
||||
qDebug("DeviceUISet::loadMIMOChannelSettings: destroying old channel [%s]",
|
||||
qPrintable(m_channelInstanceRegistrations[i].m_channelAPI->getURI()));
|
||||
m_channelInstanceRegistrations[i].m_gui->destroy(); // stop GUI first (issue #1427)
|
||||
delete m_channelInstanceRegistrations[i].m_gui; // stop GUI first (issue #1427)
|
||||
delete m_channelInstanceRegistrations[i].m_channelAPI; // stop channel before (issue #860)
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user