Mercurial > emacs
changeset 41712:c2b7b74ef973
(hide-ifdef-mode): Only modify
`change-major-mode-hook' locally. Reset invisibility spec.
author | Stefan Monnier <monnier@iro.umontreal.ca> |
---|---|
date | Fri, 30 Nov 2001 23:58:24 +0000 |
parents | efb6bac9ee70 |
children | d53ece895385 |
files | lisp/progmodes/hideif.el |
diffstat | 1 files changed, 3 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/progmodes/hideif.el Fri Nov 30 23:54:45 2001 +0000 +++ b/lisp/progmodes/hideif.el Fri Nov 30 23:58:24 2001 +0000 @@ -207,7 +207,8 @@ (default-value 'hide-ifdef-hiding)) (set (make-local-variable 'hif-outside-read-only) buffer-read-only) (set (make-local-variable 'line-move-ignore-invisible) t) - (add-hook 'change-major-mode-hook (lambda () (hide-ifdef-mode -1))) + (add-hook 'change-major-mode-hook + (lambda () (hide-ifdef-mode -1)) nil t) (add-to-invisibility-spec '(hide-ifdef . t)) @@ -216,6 +217,7 @@ (show-ifdefs))) ;; else end hide-ifdef-mode (kill-local-variable 'line-move-ignore-invisible) + (remove-from-invisibility-spec '(hide-ifdef . t)) (if hide-ifdef-hiding (show-ifdefs))))