]> git.eshelyaron.com Git - emacs.git/commitdiff
Ensure updating the animated image in all windows
authorLars Ingebrigtsen <larsi@gnus.org>
Tue, 4 May 2021 07:57:30 +0000 (09:57 +0200)
committerLars Ingebrigtsen <larsi@gnus.org>
Tue, 4 May 2021 07:57:30 +0000 (09:57 +0200)
* lisp/image.el (image-show-frame): Simplify the window update --
pass in the buffer, which is a noop if the buffer isn't displayed.

lisp/image.el

index 643f9ddf83415f45c1a6efdabbc5df8f77cca754..ee152940311972672cea12a723f83d04fdf665d2 100644 (file)
@@ -875,9 +875,7 @@ do not check N is within the range of frames present in the image."
       (setq n (min n (1- (car (plist-get (cdr image)
                                          :animate-multi-frame-data)))))))
   (plist-put (cdr image) :index n)
-  (when-let ((window
-              (get-buffer-window (plist-get (cdr image) :animate-buffer) t)))
-    (force-window-update window)))
+  (force-window-update (plist-get (cdr image) :animate-buffer)))
 
 (defun image-animate-get-speed (image)
   "Return the speed factor for animating IMAGE."