summaryrefslogtreecommitdiff
path: root/lisp/image-mode.el
diff options
context:
space:
mode:
authorGlenn Morris <rgm@gnu.org>2013-02-16 11:56:50 -0800
committerGlenn Morris <rgm@gnu.org>2013-02-16 11:56:50 -0800
commited8d7fcaa2965216d44388fd00a757c8d55e7395 (patch)
tree8e04c2457944d8e829c1eacd5eadcf68d0ad0ba6 /lisp/image-mode.el
parent783b7b7551b197fdcfd384ac4a3d93302a073eaf (diff)
downloademacs-ed8d7fcaa2965216d44388fd00a757c8d55e7395.tar.gz
Generalize "animated" images to "multi-frame" images
* lisp/image.el (image-animated-types): Remove. (image-multi-frame-p): Rename from image-animated-p, and generalize. (image-animated-p): Make obsolete alias. (image-animate, image-nth-frame, image-animate-timeout): Use image-multi-frame-p. (image-animate-timeout): If no delay, use image-default-frame-delay. * lisp/image-mode.el (image-mode, image-toggle-animation): Use image-multi-frame-p. (image-mode): Adjust startup message for a multi-frame image. * lisp/gnus/shr.el (shr-put-image): Only animate images that specify a delay. This is consistent with the old image-animated-p behavior. * etc/NEWS: Add placeholder for this. Fixes: debbugs:10739
Diffstat (limited to 'lisp/image-mode.el')
-rw-r--r--lisp/image-mode.el10
1 files changed, 5 insertions, 5 deletions
diff --git a/lisp/image-mode.el b/lisp/image-mode.el
index b6298adeb7e..52367811341 100644
--- a/lisp/image-mode.el
+++ b/lisp/image-mode.el
@@ -464,7 +464,7 @@ to toggle between display as an image and display as text."
(cond
((null image)
(message "%s" (concat msg1 "an image.")))
- ((setq animated (image-animated-p image))
+ ((setq animated (image-multi-frame-p image))
(setq image-current-frame (or (plist-get (cdr image) :index) 0)
mode-line-process
`(:eval (propertize (format " [%s/%s]"
@@ -472,9 +472,9 @@ to toggle between display as an image and display as text."
,(car animated))
'help-echo "Frame number")))
(message "%s"
- (concat msg1 "text, or "
- (substitute-command-keys
- "\\[image-toggle-animation] to animate."))))
+ (concat msg1 "text. This image has multiple frames.")))
+;;; (substitute-command-keys
+;;; "\\[image-toggle-animation] to animate."))))
(t
(message "%s" (concat msg1 "text."))))))
@@ -663,7 +663,7 @@ Otherwise it plays once, then stops."
(cond
((null image)
(error "No image is present"))
- ((null (setq animation (image-animated-p image)))
+ ((null (setq animation (image-multi-frame-p image)))
(message "No image animation."))
(t
(let ((timer (image-animate-timer image)))