From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/38792 Path: main.gmane.org!not-for-mail From: gerd.moellmann@t-online.de (Gerd Moellmann) Newsgroups: gmane.emacs.gnus.general Subject: Re: Mouse-2 on e-mail in From: header? Date: 17 Sep 2001 13:48:14 +0200 Sender: gerd@localhost.dnsalias.org Message-ID: <8666aiyr5t.fsf@gerd.dnsalias.org> References: <2nsndpqi63.fsf@piglet.jia.vnet> Reply-To: gerd@gnu.org NNTP-Posting-Host: coloc-standby.netfonds.no Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1035174598 24338 80.91.224.250 (21 Oct 2002 04:29:58 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Mon, 21 Oct 2002 04:29:58 +0000 (UTC) Return-Path: Return-Path: Original-Received: (qmail 14120 invoked from network); 17 Sep 2001 11:48:34 -0000 Original-Received: from mailout04.sul.t-online.com (HELO mailout04.sul.t-online.de) (194.25.134.18) by gnus.org with SMTP; 17 Sep 2001 11:48:34 -0000 Original-Received: from fwd01.sul.t-online.de by mailout04.sul.t-online.de with smtp id 15iwt6-0005wx-00; Mon, 17 Sep 2001 13:48:32 +0200 Original-Received: from gerd.dnsalias.org (520015515780-0001@[217.85.169.171]) by fwd01.sul.t-online.com with esmtp id 15iwsr-0yF5JAC; Mon, 17 Sep 2001 13:48:17 +0200 Original-Received: (from gerd@localhost) by gerd.dnsalias.org (8.11.6/8.11.4) id f8HBmEg03054; Mon, 17 Sep 2001 13:48:14 +0200 (CEST) (envelope-from gerd@gnu.org) X-Authentication-Warning: gerd.dnsalias.org: gerd set sender to gerd@gnu.org using -f Original-To: ding@gnus.org In-Reply-To: <2nsndpqi63.fsf@piglet.jia.vnet> User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.0.106 X-Sender: 520015515780-0001@t-dialin.net Original-Lines: 55 Xref: main.gmane.org gmane.emacs.gnus.general:38792 X-Report-Spam: http://spam.gmane.org/gmane.emacs.gnus.general:38792 ShengHuo ZHU writes: > The problem is because the button-click function changes the window > configuration, however, in widget-button-click, there is a > save-selected-window. The attached workaround fixes the problem. > > Gerd, what is the reason to save the selected window around the code > handling clicks on buttons in widget-button-click? I'm afraid I don't remember details anymore. I think it was a report from Dave Love that triggered that, so I might be able to find this in my mail archive, if you think it's worth searching. > Is the workaround appropriate? > > ShengHuo > > > Index: gnus-msg.el > =================================================================== > RCS file: /usr/local/cvsroot/gnus/lisp/gnus-msg.el,v > retrieving revision 6.46 > diff -u -r6.46 gnus-msg.el > --- gnus-msg.el 2001/08/20 18:54:43 6.46 > +++ gnus-msg.el 2001/09/15 02:41:26 > @@ -322,19 +322,27 @@ > ;; COMPOSEFUNC should return t if succeed. Undocumented ??? > t) > > +(defvar save-selected-window-window) > + > ;;;###autoload > (defun gnus-button-mailto (address) > "Mail to ADDRESS." > (set-buffer (gnus-copy-article-buffer)) > (gnus-setup-message 'message > - (message-reply address))) > + (message-reply address)) > + (and (boundp 'save-selected-window-window) > + (not (window-live-p save-selected-window-window)) > + (setq save-selected-window-window (selected-window)))) > > ;;;###autoload > (defun gnus-button-reply (&optional to-address wide) > "Like `message-reply'." > (interactive) > (gnus-setup-message 'message > - (message-reply to-address wide))) > + (message-reply to-address wide)) > + (and (boundp 'save-selected-window-window) > + (not (window-live-p save-selected-window-window)) > + (setq save-selected-window-window (selected-window)))) Sorry if I'm dense, but I don't understand what the change does. Is save-selected-window-window used somewhere else?