diff options
author | Carl Hetherington <carl@carlh.net> | 2012-05-28 21:01:43 +0000 |
---|---|---|
committer | Carl Hetherington <carl@carlh.net> | 2012-05-28 21:01:43 +0000 |
commit | cc12b6bba57ca98d5db567ca2bf9536d7d772e53 (patch) | |
tree | 512ee343bb430dac6f9d9858fe5126704f29a1b4 | |
parent | dfd842812c038f553e8887e9c07eab9dc09ccf62 (diff) |
Emit SelectionCleared() when unique-selecting the first
note in a region, so that other regions clear their
selections.
git-svn-id: svn://localhost/ardour2/branches/3.0@12472 d708f5d6-7413-0410-9779-e7cbd77b26cf
-rw-r--r-- | gtk2_ardour/midi_region_view.cc | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/gtk2_ardour/midi_region_view.cc b/gtk2_ardour/midi_region_view.cc index 299ca8ee50..db68223908 100644 --- a/gtk2_ardour/midi_region_view.cc +++ b/gtk2_ardour/midi_region_view.cc @@ -1941,6 +1941,14 @@ MidiRegionView::clear_selection_except (ArdourCanvas::CanvasNoteEvent* ev, bool { bool changed = false; + if (ev && !ev->selected ()) { + /* We're selecting this note, so the selection has changed; if + there is nothing else currently selected, the loop below will + not pick up on the change. + */ + changed = true; + } + for (Selection::iterator i = _selection.begin(); i != _selection.end(); ) { if ((*i) != ev) { Selection::iterator tmp = i; |