event: make events dynamic

Use uri for the events.
This commit is contained in:
Wim Taymans 2017-03-21 20:39:20 +01:00
parent 5bccb1aeea
commit 4d9f2c5161
23 changed files with 299 additions and 285 deletions

View file

@ -171,7 +171,8 @@ do_command (SpaLoop *loop,
}
if (async) {
SpaNodeEventAsyncComplete ac = SPA_NODE_EVENT_ASYNC_COMPLETE_INIT (seq, res);
SpaNodeEventAsyncComplete ac = SPA_NODE_EVENT_ASYNC_COMPLETE_INIT (this->uri.node_events.AsyncComplete,
seq, res);
spa_loop_invoke (this->main_loop,
do_send_event,
SPA_ID_INVALID,
@ -800,6 +801,7 @@ alsa_sink_init (const SpaHandleFactory *factory,
spa_media_subtypes_audio_map (this->map, &this->uri.media_subtypes_audio);
spa_prop_audio_map (this->map, &this->uri.prop_audio);
spa_audio_formats_map (this->map, &this->uri.audio_formats);
spa_node_events_map (this->map, &this->uri.node_events);
this->node = alsasink_node;
this->stream = SND_PCM_STREAM_PLAYBACK;