diff --git a/libs/ardour/ardour/plugin_manager.h b/libs/ardour/ardour/plugin_manager.h index 55879eea97..8b1fd3fbc6 100644 --- a/libs/ardour/ardour/plugin_manager.h +++ b/libs/ardour/ardour/plugin_manager.h @@ -159,12 +159,17 @@ public: }; std::vector get_all_tags (enum TagFilter) const; - /** plugins were added to or removed from one of the PluginInfoLists */ + /** plugins were added to or removed from one of the PluginInfoLists + * This implies PluginScanLogChanged. + */ PBD::Signal0 PluginListChanged; /** Plugin Statistics (use-count, recently-used) changed */ PBD::Signal0 PluginStatsChanged; + /** Plugin ScanLog changed */ + PBD::Signal0 PluginScanLogChanged; + /** A single plugin's Hidden/Favorite status changed */ PBD::Signal3 PluginStatusChanged; //PluginType t, string id, string tag diff --git a/libs/ardour/plugin_manager.cc b/libs/ardour/plugin_manager.cc index 4321e0cc1d..f59d27eb06 100644 --- a/libs/ardour/plugin_manager.cc +++ b/libs/ardour/plugin_manager.cc @@ -3235,6 +3235,8 @@ PluginManager::rescan_plugin (ARDOUR::PluginType type, std::string const& path_u save_scanlog (); if (erased) { PluginListChanged (); /* EMIT SIGNAL */ + } else { + PluginScanLogChanged (); /* EMIT SIGNAL */ } PluginScanMessage(X_("closeme"), "", false); return false; @@ -3275,6 +3277,7 @@ PluginManager::rescan_faulty () detect_ambiguities (); } else { save_scanlog (); + PluginScanLogChanged ();/* EMIT SIGNAL */ } } @@ -3290,6 +3293,7 @@ PluginManager::scan_log (std::vector >& l) void PluginManager::clear_stale_log () { + bool erased = false; for (PluginScanLog::const_iterator i = _plugin_scan_log.begin(); i != _plugin_scan_log.end();) { if (!(*i)->recent()) { whitelist ((*i)->type (), (*i)->path (), true); @@ -3299,11 +3303,15 @@ PluginManager::clear_stale_log () ::g_unlink (fn.c_str ()); } i = _plugin_scan_log.erase (i); + erased = true; } else { ++i; } } - save_scanlog (); + if (erased) { + save_scanlog (); + PluginScanLogChanged ();/* EMIT SIGNAL */ + } } void