mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-12-28 10:56:36 +00:00
* image-mode.el (image-mode): Add image-after-revert-hook to after-revert-hook.
(image-after-revert-hook): New function. (Bug#5669)
This commit is contained in:
parent
fc93792445
commit
0fb1193d6c
@ -1,3 +1,9 @@
|
||||
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
|
||||
|
@ -357,6 +357,7 @@ to toggle between display as an image and display as text."
|
||||
(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
|
||||
@ -503,6 +504,14 @@ the image file and `image-mode' showing the image as an image."
|
||||
(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)))
|
||||
|
||||
|
||||
;;; Support for bookmark.el
|
||||
(declare-function bookmark-make-record-default "bookmark"
|
||||
|
Loading…
Reference in New Issue
Block a user