]> git.eshelyaron.com Git - emacs.git/commitdiff
image-dired: Mark two slideshow defuns as internal
authorStefan Kangas <stefankangas@gmail.com>
Fri, 23 Sep 2022 18:18:17 +0000 (20:18 +0200)
committerStefan Kangas <stefankangas@gmail.com>
Fri, 23 Sep 2022 21:12:24 +0000 (23:12 +0200)
* lisp/image/image-dired.el (image-dired--slideshow-step)
(image-dired--slideshow-stop): Rename from
'image-dired--slideshow-step' and 'image-dired--slideshow-stop'.
Update callers and make old names into obsolete aliases.

lisp/image/image-dired.el

index c074f3312d5bb2b3f181c7180e18bbd854dace76..41decbd3414bd461c5f70e3312fb7cb1112a546a 100644 (file)
@@ -974,12 +974,12 @@ This is used by `image-dired-slideshow-start'."
 
 (defvar image-dired--slideshow-initial nil)
 
-(defun image-dired-slideshow-step ()
+(defun image-dired--slideshow-step ()
   "Step to next image in a slideshow."
   (if-let ((buf (get-buffer image-dired-thumbnail-buffer)))
       (with-current-buffer buf
         (image-dired-display-next-thumbnail-original))
-    (image-dired-slideshow-stop)))
+    (image-dired--slideshow-stop)))
 
 (defun image-dired-slideshow-start (&optional arg)
   "Start a slideshow, waiting `image-dired-slideshow-delay' between images.
@@ -1001,17 +1001,17 @@ With a negative prefix argument, prompt user for the delay."
     (setq image-dired--slideshow-timer
           (run-with-timer
            0 delay
-           'image-dired-slideshow-step))
-    (add-hook 'post-command-hook 'image-dired-slideshow-stop)
+           'image-dired--slideshow-step))
+    (add-hook 'post-command-hook 'image-dired--slideshow-stop)
     (setq image-dired--slideshow-initial t)
     (message "Running slideshow; use any command to stop")))
 
-(defun image-dired-slideshow-stop ()
+(defun image-dired--slideshow-stop ()
   "Cancel slideshow."
   ;; Make sure we don't immediately stop after
   ;; `image-dired-slideshow-start'.
   (unless image-dired--slideshow-initial
-    (remove-hook 'post-command-hook 'image-dired-slideshow-stop)
+    (remove-hook 'post-command-hook 'image-dired--slideshow-stop)
     (cancel-timer image-dired--slideshow-timer))
   (setq image-dired--slideshow-initial nil))
 
@@ -1826,6 +1826,8 @@ when using per-directory thumbnail file storage"))
       (insert "  </body>\n")
       (insert "</html>"))))
 
+(define-obsolete-function-alias 'image-dired-slideshow-step #'image-dired--slideshow-step "29.1")
+(define-obsolete-function-alias 'image-dired-slideshow-stop #'image-dired--slideshow-stop "29.1")
 (define-obsolete-function-alias 'image-dired-create-display-image-buffer
   #'ignore "29.1")
 (define-obsolete-function-alias 'image-dired-create-gallery-lists