1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-05-01 16:19:43 +02:00

Bug1321 (partial): Don't change output balance when closing Preferences unless...

... you really changed Device preferences.
This commit is contained in:
Paul Licameli 2016-02-11 12:01:42 -05:00
parent 3f4a9191ec
commit 5f76da4f5b

View File

@ -1107,8 +1107,13 @@ void AudioIO::HandleDeviceChange()
return;
// get the selected record and playback devices
int playDeviceNum = getPlayDevIndex();
int recDeviceNum = getRecordDevIndex();
const int playDeviceNum = getPlayDevIndex();
const int recDeviceNum = getRecordDevIndex();
// If no change needed, return
if (mCachedPlaybackIndex == playDeviceNum &&
mCachedCaptureIndex == recDeviceNum)
return;
// cache playback/capture rates
mCachedPlaybackRates = GetSupportedPlaybackRates(playDeviceNum);