mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2026-02-18 22:05:37 -05:00
bluetooth: Move attenuation decision to shared function
Generalize the distinction between local and peer-attenuated volumes into a function, paving the way for future changes where this needs to be checked in more places and when A2DP Absolute Volume support is added. Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/521>
This commit is contained in:
parent
d84ca03080
commit
9c847b16a8
4 changed files with 64 additions and 16 deletions
|
|
@ -191,6 +191,7 @@ pa_bluetooth_device* pa_bluetooth_discovery_get_device_by_address(pa_bluetooth_d
|
|||
pa_hook* pa_bluetooth_discovery_hook(pa_bluetooth_discovery *y, pa_bluetooth_hook_t hook);
|
||||
|
||||
const char *pa_bluetooth_profile_to_string(pa_bluetooth_profile_t profile);
|
||||
bool pa_bluetooth_profile_should_attenuate_volume(pa_bluetooth_profile_t profile);
|
||||
|
||||
static inline bool pa_bluetooth_uuid_is_hsp_hs(const char *uuid) {
|
||||
return pa_streq(uuid, PA_BLUETOOTH_UUID_HSP_HS) || pa_streq(uuid, PA_BLUETOOTH_UUID_HSP_HS_ALT);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue