changeset 50635:e0775ee7f599

(define-minor-mode): Only echo a message if the body didn't do so already. (easy-mmode-define-keymap): Remove unused var `suppress'.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Fri, 18 Apr 2003 17:31:05 +0000
parents 31489b0b9b0d
children 0af2d4122c02
files lisp/emacs-lisp/easy-mmode.el
diffstat 1 files changed, 3 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/emacs-lisp/easy-mmode.el	Fri Apr 18 13:53:18 2003 +0000
+++ b/lisp/emacs-lisp/easy-mmode.el	Fri Apr 18 17:31:05 2003 +0000
@@ -203,12 +203,12 @@
 	 (if (interactive-p)
 	     (progn
 	       ,(if globalp `(customize-mark-as-set ',mode))
+	       (unless (current-message)
 	       (message ,(format "%s %%sabled" pretty-name)
-			(if ,mode "en" "dis"))))
+			  (if ,mode "en" "dis")))))
 	 (force-mode-line-update)
 	 ;; Return the new setting.
 	 ,mode)
-
        ;; Autoloading an easy-mmode-define-minor-mode autoloads
        ;; everything up-to-here.
        :autoload-end
@@ -341,7 +341,7 @@
 Optional NAME is passed to `make-sparse-keymap'.
 Optional map M can be used to modify an existing map.
 ARGS is a list of additional keyword arguments."
-  (let (inherit dense suppress)
+  (let (inherit dense)
     (while args
       (let ((key (pop args))
 	    (val (pop args)))
@@ -350,7 +350,6 @@
 	 (:dense (setq dense val))
 	 (:inherit (setq inherit val))
 	 (:group)
-	 ;;((eq key :suppress) (setq suppress val))
 	 (t (message "Unknown argument %s in defmap" key)))))
     (unless (keymapp m)
       (setq bs (append m bs))