pidgin: 3d4c6390: Destroy the menu-actions created by plug...

sadrul at pidgin.im sadrul at pidgin.im
Fri Nov 20 17:51:51 EST 2009


-----------------------------------------------------------------
Revision: 3d4c639042fbd0a2602bdee93b94788a6e9f24b5
Ancestor: d2e4543d037494ddd30457a8d6dd42a05816cc00
Author: sadrul at pidgin.im
Date: 2009-11-20T21:49:36
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/3d4c639042fbd0a2602bdee93b94788a6e9f24b5

Modified files:
        finch/gntblist.c

ChangeLog: 

Destroy the menu-actions created by plugins for the context menus.

-------------- next part --------------
============================================================
--- finch/gntblist.c	0064525c2078fc90cffe446b196b81763b6dd3e7
+++ finch/gntblist.c	db1b1fbee651cea0f3e4ef5c5cd5370cf4f2882e
@@ -1119,6 +1119,8 @@ append_proto_menu(GntMenu *menu, PurpleC
 		PurpleMenuAction *act = (PurpleMenuAction *) list->data;
 		act->data = node;
 		gnt_append_menu_action(menu, act, NULL);
+		g_signal_connect_swapped(G_OBJECT(menu), "destroy",
+			G_CALLBACK(purple_menu_action_free), act);
 	}
 }
 
@@ -1368,6 +1370,8 @@ append_extended_menu(GntMenu *menu, Purp
 			iter; iter = g_list_delete_link(iter, iter))
 	{
 		gnt_append_menu_action(menu, iter->data, NULL);
+		g_signal_connect_swapped(G_OBJECT(menu), "destroy",
+				G_CALLBACK(purple_menu_action_free), iter->data);
 	}
 }
 


More information about the Commits mailing list