From: Dmitry Gutov Date: Mon, 10 Jun 2019 00:10:34 +0000 (+0300) Subject: Unbreak saving xref--original-window, etc X-Git-Tag: emacs-27.0.90~2634 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=5f5555da87fdd767b4ece9ac4b63ebd25985487d;p=emacs.git Unbreak saving xref--original-window, etc * lisp/progmodes/xref.el (xref--show-xref-buffer) (xref--show-defs-buffer-at-bottom): Move major mode calls earlier. So that local variable values are not lost. --- diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el index 24e2bd04e76..e88f30ca358 100644 --- a/lisp/progmodes/xref.el +++ b/lisp/progmodes/xref.el @@ -798,8 +798,8 @@ Return an alist of the form ((FILENAME . (XREF ...)) ...)." (funcall fetcher))) (xref-alist (xref--analyze xrefs))) (with-current-buffer (get-buffer-create xref-buffer-name) - (xref--show-common-initialize xref-alist fetcher alist) (xref--xref-buffer-mode) + (xref--show-common-initialize xref-alist fetcher alist) (pop-to-buffer (current-buffer)) (current-buffer)))) @@ -854,8 +854,8 @@ local keymap that binds `RET' to `xref-quit-and-goto-xref'." (assoc-default 'display-action alist))) (t (with-current-buffer (get-buffer-create xref-buffer-name) - (xref--show-common-initialize (xref--analyze xrefs) fetcher alist) (xref--transient-buffer-mode) + (xref--show-common-initialize (xref--analyze xrefs) fetcher alist) (pop-to-buffer (current-buffer) '(display-buffer-in-direction . ((direction . below)))) (current-buffer))))))