]> git.eshelyaron.com Git - emacs.git/commitdiff
(define-minor-mode): Use customize-mark-as-set for global minor modes.
authorStefan Monnier <monnier@iro.umontreal.ca>
Mon, 26 Aug 2002 16:40:49 +0000 (16:40 +0000)
committerStefan Monnier <monnier@iro.umontreal.ca>
Mon, 26 Aug 2002 16:40:49 +0000 (16:40 +0000)
lisp/emacs-lisp/easy-mmode.el

index 50b0f76c3385e6e49b4374b788d9a4b83a064819..8f89d92a057a7799e7eceb653de6bb8c006a01c8 100644 (file)
@@ -190,11 +190,13 @@ With zero or negative ARG turn mode off.
         ,@body
         ;; The on/off hooks are here for backward compatibility only.
         (run-hooks ',hook (if ,mode ',hook-on ',hook-off))
-        ;; Return the new setting.
         (if (interactive-p)
-            (message ,(format "%s %%sabled" pretty-name)
-                     (if ,mode "en" "dis")))
+            (progn
+              ,(if globalp `(customize-mark-as-set ',mode))
+              (message ,(format "%s %%sabled" pretty-name)
+                       (if ,mode "en" "dis"))))
         (force-mode-line-update)
+        ;; Return the new setting.
         ,mode)
 
        ;; Autoloading an easy-mmode-define-minor-mode autoloads