]> git.eshelyaron.com Git - emacs.git/commitdiff
* lisp/wdired.el (wdired-next-line, wdired-previous-line): Preserve column
authorStefan Monnier <monnier@iro.umontreal.ca>
Tue, 18 Feb 2020 17:47:32 +0000 (12:47 -0500)
committerStefan Monnier <monnier@iro.umontreal.ca>
Tue, 18 Feb 2020 17:47:32 +0000 (12:47 -0500)
lisp/wdired.el

index d91853e64dd47352d0495edbe5ab8e8a34a283d6..11cbe5822a7615fb6556aa01607f255e2e4f1803 100644 (file)
@@ -640,6 +640,7 @@ Optional arguments are ignored."
 See `wdired-use-dired-vertical-movement'.  Optional prefix ARG
 says how many lines to move; default is one line."
   (interactive "^p")
+  (setq this-command 'next-line)       ;Let `line-move' preserve the column.
   (with-no-warnings (next-line arg))
   (if (or (eq wdired-use-dired-vertical-movement t)
          (and wdired-use-dired-vertical-movement
@@ -653,6 +654,7 @@ says how many lines to move; default is one line."
 See `wdired-use-dired-vertical-movement'.  Optional prefix ARG
 says how many lines to move; default is one line."
   (interactive "^p")
+  (setq this-command 'previous-line)       ;Let `line-move' preserve the column.
   (with-no-warnings (previous-line arg))
   (if (or (eq wdired-use-dired-vertical-movement t)
          (and wdired-use-dired-vertical-movement