diff options
| author | Richard M. Stallman | 2001-12-21 14:12:30 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 2001-12-21 14:12:30 +0000 |
| commit | d743da264342d075295a477c9e49dd185ee654a4 (patch) | |
| tree | 000dd820c3cb77d55aae0b6cf16c058f1de16ed0 | |
| parent | 726e8778c81119ae3ba25b6b22b77c47299f2bc3 (diff) | |
| download | emacs-d743da264342d075295a477c9e49dd185ee654a4.tar.gz emacs-d743da264342d075295a477c9e49dd185ee654a4.zip | |
(define-minor-mode): Make no arg by default in an interactive call,
so that repeating the command toggles again.
| -rw-r--r-- | lisp/ChangeLog | 21 | ||||
| -rw-r--r-- | lisp/emacs-lisp/easy-mmode.el | 6 |
2 files changed, 19 insertions, 8 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 4d4a74545a8..7fd55a56901 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,16 +1,25 @@ | |||
| 1 | 2001-12-21 Richard M. Stallman <rms@gnu.org> | ||
| 2 | |||
| 3 | * emacs-lisp/easy-mmode.el (define-minor-mode): | ||
| 4 | Make no arg by default in an interactive call, | ||
| 5 | so that repeating the command toggles again. | ||
| 6 | |||
| 7 | * emacs-lisp/lisp-mode.el (eval-defun-1): Cope with atoms as args. | ||
| 8 | |||
| 1 | 2001-12-21 Eli Zaretskii <eliz@is.elta.co.il> | 9 | 2001-12-21 Eli Zaretskii <eliz@is.elta.co.il> |
| 2 | 10 | ||
| 3 | * jka-compr.el (jka-compr-partial-uncompress): Use null-device | 11 | * jka-compr.el (jka-compr-partial-uncompress): Use null-device |
| 4 | instead of a literal /dev/null. Reported by Jens Schmidt | 12 | instead of a literal /dev/null. |
| 5 | <schmidt@mathematik.uni-kl.de>. | 13 | |
| 14 | * Makefile.in (distclean): Remove Makefile in the build | ||
| 15 | directory, not in the source directory. | ||
| 16 | |||
| 17 | 2001-12-21 Simon Josefsson <jas@extundo.com>. | ||
| 6 | 18 | ||
| 7 | * mail/smtpmail.el (smtpmail-send-queued-mail): Use | 19 | * mail/smtpmail.el (smtpmail-send-queued-mail): Use |
| 8 | with-temp-buffer instead of find-file-noselect, and bind | 20 | with-temp-buffer instead of find-file-noselect, and bind |
| 9 | coding-system-for-read to no-conversion when reading the queued | 21 | coding-system-for-read to no-conversion when reading the queued |
| 10 | messages. From Simon Josefsson <jas@extundo.com>. | 22 | messages. |
| 11 | |||
| 12 | * Makefile.in (distclean): Remove Makefile in the build | ||
| 13 | directory, not in the source directory. | ||
| 14 | 23 | ||
| 15 | 2001-12-20 Werner Lemberg <wl@gnu.org> | 24 | 2001-12-20 Werner Lemberg <wl@gnu.org> |
| 16 | 25 | ||
diff --git a/lisp/emacs-lisp/easy-mmode.el b/lisp/emacs-lisp/easy-mmode.el index 0030600028d..0757115ee40 100644 --- a/lisp/emacs-lisp/easy-mmode.el +++ b/lisp/emacs-lisp/easy-mmode.el | |||
| @@ -107,7 +107,7 @@ BODY contains code that will be executed each time the mode is (dis)activated. | |||
| 107 | (let* ((mode-name (symbol-name mode)) | 107 | (let* ((mode-name (symbol-name mode)) |
| 108 | (pretty-name (easy-mmode-pretty-mode-name mode lighter)) | 108 | (pretty-name (easy-mmode-pretty-mode-name mode lighter)) |
| 109 | (globalp nil) | 109 | (globalp nil) |
| 110 | (togglep t) ;why would you ever want to toggle? | 110 | (togglep t) ;; This should never be nil -- rms. |
| 111 | (group nil) | 111 | (group nil) |
| 112 | (extra-args nil) | 112 | (extra-args nil) |
| 113 | (keymap-sym (if (and keymap (symbolp keymap)) keymap | 113 | (keymap-sym (if (and keymap (symbolp keymap)) keymap |
| @@ -175,7 +175,9 @@ Interactively, with no prefix argument, toggle the mode. | |||
| 175 | With universal prefix ARG " (unless togglep "(or if ARG is nil) ") "turn mode on. | 175 | With universal prefix ARG " (unless togglep "(or if ARG is nil) ") "turn mode on. |
| 176 | With zero or negative ARG turn mode off. | 176 | With zero or negative ARG turn mode off. |
| 177 | \\{%s}") pretty-name keymap-sym)) | 177 | \\{%s}") pretty-name keymap-sym)) |
| 178 | (interactive (list (or current-prefix-arg (if ,mode 0 1)))) | 178 | ;; Make no arg by default in an interactive call, |
| 179 | ;; so that repeating the command toggles again. | ||
| 180 | (interactive) | ||
| 179 | (setq ,mode | 181 | (setq ,mode |
| 180 | (if arg | 182 | (if arg |
| 181 | (> (prefix-numeric-value arg) 0) | 183 | (> (prefix-numeric-value arg) 0) |