+2006-09-01 Chong Yidong <cyd@stupidchicken.com>
+
+ * imenu.el (imenu-update-menubar): Use buffer-chars-modified-tick.
+
2006-08-31 Richard Stallman <rms@gnu.org>
* cus-edit.el (custom-save-variables): Slight cleanup.
(defvar imenu-buffer-menubar nil)
(defvar imenu-menubar-modified-tick 0
- "The value of (buffer-modified-tick) as of last call to `imenu-update-menubar'.")
+ "The value of (buffer-chars-modified-tick) as of the last call
+to `imenu-update-menubar'.")
(make-variable-buffer-local 'imenu-menubar-modified-tick)
(defun imenu-update-menubar ()
(when (and (current-local-map)
(keymapp (lookup-key (current-local-map) [menu-bar index]))
- (not (eq (buffer-modified-tick)
- imenu-menubar-modified-tick)))
- (setq imenu-menubar-modified-tick (buffer-modified-tick))
+ (/= (buffer-chars-modified-tick) imenu-menubar-modified-tick))
+ (setq imenu-menubar-modified-tick (buffer-chars-modified-tick))
(let ((index-alist (imenu--make-index-alist t)))
;; Don't bother updating if the index-alist has not changed
;; since the last time we did it.