diff options
Diffstat (limited to 'libs/ardour')
-rw-r--r-- | libs/ardour/ardour/plugin.h | 1 | ||||
-rw-r--r-- | libs/ardour/plugin.cc | 10 |
2 files changed, 11 insertions, 0 deletions
diff --git a/libs/ardour/ardour/plugin.h b/libs/ardour/ardour/plugin.h index 15e5f4a9c5..bf91de903b 100644 --- a/libs/ardour/ardour/plugin.h +++ b/libs/ardour/ardour/plugin.h @@ -183,6 +183,7 @@ class Plugin : public PBD::StatefulDestructible, public Latent void remove_preset (std::string); virtual bool load_preset (PresetRecord); + void clear_preset (); const PresetRecord * preset_by_label (const std::string &); const PresetRecord * preset_by_uri (const std::string &); diff --git a/libs/ardour/plugin.cc b/libs/ardour/plugin.cc index 4afc39b4ec..8cdbf98b89 100644 --- a/libs/ardour/plugin.cc +++ b/libs/ardour/plugin.cc @@ -327,6 +327,16 @@ Plugin::load_preset (PresetRecord r) return true; } +void +Plugin::clear_preset () +{ + _last_preset.uri = ""; + _last_preset.label = ""; + _parameter_changed_since_last_preset = false; + + PresetLoaded (); /* EMIT SIGNAL */ +} + /** @param val `plugin' value */ void Plugin::set_parameter (uint32_t which, float val) |