+2010-05-25 Juri Linkov <juri@jurta.org>
+
+ * image-mode.el (image-mode): Add image-after-revert-hook to
+ after-revert-hook.
+ (image-after-revert-hook): New function. (Bug#5669)
+
2010-05-25 Juri Linkov <juri@jurta.org>
* image.el (image-animated-p): When delay between animated images
(image-mode-setup-winprops)
(add-hook 'change-major-mode-hook 'image-toggle-display-text nil t)
+ (add-hook 'after-revert-hook 'image-after-revert-hook nil t)
(run-mode-hooks 'image-mode-hook)
(message "%s" (concat
(substitute-command-keys
(if (image-get-display-property)
(image-mode-as-text)
(image-mode)))
+
+(defun image-after-revert-hook ()
+ (when (image-get-display-property)
+ (image-toggle-display-text)
+ ;; Update image display.
+ (redraw-frame (selected-frame))
+ (image-toggle-display-image)))
+
\f
;;; Support for bookmark.el
(declare-function bookmark-make-record-default "bookmark"