mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-18 00:54:19 +00:00
iOS/Android PlugIn Standalone: Fixed an issue where midi callbacks would be added twice
This commit is contained in:
parent
b56e3890c2
commit
ffdc318d7f
1 changed files with 0 additions and 10 deletions
|
|
@ -520,22 +520,12 @@ private:
|
|||
if (newMidiDevices != lastMidiDevices)
|
||||
{
|
||||
for (auto& oldDevice : lastMidiDevices)
|
||||
{
|
||||
if (! newMidiDevices.contains (oldDevice))
|
||||
{
|
||||
deviceManager.setMidiInputEnabled (oldDevice, false);
|
||||
deviceManager.removeMidiInputCallback (oldDevice, &player);
|
||||
}
|
||||
}
|
||||
|
||||
for (auto& newDevice : newMidiDevices)
|
||||
{
|
||||
if (! lastMidiDevices.contains (newDevice))
|
||||
{
|
||||
deviceManager.addMidiInputCallback (newDevice, &player);
|
||||
deviceManager.setMidiInputEnabled (newDevice, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue