diff options
author | Miriam Zimmerman <[email protected]> | 2024-08-30 15:52:03 -0400 |
---|---|---|
committer | Paul Adenot <[email protected]> | 2024-09-06 10:38:17 +0200 |
commit | 19d2f7bce6a4d0566a07f3187d2bc5f0ec95c1c4 (patch) | |
tree | a9427ea5ceaa243af81e4f35caaa5cb6287d681d /src | |
parent | 8f6c9a01ddd7c1ac8360b9a31c54e24826ad073f (diff) | |
download | cubeb-19d2f7bce6a4d0566a07f3187d2bc5f0ec95c1c4.tar.gz cubeb-19d2f7bce6a4d0566a07f3187d2bc5f0ec95c1c4.zip |
wasapi: Fix default device handling.
Prior to https://github.com/mozilla/cubeb/pull/682,
a device could be default for all of
MULTIMEDIA, NOTIFICATION, and
VOICE.
After that PR, the first two were
mutually exclusive with the third, I
believe unintentionally.
Restore this behavior so that, e.g.,
on devices with only one output device,
querying for the "voice" device returns
that device.
Diffstat (limited to 'src')
-rw-r--r-- | src/cubeb_wasapi.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/cubeb_wasapi.cpp b/src/cubeb_wasapi.cpp index 01417a5..f13c5ad 100644 --- a/src/cubeb_wasapi.cpp +++ b/src/cubeb_wasapi.cpp @@ -3323,7 +3323,8 @@ wasapi_create_device(cubeb * ctx, cubeb_device_info & ret, ret.preferred = (cubeb_device_pref)(ret.preferred | CUBEB_DEVICE_PREF_MULTIMEDIA | CUBEB_DEVICE_PREF_NOTIFICATION); - } else if (defaults->is_default(flow, eCommunications, device_id.get())) { + } + if (defaults->is_default(flow, eCommunications, device_id.get())) { ret.preferred = (cubeb_device_pref)(ret.preferred | CUBEB_DEVICE_PREF_VOICE); } |