# HG changeset patch # User Sadrul Habib Chowdhury # Date 1194999801 0 # Node ID c8cdf0bcc8e3126fcd41e864b3077cc36731d586 # Parent b95a421c99805eb551ca93b6e9a965c68ae7c530# Parent a4860971f8611034412e494bde325583619025ff merge of '45b552be25717e53a4c0e84b9d0242ded9c05628' and '534c96a5976cb55b46a727cf2bee87140137b1e9' diff -r b95a421c9980 -r c8cdf0bcc8e3 ChangeLog.API --- a/ChangeLog.API Tue Nov 13 23:26:12 2007 +0000 +++ b/ChangeLog.API Wed Nov 14 00:23:21 2007 +0000 @@ -146,11 +146,13 @@ string id of a menuitem respectively. * Added gnt_window_get_accel_item, which returns a the id of a menuitem bound to a keystroke. - * Added gnt_menu_get_item to activate and return a menuitem of the - given id from a menu. + * Added gnt_menu_get_item to get a menuitem of the given id from a + menu. * Added gnt_menuitem_activate, which triggers the 'activate' signal on the menuitem and calls the callback function, if available. * Added GntEntryKillRing in GntEntry. + * Added gnt_window_set_maximize and gnt_window_get_maximize, and + GntWindowFlags enum. version 2.2.2 (??/??/????): libpurple: diff -r b95a421c9980 -r c8cdf0bcc8e3 finch/libgnt/gntmenu.c --- a/finch/libgnt/gntmenu.c Tue Nov 13 23:26:12 2007 +0000 +++ b/finch/libgnt/gntmenu.c Wed Nov 14 00:23:21 2007 +0000 @@ -490,9 +490,6 @@ item = NULL; } - if (item) - menuitem_activate(menu, item); - return item; } diff -r b95a421c9980 -r c8cdf0bcc8e3 finch/libgnt/gntmenu.h --- a/finch/libgnt/gntmenu.h Tue Nov 13 23:26:12 2007 +0000 +++ b/finch/libgnt/gntmenu.h Wed Nov 14 00:23:21 2007 +0000 @@ -108,7 +108,7 @@ void gnt_menu_add_item(GntMenu *menu, GntMenuItem *item); /** - * Activate and return the GntMenuItem with the given ID. + * Return the GntMenuItem with the given ID. * * @param menu The menu. * @param id The ID for an item. diff -r b95a421c9980 -r c8cdf0bcc8e3 finch/libgnt/gntwm.c --- a/finch/libgnt/gntwm.c Tue Nov 13 23:26:12 2007 +0000 +++ b/finch/libgnt/gntwm.c Wed Nov 14 00:23:21 2007 +0000 @@ -1876,8 +1876,11 @@ GntMenu *menu = GNT_WINDOW(win)->menu; if (menu) { const char *id = gnt_window_get_accel_item(GNT_WINDOW(win), keys); - if (id) - ret = (gnt_menu_get_item(menu, id) != NULL); + if (id) { + GntMenuItem *item = gnt_menu_get_item(menu, id); + if (item) + ret = gnt_menuitem_activate(item); + } } } if (!ret)