Mercurial > emacs
comparison lisp/image.el @ 108778:6c819187f088
* image.el (image-animated-p): When delay between animated images is 0,
set it to 10 (0.1 sec). (Bug#6258)
author | Juri Linkov <juri@jurta.org> |
---|---|
date | Tue, 25 May 2010 18:54:53 +0300 |
parents | 24d486687f54 |
children | 5883fc00b976 68616bb3ae25 |
comparison
equal
deleted
inserted
replaced
108777:04bc013ba171 | 108778:6c819187f088 |
---|---|
683 (cond | 683 (cond |
684 ((eq (plist-get (cdr image) :type) 'gif) | 684 ((eq (plist-get (cdr image) :type) 'gif) |
685 (let* ((metadata (image-metadata image)) | 685 (let* ((metadata (image-metadata image)) |
686 (images (plist-get metadata 'count)) | 686 (images (plist-get metadata 'count)) |
687 (extdata (plist-get metadata 'extension-data)) | 687 (extdata (plist-get metadata 'extension-data)) |
688 (anim (plist-get extdata #xF9))) | 688 (anim (plist-get extdata #xF9)) |
689 (and (integerp images) (> images 1) | 689 (tmo (and (integerp images) (> images 1) |
690 (stringp anim) (>= (length anim) 4) | 690 (stringp anim) (>= (length anim) 4) |
691 (cons images (+ (aref anim 1) (* (aref anim 2) 256)))))))) | 691 (+ (aref anim 1) (* (aref anim 2) 256))))) |
692 (when tmo | |
693 (if (eq tmo 0) (setq tmo 10)) | |
694 (cons images tmo)))))) | |
692 | 695 |
693 | 696 |
694 (provide 'image) | 697 (provide 'image) |
695 | 698 |
696 ;; arch-tag: 8e76a07b-eb48-4f3e-a7a0-1a7ba9f096b3 | 699 ;; arch-tag: 8e76a07b-eb48-4f3e-a7a0-1a7ba9f096b3 |