mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-02-16 17:24:23 +00:00
(display-battery): Use `add-to-list'.
This commit is contained in:
parent
c8bfa68964
commit
862a7e281e
2 changed files with 7 additions and 4 deletions
|
|
@ -1,3 +1,8 @@
|
|||
2000-10-10 Miles Bader <miles@lsi.nec.co.jp>
|
||||
|
||||
* subr.el (add-to-list): Add optional argument APPEND.
|
||||
* battery.el (display-battery): Use `add-to-list'.
|
||||
|
||||
2000-10-09 Thien-Thi Nguyen <ttn@gnu.org>
|
||||
|
||||
* play/zone.el (zone-timer, zone-wc-tbl): Rework
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
;;; battery.el --- display battery status information.
|
||||
|
||||
;; Copyright (C) 1997, 1998 Free Software Foundation, Inc.
|
||||
;; Copyright (C) 1997, 1998, 2000 Free Software Foundation, Inc.
|
||||
|
||||
;; Author: Ralph Schleicher <rs@nunatak.allgaeu.org>
|
||||
;; Keywords: hardware
|
||||
|
|
@ -108,9 +108,7 @@ seconds."
|
|||
(interactive)
|
||||
(setq battery-mode-line-string "")
|
||||
(or global-mode-string (setq global-mode-string '("")))
|
||||
(or (memq 'battery-mode-line-string global-mode-string)
|
||||
(setq global-mode-string (append global-mode-string
|
||||
'(battery-mode-line-string))))
|
||||
(add-to-list 'global-mode-string 'battery-mode-line-string t)
|
||||
(and battery-update-timer (cancel-timer battery-update-timer))
|
||||
(setq battery-update-timer (run-at-time nil battery-update-interval
|
||||
'battery-update-handler))
|
||||
|
|
|
|||
Loading…
Reference in a new issue