pidgin.vv: ef36bf6e: Use purple_timeout_* instead of g_timeou...

maiku at soc.pidgin.im maiku at soc.pidgin.im
Tue Feb 24 03:30:27 EST 2009


-----------------------------------------------------------------
Revision: ef36bf6ea65f4599818d1e448a5e8f5591f873e0
Ancestor: b93709e892e63c46b340b4bac70abe2eeef22a38
Author: maiku at soc.pidgin.im
Date: 2009-02-24T08:25:23
Branch: im.pidgin.pidgin.vv
URL: http://d.pidgin.im/viewmtn/revision/info/ef36bf6ea65f4599818d1e448a5e8f5591f873e0

Modified files:
        libpurple/media.c

ChangeLog: 

Use purple_timeout_* instead of g_timeout_*.

-------------- next part --------------
============================================================
--- libpurple/media.c	e4f3dbaef5b1789d67f4b0c07a5881d051c09396
+++ libpurple/media.c	ee4a1d9dc1ff90721c5c5e147b89f186c6b9b16a
@@ -81,6 +81,7 @@ struct _PurpleMediaStream
 	GList *active_remote_candidates;
 
 	gulong window_id;
+	guint connected_cb_id;
 };
 
 struct _PurpleMediaPrivate
@@ -253,7 +254,8 @@ purple_media_stream_free(PurpleMediaStre
 		return;
 
 	/* Remove the connected_cb timeout */
-	g_source_remove_by_user_data(stream);
+	if (stream->connected_cb_id != 0)
+		purple_timeout_remove(stream->connected_cb_id);
 
 	g_free(stream->participant);
 
@@ -1728,6 +1730,8 @@ purple_media_connected_cb(PurpleMediaStr
 {
 	g_return_val_if_fail(stream != NULL, FALSE);
 
+	stream->connected_cb_id = 0;
+
 	purple_media_manager_create_output_window(
 			stream->session->media->priv->manager,
 			stream->session->media,
@@ -1792,8 +1796,8 @@ purple_media_src_pad_added_cb(FsStream *
 		gst_element_link(stream->tee, stream->sink);
 	}
 
-	g_timeout_add_full(G_PRIORITY_HIGH, 0,
-			(GSourceFunc)purple_media_connected_cb, stream, NULL);
+	stream->connected_cb_id = purple_timeout_add(0,
+			(GSourceFunc)purple_media_connected_cb, stream);
 }
 
 static gboolean


More information about the Commits mailing list