(define-minor-mode): Use customize-mark-as-set for global minor modes.
This commit is contained in:
parent
098ba98322
commit
d99d3266b0
1 changed files with 5 additions and 3 deletions
|
@ -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
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue