1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-25 02:04:23 +00:00

win32 midi - handling for drivers returning a MIDIERR_NOTREADY error.

This commit is contained in:
jules 2014-03-05 11:40:53 +00:00
parent a2b67cbfae
commit d20441ad62

View file

@ -478,6 +478,12 @@ void MidiOutput::sendMessageNow (const MidiMessage& message)
}
else
{
midiOutShortMsg (handle->handle, *(unsigned int*) message.getRawData());
for (int i = 0; i < 50; ++i)
{
if (midiOutShortMsg (handle->handle, *(unsigned int*) message.getRawData()) != MIDIERR_NOTREADY)
break;
Sleep (1);
}
}
}