mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-09 08:14:58 +01:00
semantically more correct ordering of previous commit
This commit is contained in:
parent
0f20819c86
commit
ae837b49ed
1 changed files with 19 additions and 20 deletions
|
|
@ -87,27 +87,11 @@ ControlProtocolManager::set_session (Session* s)
|
|||
{
|
||||
SessionHandlePtr::set_session (s);
|
||||
|
||||
if (_session) {
|
||||
|
||||
/* get selection info and set it before instantiating any
|
||||
* control protocols.
|
||||
*/
|
||||
|
||||
CoreSelection::StripableAutomationControls sac;
|
||||
_session->selection().get_stripables (sac);
|
||||
|
||||
if (!sac.empty()) {
|
||||
StripableNotificationListPtr v (new StripableNotificationList);
|
||||
for (CoreSelection::StripableAutomationControls::iterator i = sac.begin(); i != sac.end(); ++i) {
|
||||
if ((*i).stripable) {
|
||||
v->push_back (boost::weak_ptr<Stripable> ((*i).stripable));
|
||||
}
|
||||
}
|
||||
if (!v->empty()) {
|
||||
StripableSelectionChanged (v); /* EMIT SIGNAL */
|
||||
}
|
||||
}
|
||||
if (!_session) {
|
||||
return;
|
||||
}
|
||||
|
||||
{
|
||||
Glib::Threads::RWLock::ReaderLock lm (protocols_lock);
|
||||
|
||||
for (list<ControlProtocolInfo*>::iterator i = control_protocol_info.begin(); i != control_protocol_info.end(); ++i) {
|
||||
|
|
@ -116,6 +100,21 @@ ControlProtocolManager::set_session (Session* s)
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
CoreSelection::StripableAutomationControls sac;
|
||||
_session->selection().get_stripables (sac);
|
||||
|
||||
if (!sac.empty()) {
|
||||
StripableNotificationListPtr v (new StripableNotificationList);
|
||||
for (CoreSelection::StripableAutomationControls::iterator i = sac.begin(); i != sac.end(); ++i) {
|
||||
if ((*i).stripable) {
|
||||
v->push_back (boost::weak_ptr<Stripable> ((*i).stripable));
|
||||
}
|
||||
}
|
||||
if (!v->empty()) {
|
||||
StripableSelectionChanged (v); /* EMIT SIGNAL */
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
int
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue