From 39cf0a5a1bfaac31f911bf833ee949f1e2e1a100 Mon Sep 17 00:00:00 2001 From: Mike Blumenkrantz Date: Sun, 15 Dec 2013 10:13:37 -0500 Subject: [PATCH] try connecting to pulse on a timer after it gets started in case it's a slow startup --- src/modules/mixer/sys_pulse.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/modules/mixer/sys_pulse.c b/src/modules/mixer/sys_pulse.c index 1bfab2de0..73a2bef98 100644 --- a/src/modules/mixer/sys_pulse.c +++ b/src/modules/mixer/sys_pulse.c @@ -19,12 +19,20 @@ static unsigned int disc_count = 0; static unsigned int update_count = 0; static Ecore_Timer *update_timer = NULL; +static Eina_Bool +_pulse_start(void *d EINA_UNUSED) +{ + update_timer = NULL; + e_mixer_pulse_init(); + return EINA_FALSE; +} static Eina_Bool _pulse_started(void *data EINA_UNUSED, int type EINA_UNUSED, E_Exec_Instance *inst) { if (inst != pulse_inst) return ECORE_CALLBACK_RENEW; - e_mixer_pulse_init(); + if (!update_timer) + update_timer = ecore_timer_add(2.0, _pulse_start, NULL); return ECORE_CALLBACK_DONE; }