Skip to content

Commit

Permalink
Maybe re-init will do the trick
Browse files Browse the repository at this point in the history
  • Loading branch information
koteq committed Aug 25, 2024
1 parent bf69a0c commit 2c49a25
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions Source/IconMenu.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -222,8 +222,11 @@ void IconMenu::changeListenerCallback(ChangeBroadcaster* changed)
else if (changed == &deviceManager)
{
// JUCE handles output device changes, but fails to do the same for input devices, e.g. when mic gets reconnected
deviceManager.closeAudioDevice();
deviceManager.restartLastAudioDevice();
if (auto state = deviceManager.createStateXml())
{
deviceManager.initialise(256, 256, state.get(), true);
}

dumpDeviceInfo();
}
}
Expand Down

0 comments on commit 2c49a25

Please sign in to comment.