GNU bug report logs -
#12764
24.2; `quit-window' wrongly iconifies frame
Previous Next
Full log
Message #8 received at 12764 <at> debbugs.gnu.org (full text, mbox):
Romain Francoise <romain <at> orebokech.com> writes:
> There's a regression in Emacs 24 compared to Emacs 23 wrt the behavior
> of `quit-window'. In some circumstances, it iconifies frames that were
> existing before the current buffer was created, which (AIUI) it's not
> supposed to do.
>
> Recipe starting from `emacs -Q':
> - C-x 5 2 to create a new frame
> - in the new frame, M-x man RET emacs RET
> - C-x 0 to make the man buffer the current buffer
> - q
>
> When you hit `q' the frame gets iconified, even though it was not
> created by M-x man.
I think the attached patch is required to fix this. Martin, please
review, thanks.
=== modified file 'lisp/window.el'
*** lisp/window.el 2012-10-27 08:58:30 +0000
--- lisp/window.el 2012-10-30 03:23:59 +0000
***************
*** 3556,3562 ****
quad entry)
(cond
((and (not prev-buffer)
! (memq (nth 1 quit-restore) '(window frame))
(eq (nth 3 quit-restore) buffer)
;; Delete WINDOW if possible.
(window--delete window nil (eq bury-or-kill 'kill)))
--- 3556,3566 ----
quad entry)
(cond
((and (not prev-buffer)
! (or (eq (nth 1 quit-restore) 'frame)
! ;; If the window had been created on an existing frame,
! ;; do not try to delete the frame.
! (and (eq (nth 1 quit-restore) 'window)
! (not (eq (window-deletable-p window) 'frame))))
(eq (nth 3 quit-restore) buffer)
;; Delete WINDOW if possible.
(window--delete window nil (eq bury-or-kill 'kill)))
This bug report was last modified 12 years and 203 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.