fix audio setting persistence for already selected device

This commit is contained in:
Zach Pomerantz 2017-03-28 15:34:42 -04:00
parent 5e0cfb6137
commit 06bf5807ae

View file

@ -154,6 +154,7 @@ function switchAudioDevice(audioDeviceMenuString) {
}
} else {
debug("Selected input device is the same as the current input device!")
Settings.setValue(INPUT_DEVICE_SETTING, selectedDevice);
Menu.setIsOptionChecked(audioDeviceMenuString, true);
AudioDevice.setInputDevice(selectedDevice); // Still try to force-set the device (in case the user's trying to forcefully debug an issue)
}
@ -172,6 +173,7 @@ function switchAudioDevice(audioDeviceMenuString) {
}
} else {
debug("Selected output device is the same as the current output device!")
Settings.setValue(OUTPUT_DEVICE_SETTING, selectedDevice);
Menu.setIsOptionChecked(audioDeviceMenuString, true);
AudioDevice.setOutputDevice(selectedDevice); // Still try to force-set the device (in case the user's trying to forcefully debug an issue)
}