diff options
author | Richard M. Stallman <rms@gnu.org> | 1995-11-26 20:50:52 +0000 |
---|---|---|
committer | Richard M. Stallman <rms@gnu.org> | 1995-11-26 20:50:52 +0000 |
commit | 20c1de0bd20e9ed1f805f7d65f5eeb0938c0c6c4 (patch) | |
tree | ee9873951357e896b2e767dbf636d36a417fe07e /src/xmenu.c | |
parent | cac858678fef30c177c85b3728f4dd4d00520933 (diff) | |
download | emacs-20c1de0bd20e9ed1f805f7d65f5eeb0938c0c6c4.tar.gz |
(set_frame_menubar): When called with deep_p == 0,
that invalidates the previous f->menu_bar_vector.
Diffstat (limited to 'src/xmenu.c')
-rw-r--r-- | src/xmenu.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/xmenu.c b/src/xmenu.c index 8fd87175a14..95aa47bccaa 100644 --- a/src/xmenu.c +++ b/src/xmenu.c @@ -1654,7 +1654,7 @@ set_frame_menubar (f, first_time, deep_p) if (menu_items_used == i || (previous_items[i] != XVECTOR (menu_items)->contents[i])) break; - if (i == menu_items_used && i == previous_menu_items_used) + if (i == menu_items_used && i == previous_menu_items_used && i != 0) { free_menubar_widget_value_tree (first_wv); menu_items = Qnil; @@ -1704,6 +1704,11 @@ set_frame_menubar (f, first_time, deep_p) first_wv->contents = wv; prev_wv = wv; } + + /* Forget what we thought we knew about what is in the + detailed contents of the menu bar menus. + Changing the top level always destroys the contents. */ + f->menu_bar_items_used = 0; } /* Create or update the menu bar widget. */ |