1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00

Check if zone is active in MPEInstrument::updateNoteTotalPitchbend() to fix a zone mismatch bug

This commit is contained in:
ed 2020-02-13 11:58:41 +00:00
parent 2650458e1f
commit 8209053244

View file

@ -497,11 +497,13 @@ void MPEInstrument::updateNoteTotalPitchbend (MPENote& note)
{
auto zone = zoneLayout.getLowerZone();
if (! zone.isUsing (note.midiChannel))
if (! zone.isActive() || ! zone.isUsing (note.midiChannel))
{
if (zoneLayout.getUpperZone().isUsing (note.midiChannel))
auto upperZone = zoneLayout.getUpperZone();
if (upperZone.isActive() && upperZone.isUsing (note.midiChannel))
{
zone = zoneLayout.getUpperZone();
zone = upperZone;
}
else
{