修复退出时崩溃
This commit is contained in:
parent
ccbfdc1213
commit
fbd7e63756
@ -17,6 +17,13 @@ void plugin_host_manager::init(singleton_initliazer& initliazer) {
|
||||
mixer_ptr->on_remove_track.add_raw(this, &plugin_host_manager::on_mixer_track_removed);
|
||||
}
|
||||
|
||||
void plugin_host_manager::release() {
|
||||
singleton_t<plugin_host_manager>::release();
|
||||
for (auto host: plugin_hosts_) {
|
||||
delete host;
|
||||
}
|
||||
}
|
||||
|
||||
plugin_host* plugin_host_manager::load_plugin(const char* path) {
|
||||
auto host = new vst2_plugin_host();
|
||||
try {
|
||||
|
@ -7,6 +7,7 @@ class mixer_track;
|
||||
class CORE_API plugin_host_manager : public singleton_t<plugin_host_manager> {
|
||||
public:
|
||||
void init(singleton_initliazer& initliazer) override;
|
||||
void release() override;
|
||||
|
||||
plugin_host* load_plugin(const char* path);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user