fix crash in ghostregions after adding notes but not invalidating optimization iter (#9452)
This commit is contained in:
parent
0633254820
commit
c642611fe8
@ -333,6 +333,7 @@ MidiGhostRegion::add_note (NoteBase* n)
|
||||
{
|
||||
GhostEvent* event = new GhostEvent (n, _note_group);
|
||||
events.insert (make_pair (n->note(), event));
|
||||
_optimization_iterator = events.end();
|
||||
|
||||
event->item->set_fill_color (UIConfiguration::instance().color_mod(n->base_color(), "ghost track midi fill"));
|
||||
event->item->set_outline_color (_outline);
|
||||
|
@ -125,6 +125,7 @@ VelocityGhostRegion::add_note (NoteBase* nb)
|
||||
|
||||
GhostEvent* event = new GhostEvent (nb, _note_group, l);
|
||||
events.insert (std::make_pair (nb->note(), event));
|
||||
_optimization_iterator = events.end();
|
||||
|
||||
l->Event.connect (sigc::bind (sigc::mem_fun (*this, &VelocityGhostRegion::lollevent), event));
|
||||
l->set_ignore_events (true);
|
||||
|
Loading…
Reference in New Issue
Block a user