summaryrefslogtreecommitdiff
path: root/gtk2_ardour/plugin_selector.cc
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2019-03-31 22:25:29 +0200
committerRobin Gareus <robin@gareus.org>2019-03-31 22:25:29 +0200
commitda15b599de110fa43b97b92bbb772410f4462f0f (patch)
tree62c262bacb1f94c417d8de4f5264b7accaae91c9 /gtk2_ardour/plugin_selector.cc
parent827b4ef8a1e74607a787b90e5e46f36e507f59b3 (diff)
Remove a hack of using flags to emit a signal-change from the GUI
The GUI should not be calling `manager.PluginListChanged();` It's up to the plugin-manager to emit relevant signals. This fixes an issue when adding/removing plugin-favorites using the mixer's sidebar or via remote-control/surfaces or script.
Diffstat (limited to 'gtk2_ardour/plugin_selector.cc')
-rw-r--r--gtk2_ardour/plugin_selector.cc12
1 files changed, 1 insertions, 11 deletions
diff --git a/gtk2_ardour/plugin_selector.cc b/gtk2_ardour/plugin_selector.cc
index 7b599bc25d..338d3aa9ee 100644
--- a/gtk2_ardour/plugin_selector.cc
+++ b/gtk2_ardour/plugin_selector.cc
@@ -69,10 +69,9 @@ PluginSelector::PluginSelector (PluginManager& mgr)
_plugin_menu = 0;
in_row_change = false;
- //anytime the list changes ( Status, Tags, or scanned plugins ) we need to rebuild redirect-box plugin selector menu
manager.PluginListChanged.connect (plugin_list_changed_connection, invalidator (*this), boost::bind (&PluginSelector::build_plugin_menu, this), gui_context());
+ manager.PluginStatusChanged.connect (plugin_list_changed_connection, invalidator (*this), boost::bind (&PluginSelector::build_plugin_menu, this), gui_context());
- //these are used to update the info of specific entries, while they are being edited
manager.PluginStatusChanged.connect (plugin_list_changed_connection, invalidator (*this), boost::bind (&PluginSelector::plugin_status_changed, this, _1, _2, _3), gui_context());
manager.PluginTagChanged.connect(plugin_list_changed_connection, invalidator (*this), boost::bind (&PluginSelector::tags_changed, this, _1, _2, _3), gui_context());
@@ -788,10 +787,6 @@ PluginSelector::run ()
manager.save_statuses();
}
- if ( _need_tag_save || _need_status_save || _need_menu_rebuild ) {
- manager.PluginListChanged(); //emit signal
- }
-
return (int) r;
}
@@ -810,7 +805,6 @@ PluginSelector::tag_reset_button_clicked ()
manager.reset_tags (pi);
display_selection_changed ();
_need_tag_save = true;
- _need_menu_rebuild = true;
}
}
@@ -833,7 +827,6 @@ PluginSelector::tag_entry_changed ()
manager.set_tags (pi->type, pi->unique_id, tag_entry->get_text(), pi->name, PluginManager::FromGui);
_need_tag_save = true;
- _need_menu_rebuild = true;
}
}
@@ -888,7 +881,6 @@ PluginSelector::on_show ()
_need_tag_save = false;
_need_status_save = false;
- _need_menu_rebuild = false;
}
struct PluginMenuCompareByCreator {
@@ -1172,7 +1164,6 @@ PluginSelector::favorite_changed (const std::string& path)
manager.set_status (pi->type, pi->unique_id, status);
_need_status_save = true;
- _need_menu_rebuild = true;
}
in_row_change = false;
}
@@ -1205,7 +1196,6 @@ PluginSelector::hidden_changed (const std::string& path)
manager.set_status (pi->type, pi->unique_id, status);
_need_status_save = true;
- _need_menu_rebuild = true;
}
in_row_change = false;
}