# HG changeset patch # User Richard M. Stallman # Date 953481400 0 # Node ID 1ea4cf59226413392e4c2cd46eed5bf858550f7c # Parent aaa6448240ebd8621bd68c6393c8f04f6d0288a1 (view-mode-disable): Kill local binding of view-read-only. diff -r aaa6448240eb -r 1ea4cf592264 lisp/view.el --- a/lisp/view.el Sun Mar 19 15:56:23 2000 +0000 +++ b/lisp/view.el Sun Mar 19 15:56:40 2000 +0000 @@ -458,6 +458,14 @@ (remove-hook 'change-major-mode-hook 'view-mode-disable t) (and view-overlay (delete-overlay view-overlay)) (force-mode-line-update) + ;; Calling toggle-read-only while View mode is enabled + ;; sets view-read-only to t as a buffer-local variable + ;; after exiting View mode. That arranges that the next toggle-read-only + ;; will reenable View mode. + ;; Cancelling View mode in any other way should cancel that, too, + ;; so that View mode stays off if toggle-read-only is called. + (if (local-variable-p 'view-read-only) + (kill-local-variable 'view-read-only)) (setq view-mode nil Helper-return-blurb view-old-Helper-return-blurb) (if buffer-read-only