diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2008-11-22 14:03:44 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2008-11-22 14:03:44 +0000 |
commit | 495edc3ed9944e50ac1223e789c74781d4715e08 (patch) | |
tree | 6413a6647696e787cdd2f30c8ca43e737eefa7c7 | |
parent | d7903af9c9e981555fd890cfd422b8d66c64408c (diff) |
new user option "New Plugins Active"; make only *new* plugins active when this is set, not any added plugins (eg. during session loading); option is true by default
git-svn-id: svn://localhost/ardour2/branches/2.0-ongoing@4233 d708f5d6-7413-0410-9779-e7cbd77b26cf
-rw-r--r-- | gtk2_ardour/ardour.menus | 1 | ||||
-rw-r--r-- | gtk2_ardour/ardour_ui.h | 1 | ||||
-rw-r--r-- | gtk2_ardour/ardour_ui_ed.cc | 1 | ||||
-rw-r--r-- | gtk2_ardour/ardour_ui_options.cc | 8 | ||||
-rw-r--r-- | gtk2_ardour/redirect_box.cc | 4 | ||||
-rw-r--r-- | libs/ardour/ardour/configuration_vars.h | 1 | ||||
-rw-r--r-- | libs/ardour/route.cc | 2 |
7 files changed, 16 insertions, 2 deletions
diff --git a/gtk2_ardour/ardour.menus b/gtk2_ardour/ardour.menus index 829ad903e4..b5330721bf 100644 --- a/gtk2_ardour/ardour.menus +++ b/gtk2_ardour/ardour.menus @@ -534,6 +534,7 @@ <menu action='MiscOptions'> <menuitem action='UseOSC'/> <menuitem action='StopPluginsWithTransport'/> + <menuitem action='NewPluginsActive'/> <menuitem action='DoNotRunPluginsWhileRecording'/> <menuitem action='LatchedRecordEnable'/> <menuitem action='RegionEquivalentsOverlap'/> diff --git a/gtk2_ardour/ardour_ui.h b/gtk2_ardour/ardour_ui.h index 66cfb46ab5..76173e8447 100644 --- a/gtk2_ardour/ardour_ui.h +++ b/gtk2_ardour/ardour_ui.h @@ -695,6 +695,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI void set_denormal_model (ARDOUR::DenormalModel); void toggle_sync_order_keys (); + void toggle_new_plugins_active(); void toggle_StopPluginsWithTransport(); void toggle_DoNotRunPluginsWhileRecording(); void toggle_VerifyRemoveLastCapture(); diff --git a/gtk2_ardour/ardour_ui_ed.cc b/gtk2_ardour/ardour_ui_ed.cc index 7c00d89ec1..f9d47c0967 100644 --- a/gtk2_ardour/ardour_ui_ed.cc +++ b/gtk2_ardour/ardour_ui_ed.cc @@ -446,6 +446,7 @@ ARDOUR_UI::install_actions () ActionManager::register_toggle_action (option_actions, X_("SyncEditorAndMixerTrackOrder"), _("Sync Editor and Mixer track order"), mem_fun (*this, &ARDOUR_UI::toggle_sync_order_keys)); ActionManager::register_toggle_action (option_actions, X_("StopPluginsWithTransport"), _("Stop plugins with transport"), mem_fun (*this, &ARDOUR_UI::toggle_StopPluginsWithTransport)); + ActionManager::register_toggle_action (option_actions, X_("NewPluginsActive"), _("New plugins are active"), mem_fun (*this, &ARDOUR_UI::toggle_new_plugins_active)); ActionManager::register_toggle_action (option_actions, X_("VerifyRemoveLastCapture"), _("Verify remove last capture"), mem_fun (*this, &ARDOUR_UI::toggle_VerifyRemoveLastCapture)); ActionManager::register_toggle_action (option_actions, X_("PeriodicSafetyBackups"), _("Make periodic safety backups"), mem_fun (*this, &ARDOUR_UI::toggle_PeriodicSafetyBackups)); ActionManager::register_toggle_action (option_actions, X_("StopRecordingOnXrun"), _("Stop recording on xrun"), mem_fun (*this, &ARDOUR_UI::toggle_StopRecordingOnXrun)); diff --git a/gtk2_ardour/ardour_ui_options.cc b/gtk2_ardour/ardour_ui_options.cc index 02dc077688..7cfef62449 100644 --- a/gtk2_ardour/ardour_ui_options.cc +++ b/gtk2_ardour/ardour_ui_options.cc @@ -470,6 +470,12 @@ ARDOUR_UI::toggle_editing_space() } void +ARDOUR_UI::toggle_new_plugins_active () +{ + ActionManager::toggle_config_state ("options", "NewPluginsActive", &Configuration::set_new_plugins_active, &Configuration::get_new_plugins_active); +} + +void ARDOUR_UI::toggle_StopPluginsWithTransport() { ActionManager::toggle_config_state ("options", "StopPluginsWithTransport", &Configuration::set_plugins_stop_with_transport, &Configuration::get_plugins_stop_with_transport); @@ -1125,6 +1131,8 @@ ARDOUR_UI::parameter_changed (const char* parameter_name) ActionManager::map_some_state ("Transport", "ToggleTimeMaster", &Configuration::get_jack_time_master); } else if (PARAM_IS ("plugins-stop-with-transport")) { ActionManager::map_some_state ("options", "StopPluginsWithTransport", &Configuration::get_plugins_stop_with_transport); + } else if (PARAM_IS ("new-plugins-active")) { + ActionManager::map_some_state ("options", "NewPluginsActive", &Configuration::get_new_plugins_active); } else if (PARAM_IS ("latched-record-enable")) { ActionManager::map_some_state ("options", "LatchedRecordEnable", &Configuration::get_latched_record_enable); } else if (PARAM_IS ("verify-remove-last-capture")) { diff --git a/gtk2_ardour/redirect_box.cc b/gtk2_ardour/redirect_box.cc index d8e3ffd043..f0f06d12d6 100644 --- a/gtk2_ardour/redirect_box.cc +++ b/gtk2_ardour/redirect_box.cc @@ -407,6 +407,10 @@ RedirectBox::use_plugins (const SelectedPlugins& plugins) boost::shared_ptr<Redirect> redirect (new PluginInsert (_session, *p, _placement)); uint32_t err_streams; + + if (Config->get_new_plugins_active()) { + redirect->set_active (true, this); + } if (_route->add_redirect (redirect, this, &err_streams)) { weird_plugin_dialog (**p, err_streams, _route); diff --git a/libs/ardour/ardour/configuration_vars.h b/libs/ardour/ardour/configuration_vars.h index da2180f92a..534bd64be3 100644 --- a/libs/ardour/ardour/configuration_vars.h +++ b/libs/ardour/ardour/configuration_vars.h @@ -157,6 +157,7 @@ CONFIG_VARIABLE (uint32_t, periodic_safety_backup_interval, "periodic-safety-bac CONFIG_VARIABLE (float, automation_interval, "automation-interval", 50) CONFIG_VARIABLE (bool, sync_all_route_ordering, "sync-all-route-ordering", true) CONFIG_VARIABLE (bool, only_copy_imported_files, "only-copy-imported-files", true) +CONFIG_VARIABLE (bool, new_plugins_active, "new-plugins-active", true) CONFIG_VARIABLE (std::string, keyboard_layout, "keyboard-layout", "ansi") CONFIG_VARIABLE (std::string, default_bindings, "default-bindings", "ardour") CONFIG_VARIABLE (bool, default_narrow_ms, "default-narrow_ms", false) diff --git a/libs/ardour/route.cc b/libs/ardour/route.cc index ed70758032..a2cf025b85 100644 --- a/libs/ardour/route.cc +++ b/libs/ardour/route.cc @@ -921,7 +921,6 @@ Route::add_redirect (boost::shared_ptr<Redirect> redirect, void *src, uint32_t* _max_peak_power.push_back(-INFINITY); } - redirect->set_active (true, this); redirect->active_changed.connect (mem_fun (*this, &Route::redirect_active_proxy)); } @@ -985,7 +984,6 @@ Route::add_redirects (const RedirectList& others, void *src, uint32_t* err_strea return -1; } - (*i)->set_active (true, this); (*i)->active_changed.connect (mem_fun (*this, &Route::redirect_active_proxy)); } } |