]> git.eshelyaron.com Git - emacs.git/commitdiff
Make image-dired-rotate-original-{left,right} respect marks
authorMorgan Smith <Morgan.J.Smith@outlook.com>
Thu, 8 Sep 2022 00:09:52 +0000 (02:09 +0200)
committerStefan Kangas <stefankangas@gmail.com>
Thu, 8 Sep 2022 00:15:14 +0000 (02:15 +0200)
* lisp/image/image-dired.el (image-dired-rotate-original-left)
(image-dired-rotate-original-right): Rotate all marked
files.  (Bug#57651)

lisp/image/image-dired.el

index 88f4ceaffb4ccdc554f0f64ff3b05af732bb2461..923efa8145e51907f4c0ae6915275c25f7a1a04f 100644 (file)
@@ -1126,7 +1126,8 @@ and a confirmation is needed before the original image files is
 overwritten.  This confirmation can be turned off using
 `image-dired-rotate-original-ask-before-overwrite'."
   (interactive nil image-dired-thumbnail-mode)
-  (image-dired-rotate-original "270"))
+  (image-dired--with-marked
+   (image-dired-rotate-original "270")))
 
 (defun image-dired-rotate-original-right ()
   "Rotate original image right (clockwise) 90 degrees.
@@ -1135,7 +1136,8 @@ and a confirmation is needed before the original image files is
 overwritten.  This confirmation can be turned off using
 `image-dired-rotate-original-ask-before-overwrite'."
   (interactive nil image-dired-thumbnail-mode)
-  (image-dired-rotate-original "90"))
+  (image-dired--with-marked
+   (image-dired-rotate-original "90")))
 
 (defun image-dired-display-next-thumbnail-original (&optional arg)
   "Move to the next image in the thumbnail buffer and display it.