# HG changeset patch # User Luc Teirlinck # Date 1080349695 0 # Node ID adcc0a8ef9055a2b79460911d5ae4469530f9364 # Parent 70182fa217a2d88810b93adaeac7ca0c5b82a660 (buffer-stale-function): Moved here from autorevert.el. diff -r 70182fa217a2 -r adcc0a8ef905 lisp/files.el --- a/lisp/files.el Sat Mar 27 00:08:57 2004 +0000 +++ b/lisp/files.el Sat Mar 27 01:08:15 2004 +0000 @@ -3454,6 +3454,19 @@ The function you specify is responsible for updating (or preserving) point.") +(defvar buffer-stale-function nil + "Function to check whether a non-file buffer needs reverting. +This should be a function with one optional argument NOCONFIRM. +Auto Revert Mode sets NOCONFIRM to t. The function should return +non-nil if the buffer should be reverted. The buffer is current +when this function is called. + +The idea behind the NOCONFIRM argument is that the same function +can also be used to ask the user whether the buffer should be +reverted. In such a situation one has to be less careful about, +say, reverting remote files, than if the function is called at +regular intervals by Auto Revert Mode.") + (defvar before-revert-hook nil "Normal hook for `revert-buffer' to run before reverting. If `revert-buffer-function' is used to override the normal revert