Updates PianoRoll to immediately reflect note changes in BBEditor (#6242)

This commit is contained in:
merrickclay
2021-12-27 19:12:26 -07:00
committed by GitHub
parent 7f666e8071
commit 13e17496dc

View File

@@ -845,6 +845,7 @@ void PianoRoll::setCurrentPattern( Pattern* newPattern )
if( hasValidPattern() )
{
m_pattern->instrumentTrack()->disconnect( this );
m_pattern->disconnect(this);
}
// force the song-editor to stop playing if it played pattern before
@@ -905,6 +906,7 @@ void PianoRoll::setCurrentPattern( Pattern* newPattern )
connect( m_pattern->instrumentTrack(), SIGNAL( midiNoteOn( const Note& ) ), this, SLOT( startRecordNote( const Note& ) ) );
connect( m_pattern->instrumentTrack(), SIGNAL( midiNoteOff( const Note& ) ), this, SLOT( finishRecordNote( const Note& ) ) );
connect( m_pattern, SIGNAL(dataChanged()), this, SLOT(update()));
connect( m_pattern->instrumentTrack()->pianoModel(), SIGNAL( dataChanged() ), this, SLOT( update() ) );
connect(m_pattern->instrumentTrack()->firstKeyModel(), SIGNAL(dataChanged()), this, SLOT(update()));