smaller_hbox->pack_start (_preset_modified, false, false);
smaller_hbox->pack_start (_preset_combo, false, false);
smaller_hbox->pack_start (add_button, false, false);
-#if 0
- /* Ardour does not currently allow to overwrite existing presets
- * see save_property_list() in audio_unit.cc
- */
smaller_hbox->pack_start (save_button, false, false);
-#endif
+ smaller_hbox->pack_start (delete_button, false, false);
+
#if 0
/* one day these might be useful with an AU plugin, but not yet */
smaller_hbox->pack_start (automation_mode_label, false, false);
}
--_no_load_preset;
- save_button.set_sensitive (!p.uri.empty() && p.user);
delete_button.set_sensitive (!p.uri.empty() && p.user);
-
update_preset_modified ();
}
void
PlugUIBase::update_preset_modified ()
{
+ Plugin::PresetRecord p = plugin->last_preset();
- if (plugin->last_preset().uri.empty()) {
+ if (p.uri.empty()) {
+ save_button.set_sensitive (false);
_preset_modified.set_text ("");
return;
}
if (_preset_modified.get_text().empty() == c) {
_preset_modified.set_text (c ? "*" : "");
}
+ save_button.set_sensitive (c && p.user);
}
void