comparison lisp/pcvs-util.el @ 36614:dfaaee4447ff

(cvs-bury-buffer): In doubt, don't delete window.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Wed, 07 Mar 2001 00:19:08 +0000
parents f67876180a63
children 6098465deff0
comparison
equal deleted inserted replaced
36613:6fd7e79e9d1f 36614:dfaaee4447ff
3 ;; Copyright (C) 1991,92,93,94,95,96,97,98,99,2000, 2001 3 ;; Copyright (C) 1991,92,93,94,95,96,97,98,99,2000, 2001
4 ;; Free Software Foundation, Inc. 4 ;; Free Software Foundation, Inc.
5 5
6 ;; Author: Stefan Monnier <monnier@cs.yale.edu> 6 ;; Author: Stefan Monnier <monnier@cs.yale.edu>
7 ;; Keywords: pcl-cvs 7 ;; Keywords: pcl-cvs
8 ;; Revision: $Id: pcvs-util.el,v 1.8 2000/12/18 03:17:31 monnier Exp $ 8 ;; Revision: $Id: pcvs-util.el,v 1.9 2001/01/09 13:12:04 gerd Exp $
9 9
10 ;; This file is part of GNU Emacs. 10 ;; This file is part of GNU Emacs.
11 11
12 ;; GNU Emacs is free software; you can redistribute it and/or modify 12 ;; GNU Emacs is free software; you can redistribute it and/or modify
13 ;; it under the terms of the GNU General Public License as published by 13 ;; it under the terms of the GNU General Public License as published by
121 (if (window-dedicated-p win) 121 (if (window-dedicated-p win)
122 (condition-case () 122 (condition-case ()
123 (delete-window win) 123 (delete-window win)
124 (error (iconify-frame (window-frame win)))) 124 (error (iconify-frame (window-frame win))))
125 (if (and mainbuf (get-buffer-window mainbuf)) 125 (if (and mainbuf (get-buffer-window mainbuf))
126 (delete-window win))))) 126 ;; FIXME: if the buffer popped into a pre-existing window,
127 ;; we don't want to delete that window.
128 ;;(delete-window win)
129 ))))
127 (with-current-buffer buf 130 (with-current-buffer buf
128 (bury-buffer (unless (and (eq buf (window-buffer (selected-window))) 131 (bury-buffer (unless (and (eq buf (window-buffer (selected-window)))
129 (not (window-dedicated-p (selected-window)))) 132 (not (window-dedicated-p (selected-window))))
130 buf))) 133 buf)))
131 (when mainbuf 134 (when mainbuf