mirror of
https://github.com/Ardour/ardour.git
synced 2026-01-05 05:05:43 +01:00
[Summary] Implementing synchronously changed tracks/busses selection in the editor and embedded mixer bridge view.
This commit is contained in:
parent
dd2ba90810
commit
0f3f0d0a4a
3 changed files with 33 additions and 1 deletions
|
|
@ -304,6 +304,7 @@ Editor::Editor ()
|
|||
|
||||
, _region_selection_change_updates_region_list (true)
|
||||
, _following_mixer_selection (false)
|
||||
, _following_mixer_bridge_view_selection (false)
|
||||
, _control_point_toggled_on_press (false)
|
||||
, _stepping_axis_view (0)
|
||||
, current_mixer_strip (0)
|
||||
|
|
|
|||
|
|
@ -2095,6 +2095,9 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
|
|||
void follow_mixer_selection ();
|
||||
bool _following_mixer_selection;
|
||||
|
||||
void follow_mixer_bridge_view_selection ();
|
||||
bool _following_mixer_bridge_view_selection;
|
||||
|
||||
int time_fx (ARDOUR::RegionList&, float val, bool pitching);
|
||||
void note_edit_done (int, EditNoteDialog*);
|
||||
void toggle_sound_midi_notes ();
|
||||
|
|
|
|||
|
|
@ -255,13 +255,14 @@ void
|
|||
Editor::track_mixer_selection ()
|
||||
{
|
||||
Mixer_UI::instance()->selection().RoutesChanged.connect (sigc::mem_fun (*this, &Editor::follow_mixer_selection));
|
||||
_mixer_bridge_view.selection().RoutesChanged.connect (sigc::mem_fun (*this, &Editor::follow_mixer_bridge_view_selection));
|
||||
_mixer_bridge_view.track_editor_selection ();
|
||||
}
|
||||
|
||||
void
|
||||
Editor::follow_mixer_selection ()
|
||||
{
|
||||
if (!ARDOUR::Config->get_link_editor_and_mixer_selection() || _following_mixer_selection) {
|
||||
if (/*!ARDOUR::Config->get_link_editor_and_mixer_selection() ||*/ _following_mixer_selection) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -283,3 +284,30 @@ Editor::follow_mixer_selection ()
|
|||
selection->block_tracks_changed (false);
|
||||
selection->TracksChanged (); /* EMIT SIGNAL */
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
Editor::follow_mixer_bridge_view_selection ()
|
||||
{
|
||||
if (/*!ARDOUR::Config->get_link_editor_and_mixer_selection() || */_following_mixer_bridge_view_selection) {
|
||||
return;
|
||||
}
|
||||
|
||||
_following_mixer_bridge_view_selection = true;
|
||||
selection->block_tracks_changed (true);
|
||||
|
||||
RouteUISelection& s (_mixer_bridge_view.selection().routes);
|
||||
|
||||
selection->clear_tracks ();
|
||||
|
||||
for (RouteUISelection::iterator i = s.begin(); i != s.end(); ++i) {
|
||||
TimeAxisView* tav = get_route_view_by_route_id ((*i)->route()->id());
|
||||
if (tav) {
|
||||
selection->add (tav);
|
||||
}
|
||||
}
|
||||
|
||||
_following_mixer_bridge_view_selection = false;
|
||||
selection->block_tracks_changed (false);
|
||||
selection->TracksChanged (); /* EMIT SIGNAL */
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue