summaryrefslogtreecommitdiff
path: root/gtk2_ardour
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2017-01-10 15:18:00 +0000
committerPaul Davis <paul@linuxaudiosystems.com>2017-01-10 15:18:00 +0000
commit7551f6941f419fcfc619c68ca22c9640176442ba (patch)
tree79d318691b10bee98a7d11e520864463656f4172 /gtk2_ardour
parentb64dcbb36fc696f7dad3669c95075ca8c9e65341 (diff)
never remove tracks from selection during a range drag
Diffstat (limited to 'gtk2_ardour')
-rw-r--r--gtk2_ardour/editor_drag.cc22
1 files changed, 2 insertions, 20 deletions
diff --git a/gtk2_ardour/editor_drag.cc b/gtk2_ardour/editor_drag.cc
index cb972727d8..62437c6fea 100644
--- a/gtk2_ardour/editor_drag.cc
+++ b/gtk2_ardour/editor_drag.cc
@@ -5202,32 +5202,14 @@ SelectionDrag::motion (GdkEvent* event, bool first_move)
}
}
- //now find any tracks that are GROUPED with the tracks we selected
- TrackViewList grouped_add = new_selection;
- for (TrackViewList::const_iterator i = new_selection.begin(); i != new_selection.end(); ++i) {
- RouteTimeAxisView *n = dynamic_cast<RouteTimeAxisView *>(*i);
- if ( n && n->route()->route_group() && n->route()->route_group()->is_active() && n->route()->route_group()->enabled_property (ARDOUR::Properties::group_select.property_id) ) {
- for (TrackViewList::const_iterator j = all_tracks.begin(); j != all_tracks.end(); ++j) {
- RouteTimeAxisView *check = dynamic_cast<RouteTimeAxisView *>(*j);
- if ( check && (n != check) && (check->route()->route_group() == n->route()->route_group()) )
- grouped_add.push_back (*j);
- }
- }
- }
-
- //now compare our list with the current selection, and add or remove as necessary
+ //now compare our list with the current selection, and add as necessary
//( NOTE: most mouse moves don't change the selection so we can't just SET it for every mouse move; it gets clunky )
TrackViewList tracks_to_add;
TrackViewList tracks_to_remove;
- for (TrackViewList::const_iterator i = grouped_add.begin(); i != grouped_add.end(); ++i)
+ for (TrackViewList::const_iterator i = new_selection.begin(); i != new_selection.end(); ++i)
if ( !_editor->selection->tracks.contains ( *i ) )
tracks_to_add.push_back ( *i );
- for (TrackViewList::const_iterator i = _editor->selection->tracks.begin(); i != _editor->selection->tracks.end(); ++i)
- if ( !grouped_add.contains ( *i ) )
- tracks_to_remove.push_back ( *i );
_editor->selection->add(tracks_to_add);
- _editor->selection->remove(tracks_to_remove);
-
}
}
break;