From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Thierry Volpiatto Newsgroups: gmane.emacs.devel Subject: Re: quit-window new behavior with frames Date: Thu, 22 Sep 2011 10:35:39 +0200 Message-ID: <87r5392cv8.fsf@gmail.com> References: <87litzbkyx.fsf@gmail.com> <4E68E4AD.3060205@gmx.at> <874o053ybm.fsf@gmail.com> <4E7ADC88.60606@gmx.at> <87vcsl2fje.fsf@gmail.com> <4E7AEC5B.9020801@gmx.at> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1316680554 10050 80.91.229.12 (22 Sep 2011 08:35:54 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 22 Sep 2011 08:35:54 +0000 (UTC) Cc: emacs-devel@gnu.org To: martin rudalics Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Sep 22 10:35:50 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1R6el3-0001Lt-T7 for ged-emacs-devel@m.gmane.org; Thu, 22 Sep 2011 10:35:50 +0200 Original-Received: from localhost ([::1]:47191 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R6el3-00011o-Bs for ged-emacs-devel@m.gmane.org; Thu, 22 Sep 2011 04:35:49 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:59708) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R6el0-00011j-W0 for emacs-devel@gnu.org; Thu, 22 Sep 2011 04:35:47 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1R6ekz-0004G8-M8 for emacs-devel@gnu.org; Thu, 22 Sep 2011 04:35:46 -0400 Original-Received: from mail-ey0-f169.google.com ([209.85.215.169]:39951) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R6ekz-0004G2-G2 for emacs-devel@gnu.org; Thu, 22 Sep 2011 04:35:45 -0400 Original-Received: by eye13 with SMTP id 13so1649879eye.0 for ; Thu, 22 Sep 2011 01:35:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type; bh=vxiurd+qM0Lopx8t+m152fa5cYmrvDFnBEVqLGkVJ1w=; b=lbOs2JF6UvSLCRkdM6cVfw3KuT0D3BKUPnhiGW5KG4jnYKOZpv1n79NA1y7vBnCiiW 5ei9OcdYzeO/635gqYNVy2sqYBWT9NsZSlZBsIWqb24hzb/mcNtPnaVDGvfD377FJ6dH dhc2wfMYwKvgHA8MYWM/pkUixoxfK7cl0CKMA= Original-Received: by 10.14.18.138 with SMTP id l10mr688238eel.31.1316680544577; Thu, 22 Sep 2011 01:35:44 -0700 (PDT) Original-Received: from thierry-MM061 (96.211.85.79.rev.sfr.net. [79.85.211.96]) by mx.google.com with ESMTPS id d59sm22591193eea.3.2011.09.22.01.35.42 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 22 Sep 2011 01:35:43 -0700 (PDT) In-Reply-To: <4E7AEC5B.9020801@gmx.at> (martin rudalics's message of "Thu, 22 Sep 2011 10:05:47 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 209.85.215.169 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:144178 Archived-At: martin rudalics writes: >> It now quit the help buffer, but don't delete the frame. > > Please debug `quit-window' and tell me why the conjunction below returns > nil in your case. There is a previous buffer. ("*scratch*") #+BEGIN_SRC lisp ((and (not prev-buffer) ; => Return nil here. (eq (nth 1 quit-restore) 'frame) (eq (window-deletable-p window) 'frame) (eq (nth 3 quit-restore) buffer)) ;; WINDOW's frame can be deleted. (delete-frame (window-frame window)) #+END_SRC This is working: #+BEGIN_SRC lisp ((and (or (not prev-buffer) (window-dedicated-p)) (eq (nth 1 quit-restore) 'frame) (eq (window-deletable-p window) 'frame) (eq (nth 3 quit-restore) buffer)) ;; WINDOW's frame can be deleted. (delete-frame (window-frame window)) #+END_SRC -- A+ Thierry Get my Gnupg key: gpg --keyserver pgp.mit.edu --recv-keys 59F29997