Commit 69e73dd3 authored by Richard M. Stallman's avatar Richard M. Stallman
Browse files

(help-mode-finish): Set help-return-alist first

thing, setting only the entry for the selected window.
parent 19a151e5
...@@ -195,14 +195,17 @@ Commands: ...@@ -195,14 +195,17 @@ Commands:
;;;###autoload ;;;###autoload
(defun help-mode-finish () (defun help-mode-finish ()
(let ((entry (assq (selected-window) view-return-to-alist)))
(if entry (setcdr entry (cons (selected-window)
help-return-method))
(setq view-return-to-alist
(cons (cons (selected-window) help-return-method)
view-return-to-alist))))
(when (eq major-mode 'help-mode) (when (eq major-mode 'help-mode)
;; View mode's read-only status of existing *Help* buffer is lost ;; View mode's read-only status of existing *Help* buffer is lost
;; by with-output-to-temp-buffer. ;; by with-output-to-temp-buffer.
(toggle-read-only 1) (toggle-read-only 1)
(help-make-xrefs (current-buffer))) (help-make-xrefs (current-buffer))))
(setq view-return-to-alist
(list (cons (selected-window) help-return-method))))
;; Grokking cross-reference information in doc strings and ;; Grokking cross-reference information in doc strings and
;; hyperlinking it. ;; hyperlinking it.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment