Commit b268433a authored by Marijn Suijten's avatar Marijn Suijten 🦀

fixup! bluetooth: Synchronize AVRCP Absolute Volume with A2DP sink

parent 91c54f1f
...@@ -418,10 +418,17 @@ pa_hashmap *pa_bluetooth_transport_get_all(pa_bluetooth_discovery *y) { ...@@ -418,10 +418,17 @@ pa_hashmap *pa_bluetooth_transport_get_all(pa_bluetooth_discovery *y) {
static void pa_bluetooth_transport_remote_volume_changed(pa_bluetooth_transport *t, pa_volume_t volume) { static void pa_bluetooth_transport_remote_volume_changed(pa_bluetooth_transport *t, pa_volume_t volume) {
pa_bluetooth_hook_t hook; pa_bluetooth_hook_t hook;
bool is_source;
pa_assert(t); pa_assert(t);
if (pa_bluetooth_profile_is_a2dp_source(t->profile)) { is_source = pa_bluetooth_profile_is_a2dp_source(t->profile);
pa_log_debug("Reporting volume change %d/127 for %s",
volume,
is_source ? "source" : "sink");
if (is_source) {
t->rx_volume_gain = volume; t->rx_volume_gain = volume;
hook = PA_BLUETOOTH_HOOK_TRANSPORT_RX_VOLUME_GAIN_CHANGED; hook = PA_BLUETOOTH_HOOK_TRANSPORT_RX_VOLUME_GAIN_CHANGED;
} else if (pa_bluetooth_profile_is_a2dp_sink(t->profile)) { } else if (pa_bluetooth_profile_is_a2dp_sink(t->profile)) {
...@@ -771,6 +778,8 @@ static void parse_transport_property(pa_bluetooth_transport *t, DBusMessageIter ...@@ -771,6 +778,8 @@ static void parse_transport_property(pa_bluetooth_transport *t, DBusMessageIter
if (key == NULL) if (key == NULL)
return; return;
pa_log_debug("Transport property %s changed", key);
dbus_message_iter_recurse(i, &variant_i); dbus_message_iter_recurse(i, &variant_i);
switch (dbus_message_iter_get_arg_type(&variant_i)) { switch (dbus_message_iter_get_arg_type(&variant_i)) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment