From: <sa...@us...> - 2006-10-17 04:35:26
|
Revision: 17493 http://svn.sourceforge.net/gaim/?rev=17493&view=rev Author: sadrul Date: 2006-10-16 21:34:55 -0700 (Mon, 16 Oct 2006) Log Message: ----------- Patch from Richard Nelson (wabz). This will allow the WM to do stuff when a window is closed. Also, ignore SIGPIPE, although this doesn't seem to help. Modified Paths: -------------- trunk/console/libgnt/gntmain.c Modified: trunk/console/libgnt/gntmain.c =================================================================== --- trunk/console/libgnt/gntmain.c 2006-10-17 04:07:19 UTC (rev 17492) +++ trunk/console/libgnt/gntmain.c 2006-10-17 04:34:55 UTC (rev 17493) @@ -268,7 +268,8 @@ GNT_WIDGET_UNSET_FLAGS(w, GNT_WIDGET_URGENT); if (wm.window_update) { GntNode *node = g_hash_table_lookup(nodes, w); - wm.window_update(node->panel, w); + if (node) + wm.window_update(node->panel, w); } } else if (GNT_WIDGET_IS_FLAG_SET(w, GNT_WIDGET_URGENT)) { /* This is a window with the URGENT hint set */ @@ -1158,6 +1159,7 @@ signal(SIGWINCH, sighandler); #endif signal(SIGCHLD, sighandler); + signal(SIGPIPE, SIG_IGN); g_type_init(); @@ -1225,6 +1227,9 @@ if (node == NULL) /* Yay! Nothing to do. */ return; + if (GNT_WIDGET_IS_FLAG_SET(widget, GNT_WIDGET_DESTROYING) && wm.close_window) + wm.close_window(widget); + g_hash_table_remove(nodes, widget); if (window_list) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |