From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.bugs Subject: special-display-popup-frame should have BUFFER current when it calls make-frame Date: Fri, 1 Oct 2004 11:07:08 -0700 Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Message-ID: NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1096654114 4482 80.91.229.6 (1 Oct 2004 18:08:34 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 1 Oct 2004 18:08:34 +0000 (UTC) Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Oct 01 20:08:24 2004 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1CDRpQ-0007An-00 for ; Fri, 01 Oct 2004 20:08:24 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CDRvr-0007bv-R3 for geb-bug-gnu-emacs@m.gmane.org; Fri, 01 Oct 2004 14:15:03 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1CDRvq-0007bi-8m for bug-gnu-emacs@gnu.org; Fri, 01 Oct 2004 14:15:02 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1CDRvo-0007ap-Oe for bug-gnu-emacs@gnu.org; Fri, 01 Oct 2004 14:15:01 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CDRvo-0007a2-0R for bug-gnu-emacs@gnu.org; Fri, 01 Oct 2004 14:15:00 -0400 Original-Received: from [141.146.126.230] (helo=agminet03.oracle.com) by monty-python.gnu.org with esmtp (TLSv1:DES-CBC3-SHA:168) (Exim 4.34) id 1CDRoG-0006TL-JO for bug-gnu-emacs@gnu.org; Fri, 01 Oct 2004 14:07:12 -0400 Original-Received: from rgmgw3.us.oracle.com (rgmgw3.us.oracle.com [138.1.191.12]) by agminet03.oracle.com (Switch-3.1.4/Switch-3.1.0) with ESMTP id i91I7AFf002657 for ; Fri, 1 Oct 2004 11:07:10 -0700 Original-Received: from rgmgw3.us.oracle.com (localhost [127.0.0.1]) by rgmgw3.us.oracle.com (Switch-3.1.4/Switch-3.1.0) with ESMTP id i91I7Acc031585 for ; Fri, 1 Oct 2004 12:07:10 -0600 Original-Received: from dradamslap (dhcp-amer-csvpn-gw1-141-144-68-132.vpn.oracle.com [141.144.68.132]) by rgmgw3.us.oracle.com (Switch-3.1.4/Switch-3.1.0) with SMTP id i91I79O8031564 for ; Fri, 1 Oct 2004 12:07:09 -0600 Original-To: X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.6604 (9.0.2911.0) X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2800.1441 Importance: Normal X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.bugs:9164 X-Report-Spam: http://spam.gmane.org/gmane.emacs.bugs:9164 This problem existed in Emacs 20. I'm not positive that this change needs to be made to Emacs 21, but comparing the code to the Emacs 20 code, I believe the change still needs to be made. The problem is that, when a new frame is created because no window exists yet, the call to make-frame does not happen with BUFFER current. This can have undesirable consequences for, for instance, after-make-frame-functions that might depend on which buffer is current. The code should be changed from this: (make-frame (append args special-display-frame-alist)) to this: (save-excursion (set-buffer buffer) (make-frame (append args special-display-frame-alist)))