summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2012-11-12 16:49:11 +0000
committerRobin Gareus <robin@gareus.org>2012-11-12 16:49:11 +0000
commitc528c1178a38a421e893c25145630299ec4786ad (patch)
treed2513786d5082f5d74b1c46e1f125c39a527664d
parentad4d781477603117fb6a2acc57824aa0f2f89d8b (diff)
prevent changing slave while slave is active
fix potential segfault: clock asking for slave's timecode when the slave is not a Timecode-slave. git-svn-id: svn://localhost/ardour2/branches/3.0@13455 d708f5d6-7413-0410-9779-e7cbd77b26cf
-rw-r--r--gtk2_ardour/ardour_ui_options.cc11
-rw-r--r--gtk2_ardour/rc_option_editor.cc6
2 files changed, 16 insertions, 1 deletions
diff --git a/gtk2_ardour/ardour_ui_options.cc b/gtk2_ardour/ardour_ui_options.cc
index 5da10c7ea3..8e0066da0d 100644
--- a/gtk2_ardour/ardour_ui_options.cc
+++ b/gtk2_ardour/ardour_ui_options.cc
@@ -69,6 +69,17 @@ when the pull up/down setting is non-zero."));
}
}
+ /* activating a slave is a session-property.
+ * The slave type is a RC property.
+ * When the slave is active is must not be reconfigured.
+ * This is a UI limitation, imposed by audio-clock and
+ * status displays which combine RC-config & session-properties.
+ *
+ * Notficy RCOptionEditor by emitting a signal if the active
+ * status changed:
+ */
+ Config->ParameterChanged("sync-source");
+
ActionManager::toggle_config_state_foo ("Transport", "ToggleExternalSync", sigc::mem_fun (_session->config, &SessionConfiguration::set_external_sync), sigc::mem_fun (_session->config, &SessionConfiguration::get_external_sync));
}
}
diff --git a/gtk2_ardour/rc_option_editor.cc b/gtk2_ardour/rc_option_editor.cc
index c59c3c949e..978cea87cc 100644
--- a/gtk2_ardour/rc_option_editor.cc
+++ b/gtk2_ardour/rc_option_editor.cc
@@ -1152,10 +1152,10 @@ RCOptionEditor::RCOptionEditor ()
_("Specify the Peak Volume of the generated LTC signal in dbFS. A good value is 0dBu ^= -18dbFS in an EBU calibrated system"));
add_option (_("Transport"), _ltc_volume_slider);
+ parameter_changed ("send-ltc");
#endif
parameter_changed ("sync-source");
- parameter_changed ("send-ltc");
/* EDITOR */
@@ -1795,6 +1795,10 @@ RCOptionEditor::parameter_changed (string const & p)
_solo_control_is_listen_control->set_sensitive (s);
_listen_position->set_sensitive (s);
} else if (p == "sync-source") {
+ _sync_source->set_sensitive (true);
+ if (_session) {
+ _sync_source->set_sensitive (_session->config.get_external_sync());
+ }
switch(Config->get_sync_source()) {
case ARDOUR::MTC:
case ARDOUR::LTC: