From: "poljar (Damir Jelić)" <[email protected]>
When the offset changes a subscription event should be sent to the
relevant card.
---
src/pulsecore/device-port.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/src/pulsecore/device-port.c b/src/pulsecore/device-port.c
index 46e37e2..f39fc33 100644
--- a/src/pulsecore/device-port.c
+++ b/src/pulsecore/device-port.c
@@ -116,6 +116,8 @@ void pa_device_port_hashmap_free(pa_hashmap *h) {
void pa_device_port_set_latency_offset(pa_device_port *p, pa_usec_t offset) {
uint32_t state;
+ pa_core *core;
+ pa_card *card;
pa_assert(p);
@@ -139,4 +141,10 @@ void pa_device_port_set_latency_offset(pa_device_port *p,
pa_usec_t offset) {
break;
}
}
+
+ /* Post subscriptions to the card which owns us */
+ pa_assert_se(core = p->core);
+ PA_IDXSET_FOREACH(card, core->cards, state)
+ if (p == pa_hashmap_get(card->ports, p->name))
+ pa_subscription_post(core,
PA_SUBSCRIPTION_EVENT_CARD|PA_SUBSCRIPTION_EVENT_CHANGE, card->index);
}
--
1.7.11.1
_______________________________________________
pulseaudio-discuss mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/pulseaudio-discuss