]> git.eshelyaron.com Git - emacs.git/commitdiff
Convert two `easy-mmode-defmap' usages to `defvar-keymap'
authorLars Ingebrigtsen <larsi@gnus.org>
Fri, 15 Oct 2021 12:19:32 +0000 (14:19 +0200)
committerLars Ingebrigtsen <larsi@gnus.org>
Fri, 15 Oct 2021 12:19:41 +0000 (14:19 +0200)
* lisp/vc/log-edit.el (log-edit-mode-map):
* lisp/vc/cvs-status.el (cvs-status-mode-map): Convert
`easy-mmode-defmap' to `defvar-keymap'.

lisp/vc/cvs-status.el
lisp/vc/log-edit.el

index 63b886362ba3238ac7f623e106bafa65446ddd46..6b49690aa428f271259f4d8c4b3dec23c0cd004a 100644 (file)
 ;;; Code:
 
 (require 'cl-lib)
-(require 'pcvs-util)
+(require 'pcvs)
+(require 'easy-mmode)
 
 ;;;
 
-(easy-mmode-defmap cvs-status-mode-map
-  '(("n"       . next-line)
-    ("p"       . previous-line)
-    ("N"       . cvs-status-next)
-    ("P"       . cvs-status-prev)
-    ("\M-n"    . cvs-status-next)
-    ("\M-p"    . cvs-status-prev)
-    ("t"       . cvs-status-cvstrees)
-    ("T"       . cvs-status-trees)
-    (">"        . cvs-mode-checkout))
-  "CVS-Status' keymap."
-  :group 'cvs-status
-  :inherit 'cvs-mode-map)
+(defvar-keymap cvs-status-mode-map
+  :inherit 'cvs-mode-map
+  "n"         #'next-line
+  "p"         #'previous-line
+  "N"         #'cvs-status-next
+  "P"         #'cvs-status-prev
+  (kbd "M-n") #'cvs-status-next
+  (kbd "M-p") #'cvs-status-prev
+  "t"         #'cvs-status-cvstrees
+  "T"         #'cvs-status-trees
+  ">"         #'cvs-mode-checkout)
 
 ;;(easy-menu-define cvs-status-menu cvs-status-mode-map
 ;;  "Menu for `cvs-status-mode'."
index 4d151d555cc2a390b696d246e1d429136f6b3eff..c8d089e4113819c8d72bd8ecc5e3e49819774b03 100644 (file)
 (define-obsolete-variable-alias 'vc-log-mode-map 'log-edit-mode-map "28.1")
 (define-obsolete-variable-alias 'vc-log-entry-mode 'log-edit-mode-map "28.1")
 
-(easy-mmode-defmap log-edit-mode-map
-  '(("\C-c\C-c" . log-edit-done)
-    ("\C-c\C-a" . log-edit-insert-changelog)
-    ("\C-c\C-w" . log-edit-generate-changelog-from-diff)
-    ("\C-c\C-d" . log-edit-show-diff)
-    ("\C-c\C-f" . log-edit-show-files)
-    ("\C-c\C-k" . log-edit-kill-buffer)
-    ("\C-a"     . log-edit-beginning-of-line)
-    ("\M-n"    . log-edit-next-comment)
-    ("\M-p"    . log-edit-previous-comment)
-    ("\M-r"    . log-edit-comment-search-backward)
-    ("\M-s"    . log-edit-comment-search-forward)
-    ("\C-c?"   . log-edit-mode-help))
-  "Keymap for the `log-edit-mode' (to edit version control log messages)."
-  :group 'log-edit)
+(defvar-keymap log-edit-mode-map
+  (kbd "C-c C-c") #'log-edit-done
+  (kbd "C-c C-a") #'log-edit-insert-changelog
+  (kbd "C-c C-w") #'log-edit-generate-changelog-from-diff
+  (kbd "C-c C-d") #'log-edit-show-diff
+  (kbd "C-c C-f") #'log-edit-show-files
+  (kbd "C-c C-k") #'log-edit-kill-buffer
+  (kbd "C-a")     #'log-edit-beginning-of-line
+  (kbd "M-n")     #'log-edit-next-comment
+  (kbd "M-p")     #'log-edit-previous-comment
+  (kbd "M-r")     #'log-edit-comment-search-backward
+  (kbd "M-s")     #'log-edit-comment-search-forward
+  (kbd "C-c ?")   #'log-edit-mode-help)
 
 (easy-menu-define log-edit-menu log-edit-mode-map
   "Menu used for `log-edit-mode'."