aboutsummaryrefslogtreecommitdiffstats
path: root/src/xmenu.c
diff options
context:
space:
mode:
authorChong Yidong2008-07-30 13:57:26 +0000
committerChong Yidong2008-07-30 13:57:26 +0000
commitbb08f2900cf5f80f734788bb15143d6daecd50e5 (patch)
treea91d2d07eeacd2ebb0cb2bc6612f80f42db98681 /src/xmenu.c
parent9cce74cd9637cec46af14becf5b86f0a3639cef2 (diff)
downloademacs-bb08f2900cf5f80f734788bb15143d6daecd50e5.tar.gz
emacs-bb08f2900cf5f80f734788bb15143d6daecd50e5.zip
(Fx_menu_bar_open_internal): Use activate_item signal to open menu.
Diffstat (limited to 'src/xmenu.c')
-rw-r--r--src/xmenu.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/xmenu.c b/src/xmenu.c
index d240355ef2f..6902f1e4025 100644
--- a/src/xmenu.c
+++ b/src/xmenu.c
@@ -1412,11 +1412,12 @@ If FRAME is nil or not given, use the selected frame. */)
1412 /* Activate the first menu. */ 1412 /* Activate the first menu. */
1413 GList *children = gtk_container_get_children (GTK_CONTAINER (menubar)); 1413 GList *children = gtk_container_get_children (GTK_CONTAINER (menubar));
1414 1414
1415 gtk_menu_shell_select_item (GTK_MENU_SHELL (menubar), 1415 if (children)
1416 GTK_WIDGET (children->data)); 1416 {
1417 1417 g_signal_emit_by_name (children->data, "activate_item");
1418 popup_activated_flag = 1; 1418 popup_activated_flag = 1;
1419 g_list_free (children); 1419 g_list_free (children);
1420 }
1420 } 1421 }
1421 UNBLOCK_INPUT; 1422 UNBLOCK_INPUT;
1422 1423