Mercurial > emacs
changeset 76697:596838644e8e
(find-file-hook, auto-revert-tail-mode):
Use file size in bytes for auto-revert-tail-pos not characters.
author | Jason Rumney <jasonr@gnu.org> |
---|---|
date | Sat, 24 Mar 2007 13:39:21 +0000 |
parents | a1bfaeef534b |
children | d9947515661b |
files | lisp/autorevert.el |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/autorevert.el Sat Mar 24 13:38:43 2007 +0000 +++ b/lisp/autorevert.el Sat Mar 24 13:39:21 2007 +0000 @@ -278,7 +278,7 @@ (add-hook 'find-file-hook (lambda () (set (make-local-variable 'auto-revert-tail-pos) - (save-restriction (widen) (1- (point-max)))))) + (nth 7 (file-attributes buffer-file-name))))) ;; Functions: @@ -341,7 +341,7 @@ (add-hook 'before-save-hook (lambda () (auto-revert-tail-mode 0)) nil t) (or (local-variable-p 'auto-revert-tail-pos) ; don't lose prior position (set (make-local-variable 'auto-revert-tail-pos) - (save-restriction (widen) (1- (point-max))))) + (nth 7 (file-attributes buffer-file-name)))) ;; let auto-revert-mode set up the mechanism for us if it isn't already (or auto-revert-mode (let ((auto-revert-tail-mode t))