[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#30449: imenu contains redundant '*Rescan*' item with auto refresh
From: |
Lars Ingebrigtsen |
Subject: |
bug#30449: imenu contains redundant '*Rescan*' item with auto refresh |
Date: |
Sun, 14 Jul 2019 18:32:45 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) |
Campbell Barton <ideasman42@gmail.com> writes:
> With imenu package when auto rescan is enabled:
>
> (setq imenu-auto-rescan t)
>
> imenu shows a '*Refresh*' option,
> which should not be displayed when auto-rescan is used.
>
> See reference: https://emacs.stackexchange.com/a/38808/2418
I don't use imenu, so I can't really test, but does the following fix
the problem?
diff --git a/lisp/imenu.el b/lisp/imenu.el
index 5084fe61ef..9df597b4d6 100644
--- a/lisp/imenu.el
+++ b/lisp/imenu.el
@@ -510,8 +510,9 @@ imenu--make-index-alist
"No items suitable for an index found in this buffer"))
(or imenu--index-alist
(setq imenu--index-alist (list nil)))
- ;; Add a rescan option to the index.
- (cons imenu--rescan-item imenu--index-alist))
+ (unless imenu-auto-rescan
+ ;; Add a rescan option to the index.
+ (cons imenu--rescan-item imenu--index-alist)))
(defvar imenu--cleanup-seen nil)
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- bug#30449: imenu contains redundant '*Rescan*' item with auto refresh,
Lars Ingebrigtsen <=