From: Richard M. Stallman Date: Sat, 6 Feb 1999 21:50:53 +0000 (+0000) Subject: (imenu--last-menubar-index-alist): Add doc. X-Git-Tag: emacs-20.4~679 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=0cff96e7cee5f808876ba09c91aaa25e1c311422;p=emacs.git (imenu--last-menubar-index-alist): Add doc. (imenu-add-to-menubar): Reset imenu--last-menubar-index-alist. --- diff --git a/lisp/imenu.el b/lisp/imenu.el index f9b33b80b47..4fa74b7ec72 100644 --- a/lisp/imenu.el +++ b/lisp/imenu.el @@ -426,8 +426,9 @@ This variable is local in all buffers, once set.") (make-variable-buffer-local 'imenu--index-alist) -;; The latest buffer index used to update the menu bar menu. -(defvar imenu--last-menubar-index-alist nil) +(defvar imenu--last-menubar-index-alist nil + "The latest buffer index used to update the menu bar menu.") + (make-variable-buffer-local 'imenu--last-menubar-index-alist) ;; History list for 'jump-to-function-in-buffer'. @@ -991,6 +992,7 @@ See the command `imenu' for more information." 'imenu-default-create-index-function))) (let ((newmap (make-sparse-keymap)) (menu-bar (lookup-key (current-local-map) [menu-bar]))) + (setq imenu--last-menubar-index-alist nil) (define-key newmap [menu-bar] (append (make-sparse-keymap) menu-bar)) (define-key newmap [menu-bar index]