]> git.0d.be Git - empathy.git/commitdiff
Ensure we call the empathy_sound_stop from the main thread
authorSjoerd Simons <sjoerd.simons@collabora.co.uk>
Wed, 26 Aug 2009 15:57:16 +0000 (16:57 +0100)
committerSjoerd Simons <sjoerd.simons@collabora.co.uk>
Wed, 26 Aug 2009 15:57:16 +0000 (16:57 +0100)
The canberra gtk context is stored in thread-local storage, so we need to
ensure that we start and stop the sounds from the same thread.

src/empathy-call-window.c

index f7ba242326fadb68f4dd71202d124a59a6882308..fed71b9952b7812f03f78a428dba0467ff1f30fd 100644 (file)
@@ -1403,6 +1403,8 @@ empathy_call_window_connected (gpointer user_data)
   EmpathyTpCall *call;
   gboolean can_send_video;
 
+  empathy_sound_stop (EMPATHY_SOUND_PHONE_OUTGOING);
+
   can_send_video = priv->video_input != NULL && priv->contact != NULL &&
     empathy_contact_can_voip_video (priv->contact);
 
@@ -1471,7 +1473,6 @@ empathy_call_window_src_added_cb (EmpathyCallHandler *handler,
       g_timer_start (priv->timer);
       priv->timer_id = g_idle_add  (empathy_call_window_connected, self);
       priv->call_state = CONNECTED;
-      empathy_sound_stop (EMPATHY_SOUND_PHONE_OUTGOING);
     }
 
   switch (media_type)