Disable diff-restrict-view by default
* lisp/vc/diff-mode.el (diff-restrict-view): Disable it. * etc/NEWS: Announce the change.
This commit is contained in:
parent
6e4bceb8ce
commit
852ca2ff40
2 changed files with 8 additions and 0 deletions
7
etc/NEWS
7
etc/NEWS
|
|
@ -2825,6 +2825,13 @@ already have, consider replacing the default global bindings, like this:
|
|||
---
|
||||
*** New command alias 'vc-restore' for 'vc-revert'.
|
||||
|
||||
---
|
||||
*** The 'diff-restrict-view' command is disabled by default.
|
||||
This command is Diff mode's specialized 'narrow-to-region'.
|
||||
'narrow-to-region' has long been disabled by default, so for
|
||||
consistency, 'diff-restrict-view' is now too.
|
||||
To enable it again, use 'M-x enable-command'.
|
||||
|
||||
** Package
|
||||
|
||||
+++
|
||||
|
|
|
|||
|
|
@ -875,6 +875,7 @@ If the prefix ARG is given, restrict the view to the current file instead."
|
|||
(apply #'narrow-to-region
|
||||
(if arg (diff-bounds-of-file) (diff-bounds-of-hunk)))
|
||||
(setq-local diff-narrowed-to (if arg 'file 'hunk)))
|
||||
(put 'diff-restrict-view 'disabled t)
|
||||
|
||||
(defun diff--some-hunks-p ()
|
||||
(save-excursion
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue