From: Richard M. Stallman Date: Fri, 31 May 1996 20:10:02 +0000 (+0000) Subject: (single_submenu): Handle non-keymap lists like symbols. X-Git-Tag: emacs-19.34~551 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=846e8c10a08a1995639e0e383ac96a5047cedac7;p=emacs.git (single_submenu): Handle non-keymap lists like symbols. --- diff --git a/src/xmenu.c b/src/xmenu.c index ef2bbd792ac..1ea7140d50f 100644 --- a/src/xmenu.c +++ b/src/xmenu.c @@ -1377,8 +1377,12 @@ single_submenu (item_key, item_name, maps) But don't make a pane that is empty--ignore that map instead. */ for (i = 0; i < len; i++) { - if (SYMBOLP (mapvec[i])) + if (SYMBOLP (mapvec[i]) + || (CONSP (mapvec[i]) + && NILP (Fkeymapp (mapvec[i])))) { + /* Here we have a command at top level in the menu bar + as opposed to a submenu. */ top_level_items = 1; push_menu_pane (Qnil, Qnil); push_menu_item (item_name, Qt, item_key, mapvec[i], Qnil);