pidgin: 62ed11bd: Ensure that the user's close callback is...

qulogic at pidgin.im qulogic at pidgin.im
Thu Dec 22 04:41:25 EST 2011


----------------------------------------------------------------------
Revision: 62ed11bd6251d076f4987ee411c96b8e28472817
Parent:   bf80bd26d9da7a91dd596e36945dfc24115cfb9d
Author:   hyc at symas.com
Date:     12/22/11 00:45:40
Branch:   im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/62ed11bd6251d076f4987ee411c96b8e28472817

Changelog: 

Ensure that the user's close callback is invoked when search
results are closed in finch.

Fixes #14820.

Changes against parent bf80bd26d9da7a91dd596e36945dfc24115cfb9d

  patched  finch/gntnotify.c

-------------- next part --------------
============================================================
--- finch/gntnotify.c	226d2f86c1ec6a4276849f99a560304a3ba29bf7
+++ finch/gntnotify.c	5d749c9bf6941756019c317dfc3c4f69f8a79ab4
@@ -397,6 +397,12 @@ finch_notify_sr_new_rows(PurpleConnectio
 	}
 }
 
+static void
+notify_sr_destroy_cb(GntWidget *window, void *data)
+{
+	purple_notify_close(PURPLE_NOTIFY_SEARCHRESULTS, window);
+}
+
 static void *
 finch_notify_searchresults(PurpleConnection *gc, const char *title,
 		const char *primary, const char *secondary,
@@ -481,6 +487,8 @@ finch_notify_searchresults(PurpleConnect
 	}
 
 	gnt_box_add_widget(GNT_BOX(window), box);
+	g_signal_connect(G_OBJECT(tree), "destroy",
+			G_CALLBACK(notify_sr_destroy_cb), NULL);
 
 	finch_notify_sr_new_rows(gc, results, tree);
 


More information about the Commits mailing list