PBD::Signal1<void,StripableNotificationListPtr> ControlProtocol::StripableSelectionChanged;
-Glib::Threads::Mutex ControlProtocol::first_selected_mutex;
+Glib::Threads::Mutex ControlProtocol::special_stripable_mutex;
boost::weak_ptr<Stripable> ControlProtocol::_first_selected_stripable;
StripableNotificationList ControlProtocol::_last_selected;
bool ControlProtocol::selection_connected = false;
boost::shared_ptr<Stripable>
ControlProtocol::first_selected_stripable ()
{
- Glib::Threads::Mutex::Lock lm (first_selected_mutex);
+ Glib::Threads::Mutex::Lock lm (special_stripable_mutex);
return _first_selected_stripable.lock();
}
+boost::shared_ptr<Stripable>
+ControlProtocol::leftmost_mixer_stripable ()
+{
+ Glib::Threads::Mutex::Lock lm (special_stripable_mutex);
+ return _first_selected_stripable.lock();
+}
+
+void
+ControlProtocol::set_leftmost_mixer_stripable (boost::shared_ptr<Stripable> s)
+{
+ Glib::Threads::Mutex::Lock lm (special_stripable_mutex);
+ _first_selected_stripable = s;
+}
+
void
ControlProtocol::set_first_selected_stripable (boost::shared_ptr<Stripable> s)
{
- Glib::Threads::Mutex::Lock lm (first_selected_mutex);
+ Glib::Threads::Mutex::Lock lm (special_stripable_mutex);
_first_selected_stripable = s;
}
_last_selected = *sp;
{
- Glib::Threads::Mutex::Lock lm (first_selected_mutex);
+ Glib::Threads::Mutex::Lock lm (special_stripable_mutex);
if (!_last_selected.empty()) {
if (!had_selection) {
static boost::shared_ptr<ARDOUR::Stripable> first_selected_stripable ();
static void set_first_selected_stripable (boost::shared_ptr<ARDOUR::Stripable>);
+ static boost::shared_ptr<ARDOUR::Stripable> leftmost_mixer_stripable ();
+ static void set_leftmost_mixer_stripable (boost::shared_ptr<ARDOUR::Stripable>);
+
/* the model here is as follows:
we imagine most control surfaces being able to control
bool _active;
- static Glib::Threads::Mutex first_selected_mutex;
+ static Glib::Threads::Mutex special_stripable_mutex;
+ static boost::weak_ptr<ARDOUR::Stripable> _leftmost_mixer_stripable;
static boost::weak_ptr<ARDOUR::Stripable> _first_selected_stripable;
static StripableNotificationList _last_selected;
static void stripable_selection_changed (StripableNotificationListPtr);