pidgin: df2a3406: Show the submenu for the toplevel menu w...
sadrul at pidgin.im
sadrul at pidgin.im
Tue Jan 6 17:46:28 EST 2009
-----------------------------------------------------------------
Revision: df2a3406011776c81e22d17fb2c43581cfc05883
Ancestor: b17f5a8d5ea616bc3b0bf4e5bfb21cd7c63c0bb2
Author: sadrul at pidgin.im
Date: 2009-01-06T16:19:16
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/df2a3406011776c81e22d17fb2c43581cfc05883
Modified files:
finch/libgnt/gntwindow.c
ChangeLog:
Show the submenu for the toplevel menu without requiring a keypress from the user.
-------------- next part --------------
============================================================
--- finch/libgnt/gntwindow.c f653edd2e24f5f8a5d67bf830dd209d67eec8baa
+++ finch/libgnt/gntwindow.c 756cd9ebdc490c0343ab2f3fccb2d5a55d33d960
@@ -49,7 +49,16 @@ show_menu(GntBindable *bind, GList *null
{
GntWindow *win = GNT_WINDOW(bind);
if (win->menu) {
- gnt_screen_menu_show(win->menu);
+ GntMenu *menu = win->menu;
+
+ gnt_screen_menu_show(menu);
+ if (menu->type == GNT_MENU_TOPLEVEL) {
+ GntMenuItem *item;
+ item = g_list_nth_data(menu->list, menu->selected);
+ if (item && gnt_menuitem_get_submenu(item)) {
+ gnt_widget_activate(GNT_WIDGET(menu));
+ }
+ }
return TRUE;
}
return FALSE;
More information about the Commits
mailing list