diff options
| author | Alex Schroeder | 2003-09-10 19:51:01 +0000 |
|---|---|---|
| committer | Alex Schroeder | 2003-09-10 19:51:01 +0000 |
| commit | dce78214fe44143bb60d63f49928cfc05af24fe0 (patch) | |
| tree | a67b1ebbe3efd46cd6b83582d5c8031679dc3150 | |
| parent | d5d78bd53e5bc03744fb55c62ba5330c498c5973 (diff) | |
| download | emacs-dce78214fe44143bb60d63f49928cfc05af24fe0.tar.gz emacs-dce78214fe44143bb60d63f49928cfc05af24fe0.zip | |
2003-09-10 Mario Lang <mlang@delysid.org>
Update Commentary and Copyright.
(battery-linux-proc-acpi): Fix a bug in %b which made "!" never
appear due to wrong ordering of the expressions in `or'.
| -rw-r--r-- | lisp/battery.el | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lisp/battery.el b/lisp/battery.el index 068f1ab50d5..c82d3ac02b3 100644 --- a/lisp/battery.el +++ b/lisp/battery.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; battery.el --- display battery status information | 1 | ;;; battery.el --- display battery status information |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1997, 1998, 2000, 2001 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 1997, 1998, 2000, 2001, 2003 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Ralph Schleicher <rs@nunatak.allgaeu.org> | 5 | ;; Author: Ralph Schleicher <rs@nunatak.allgaeu.org> |
| 6 | ;; Keywords: hardware | 6 | ;; Keywords: hardware |
| @@ -24,9 +24,9 @@ | |||
| 24 | 24 | ||
| 25 | ;;; Commentary: | 25 | ;;; Commentary: |
| 26 | 26 | ||
| 27 | ;; There is at present only a function interpreting the new `/proc/apm' | 27 | ;; There is at present support for interpreting the new `/proc/apm' |
| 28 | ;; file format of Linux version 1.3.58 or newer. That is, what a lucky | 28 | ;; file format of Linux version 1.3.58 or newer and for the `/proc/acpi/' |
| 29 | ;; coincidence, exactly the interface provided by the author's laptop. | 29 | ;; directory structure of Linux 2.4.20 and 2.6. |
| 30 | 30 | ||
| 31 | ;;; Code: | 31 | ;;; Code: |
| 32 | 32 | ||
| @@ -308,8 +308,8 @@ The following %-sequences are provided: | |||
| 308 | (cons ?r (or (and rate (number-to-string rate)) "N/A")) | 308 | (cons ?r (or (and rate (number-to-string rate)) "N/A")) |
| 309 | (cons ?B (or charging-state "N/A")) | 309 | (cons ?B (or charging-state "N/A")) |
| 310 | (cons ?b (or (and (string= charging-state "charging") "+") | 310 | (cons ?b (or (and (string= charging-state "charging") "+") |
| 311 | (and warn (< capacity warn) "-") | ||
| 312 | (and low (< capacity low) "!") | 311 | (and low (< capacity low) "!") |
| 312 | (and warn (< capacity warn) "-") | ||
| 313 | "")) | 313 | "")) |
| 314 | (cons ?h (or (and hours (number-to-string hours)) "N/A")) | 314 | (cons ?h (or (and hours (number-to-string hours)) "N/A")) |
| 315 | (cons ?m (or (and minutes (number-to-string minutes)) "N/A")) | 315 | (cons ?m (or (and minutes (number-to-string minutes)) "N/A")) |