mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Ensure that audio device is always stopped before modifying in AudioDeviceManager::setAudioDeviceSetup()
This commit is contained in:
parent
450ac8ade5
commit
21e4522891
1 changed files with 2 additions and 2 deletions
|
|
@ -544,6 +544,8 @@ String AudioDeviceManager::setAudioDeviceSetup (const AudioDeviceSetup& newSetup
|
|||
else if (currentAudioDevice != nullptr)
|
||||
return {};
|
||||
|
||||
stopDevice();
|
||||
|
||||
if (getCurrentDeviceTypeObject() == nullptr
|
||||
|| (newSetup.inputDeviceName.isEmpty() && newSetup.outputDeviceName.isEmpty()))
|
||||
{
|
||||
|
|
@ -555,8 +557,6 @@ String AudioDeviceManager::setAudioDeviceSetup (const AudioDeviceSetup& newSetup
|
|||
return {};
|
||||
}
|
||||
|
||||
stopDevice();
|
||||
|
||||
String error;
|
||||
|
||||
if (currentSetup.inputDeviceName != newSetup.inputDeviceName
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue