Skip to content

Commit

Permalink
Merge pull request #991 from werhner/master
Browse files Browse the repository at this point in the history
add lsp-bridge-raw-imenu-modes
  • Loading branch information
manateelazycat authored Jul 13, 2024
2 parents 3e96278 + 007ce04 commit f47cf14
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion lsp-bridge-imenu.el
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,15 @@
(require 'imenu)
(require 'lsp-bridge)

(defcustom lsp-bridge-raw-imenu-modes
'(emacs-lisp-mode org-mode)
"Modes that use `imenu' instead of Lsp-bridge imenu."
:type 'cons)

;;;###autoload
(defun lsp-bridge-imenu ()
(interactive)
(if (equal major-mode 'emacs-lisp-mode)
(if (memq major-mode lsp-bridge-raw-imenu-modes)
(call-interactively 'imenu)
(lsp-bridge-call-file-api "imenu")))

Expand Down

0 comments on commit f47cf14

Please sign in to comment.