changeset 23728:0d1a0ded9aa1

(temp_output_buffer_show): Around temp-buffer-show-hook, don't do save-excursion, just restore selected window. (window_loop): For UNSHOW_BUFFER, always do consider minibuffer windows.
author Richard M. Stallman <rms@gnu.org>
date Tue, 17 Nov 1998 16:27:02 +0000
parents 682a37afcb98
children cf1cbb0e5d5b
files src/window.c
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/window.c	Tue Nov 17 06:30:52 1998 +0000
+++ b/src/window.c	Tue Nov 17 16:27:02 1998 +0000
@@ -1375,6 +1375,8 @@
 	 the frame is visible, since Fnext_window skips non-visible frames
 	 if that is desired, under the control of frame_arg.  */
       if (! MINI_WINDOW_P (XWINDOW (w))
+	  /* For UNSHOW_BUFFER, we must always consider all windows.  */
+	  || type == UNSHOW_BUFFER
 	  || (mini && minibuf_level > 0))
 	switch (type)
 	  {
@@ -2394,9 +2396,7 @@
 		  prev_window = selected_window;
 
 		  /* Select the window that was chosen, for running the hook.  */
-		  record_unwind_protect (Fset_window_configuration,
-					 Fcurrent_window_configuration (Qnil));
-
+		  record_unwind_protect (Fselect_window, prev_window);
 		  select_window_1 (window, 0);
 		  Fset_buffer (w->buffer);
 		  call1 (Vrun_hooks, Qtemp_buffer_show_hook);