diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2009-09-10 21:19:01 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2009-09-10 21:19:01 +0000 |
commit | 2ff1cd99af1b32434819c9dc48f1c5459837eaa3 (patch) | |
tree | 1f73efc0b418a1b9c225a748eb091b9e4a34186f /gtk2_ardour/midi_streamview.cc | |
parent | 7b8adc78b6082efb2c46822ddb5d8347a4e20e9e (diff) |
do not crash when loading old history files with MIDI edits; add all notes in region to canvas, but pay attention to visibility
git-svn-id: svn://localhost/ardour2/branches/3.0@5652 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/midi_streamview.cc')
-rw-r--r-- | gtk2_ardour/midi_streamview.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/gtk2_ardour/midi_streamview.cc b/gtk2_ardour/midi_streamview.cc index 6f2e81f0ff..09abaeb749 100644 --- a/gtk2_ardour/midi_streamview.cc +++ b/gtk2_ardour/midi_streamview.cc @@ -589,8 +589,6 @@ MidiStreamView::update_rec_regions (boost::shared_ptr<MidiModel> data, nframes_t if (note->time() + region->position() > start + dur) break; - mrv->add_note(note); - if (note->note() < _lowest_note) { _lowest_note = note->note(); update_range = true; @@ -598,6 +596,9 @@ MidiStreamView::update_rec_regions (boost::shared_ptr<MidiModel> data, nframes_t _highest_note = note->note(); update_range = true; } + + mrv->add_note (note, !update_range); + } mrv->extend_active_notes(); |