Make easymenu downcase the menu symbol for greater backwards compat

* lisp/cmuscheme.el (map): Revert previous fix.

* lisp/woman.el (woman-dired-define-keys): Ditto.

* lisp/emacs-lisp/easymenu.el (easy-menu-do-define): Downcase the
menu name for greater backwards compatibility.
This commit is contained in:
Lars Ingebrigtsen 2021-03-01 22:12:43 +01:00
parent 0d827c7f52
commit e5392d38ac
3 changed files with 7 additions and 3 deletions

View file

@ -132,7 +132,7 @@
(define-key scheme-mode-map "\C-c\C-l" 'scheme-load-file)
(define-key scheme-mode-map "\C-c\C-k" 'scheme-compile-file) ;k for "kompile"
(let ((map (lookup-key scheme-mode-map [menu-bar Scheme])))
(let ((map (lookup-key scheme-mode-map [menu-bar scheme])))
(define-key map [separator-eval] '("--"))
(define-key map [compile-file]
'("Compile Scheme File" . scheme-compile-file))

View file

@ -190,7 +190,11 @@ This is expected to be bound to a mouse event."
(function-put symbol 'completion-predicate #'ignore))
(dolist (map (if (keymapp maps) (list maps) maps))
(define-key map
(vector 'menu-bar (easy-menu-intern (car menu)))
(vector 'menu-bar (if (symbolp (car menu))
(car menu)
;; If a string, then use the downcased
;; version for greater backwards compatibiltiy.
(intern (downcase (car menu)))))
(easy-menu-binding keymap (car menu))))))
(defun easy-menu-filter-return (menu &optional name)

View file

@ -1523,7 +1523,7 @@ Also make each path-info component into a list.
(mapc 'woman-dired-define-key woman-dired-keys)
(woman-dired-define-key-maybe "w")
(woman-dired-define-key-maybe "W")))
(define-key-after (lookup-key dired-mode-map [menu-bar Immediate])
(define-key-after (lookup-key dired-mode-map [menu-bar immediate])
[woman] '("Read Man Page (WoMan)" . woman-dired-find-file) 'view))
(if (featurep 'dired)