From: Richard M. Stallman Date: Thu, 19 May 1994 21:50:30 +0000 (+0000) Subject: (compilation-goto-locus): Handle case where *compilation* X-Git-Tag: emacs-19.34~8286 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=e89a7d771b61197e1d0a1fb70a940218fb7652d9;p=emacs.git (compilation-goto-locus): Handle case where *compilation* is in a dedicated window. --- diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index ca34beeb670..e9fc213c98b 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el @@ -955,7 +955,10 @@ The current buffer should be the desired compilation output buffer." "Jump to an error locus returned by `compilation-next-error-locus'. Takes one argument, a cons (ERROR . SOURCE) of two markers. Selects a window with point at SOURCE, with another window displaying ERROR." - (switch-to-buffer (marker-buffer (cdr next-error))) + (if (and (window-dedicated-p (selected-window)) + (eq (selected-window) (frame-root-window))) + (switch-to-buffer-other-frame (marker-buffer (cdr next-error))) + (switch-to-buffer (marker-buffer (cdr next-error)))) (goto-char (cdr next-error)) ;; If narrowing got in the way of ;; going to the right place, widen.