(display-time-sentinel, display-time-filter): Use force-mode-line-update.
authorKarl Heuer <kwzh@gnu.org>
Tue, 25 Apr 1995 22:24:40 +0000 (22:24 +0000)
committerKarl Heuer <kwzh@gnu.org>
Tue, 25 Apr 1995 22:24:40 +0000 (22:24 +0000)
lisp/time.el

index 95c761f..f99cb3c 100644 (file)
@@ -88,8 +88,7 @@ After each update, `display-time-hook' is run with `run-hooks'."
   (or (eq (process-status proc) 'run)
       (setq display-time-string ""))
   ;; Force mode-line updates
-  (save-excursion (set-buffer (other-buffer)))
-  (set-buffer-modified-p (buffer-modified-p))
+  (force-mode-line-update t)
   (sit-for 0))
 
 (defvar display-time-string-forms
@@ -165,9 +164,7 @@ would give mode line times like `94/12/30 21:07:48 (UTC)'.")
     (setq display-time-string
           (mapconcat 'eval display-time-string-forms "")))
   (run-hooks 'display-time-hook)
-  ;; Force redisplay of all buffers' mode lines to be considered.
-  (save-excursion (set-buffer (other-buffer)))
-  (set-buffer-modified-p (buffer-modified-p))
+  (force-mode-line-update)
   ;; Do redisplay right now, if no input pending.
   (sit-for 0))