mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-02-16 09:14:18 +00:00
Bind "u", "@" in diff-mode-read-only-map, not diff-mode-shared-map
* lisp/vc/diff-mode.el (diff-mode-shared-map): Move bindings for "u" and "@" from here ... (diff-mode-read-only-map): ... to here.
This commit is contained in:
parent
ccee1c0de6
commit
10aa35bab7
1 changed files with 13 additions and 10 deletions
|
|
@ -218,15 +218,7 @@ See also `diff-mode-read-only-map'."
|
|||
"RET" #'diff-goto-source
|
||||
"<mouse-2>" #'diff-goto-source
|
||||
"o" #'diff-goto-source ; other-window
|
||||
"<remap> <undo>" #'undo-ignore-read-only
|
||||
|
||||
;; The foregoing commands don't affect buffers beyond this one.
|
||||
;; The following command is the only one that has a single-character
|
||||
;; binding and which affects buffers beyond this one.
|
||||
;; However, the following command asks for confirmation by default,
|
||||
;; so that seems okay. --spwhitton
|
||||
"u" #'diff-revert-and-kill-hunk
|
||||
"@" #'diff-revert-and-kill-hunk)
|
||||
"<remap> <undo>" #'undo-ignore-read-only)
|
||||
|
||||
;; Not `diff-read-only-mode-map' because there is no such mode
|
||||
;; `diff-read-only-mode'; see comment above.
|
||||
|
|
@ -245,7 +237,18 @@ buffers."
|
|||
"A" #'diff-ediff-patch
|
||||
"r" #'diff-restrict-view
|
||||
"R" #'diff-reverse-direction
|
||||
"s" #'diff-split-hunk)
|
||||
"s" #'diff-split-hunk
|
||||
|
||||
;; The foregoing commands in `diff-mode-shared-map' and
|
||||
;; `diff-mode-read-only-map' don't affect buffers beyond this one.
|
||||
;; The following command is the only one that has a single-character
|
||||
;; binding and which affects buffers beyond this one. However, the
|
||||
;; following command asks for confirmation by default, so that seems
|
||||
;; okay. --spwhitton
|
||||
"u" #'diff-revert-and-kill-hunk
|
||||
;; `diff-revert-and-kill-hunk' is the `diff-mode' analogue of what '@'
|
||||
;; does in VC-Dir, so give it the same short binding.
|
||||
"@" #'diff-revert-and-kill-hunk)
|
||||
|
||||
(defvar-keymap diff-mode-map
|
||||
:doc "Keymap for `diff-mode'. See also `diff-mode-shared-map'."
|
||||
|
|
|
|||
Loading…
Reference in a new issue