# HG changeset patch # User Karl Heuer # Date 802660296 0 # Node ID f1585a0ecd0cce4d2855a40ccbf9db42c0fb7da0 # Parent a1c38b9b0f736b3d7dd827cd72572eafca5d2b0a (xmenu_show): Do call lw_destroy_all_widgets. (xdialog_show): Likewise. (popup_get_selection): Don't call it here. diff -r a1c38b9b0f73 -r f1585a0ecd0c src/xmenu.c --- a/src/xmenu.c Fri Jun 09 01:10:11 1995 +0000 +++ b/src/xmenu.c Fri Jun 09 01:11:36 1995 +0000 @@ -1083,7 +1083,6 @@ else if (event.type == KeyPress && dpyinfo->display == event.xbutton.display) { - lw_destroy_all_widgets (id); popup_activated_flag = 0; break; } @@ -1862,13 +1861,11 @@ /* Process events that apply to the menu. */ popup_get_selection ((XEvent *) 0, FRAME_X_DISPLAY_INFO (f), menu_id); -#if 0 /* fp turned off the following statement and wrote a comment that it is unnecessary--that the menu has already disappeared. - I observer that is not so. -- rms. */ - /* Make sure the menu disappears. */ + Nowadays the menu disappears ok, all right, but + we need to delete the widgets or multiple ones will pile up. */ lw_destroy_all_widgets (menu_id); -#endif /* Find the selected item, and its pane, to return the proper value. */ @@ -2080,6 +2077,8 @@ /* Process events that apply to the menu. */ popup_get_selection ((XEvent *) 0, FRAME_X_DISPLAY_INFO (f), dialog_id); + lw_destroy_all_widgets (dialog_id); + /* Find the selected item, and its pane, to return the proper value. */ if (menu_item_selection != 0)