From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#10037: 24.0.91; `isearch-mouse-2' no good with standalone minibuffer frame Date: Tue, 06 Dec 2011 20:15:40 -0500 Message-ID: References: <01C1F1EEC9F042E8B9E91B12BD34EE33@us.oracle.com> <811EE3EE511B43748AEF1A9E8CFE5654@us.oracle.com> <308914D4D17149D99C5B8361D477ED04@us.oracle.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1323220591 27085 80.91.229.12 (7 Dec 2011 01:16:31 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 7 Dec 2011 01:16:31 +0000 (UTC) Cc: 10037@debbugs.gnu.org To: "Drew Adams" Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Dec 07 02:16:27 2011 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1RY67W-0002NZ-6Q for geb-bug-gnu-emacs@m.gmane.org; Wed, 07 Dec 2011 02:16:26 +0100 Original-Received: from localhost ([::1]:48402 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RY67V-0003ST-2N for geb-bug-gnu-emacs@m.gmane.org; Tue, 06 Dec 2011 20:16:25 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:35929) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RY67T-0003SD-8e for bug-gnu-emacs@gnu.org; Tue, 06 Dec 2011 20:16:24 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RY67S-0008Nm-1t for bug-gnu-emacs@gnu.org; Tue, 06 Dec 2011 20:16:23 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:56079) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RY67R-0008Ni-VP for bug-gnu-emacs@gnu.org; Tue, 06 Dec 2011 20:16:22 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1RY685-00008e-R6 for bug-gnu-emacs@gnu.org; Tue, 06 Dec 2011 20:17:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 07 Dec 2011 01:17:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 10037 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 10037-submit@debbugs.gnu.org id=B10037.1323220587480 (code B ref 10037); Wed, 07 Dec 2011 01:17:01 +0000 Original-Received: (at 10037) by debbugs.gnu.org; 7 Dec 2011 01:16:27 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RY67W-00007g-18 for submit@debbugs.gnu.org; Tue, 06 Dec 2011 20:16:26 -0500 Original-Received: from pruche.dit.umontreal.ca ([132.204.246.22]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RY67T-00007Y-Jx for 10037@debbugs.gnu.org; Tue, 06 Dec 2011 20:16:24 -0500 Original-Received: from pastel.home (lechon.iro.umontreal.ca [132.204.27.242]) by pruche.dit.umontreal.ca (8.14.1/8.14.1) with ESMTP id pB71Ff7l013670; Tue, 6 Dec 2011 20:15:41 -0500 Original-Received: by pastel.home (Postfix, from userid 20848) id 65087593FF; Tue, 6 Dec 2011 20:15:40 -0500 (EST) In-Reply-To: <308914D4D17149D99C5B8361D477ED04@us.oracle.com> (Drew Adams's message of "Tue, 6 Dec 2011 16:25:14 -0800") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.91 (gnu/linux) X-NAI-Spam-Flag: NO X-NAI-Spam-Threshold: 5 X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 1 Rules triggered RV4063=0 X-NAI-Spam-Version: 2.2.0.9309 : core <4063> : streams <708434> : uri <1023074> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Tue, 06 Dec 2011 20:17:01 -0500 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org 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 Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:54767 Archived-At: > IOW, why wouldn't it just "work", in practice, at least most of the > time, if `switch-frame' were not coded to exit isearch? Just why is > that exiting needed? Because subsequent operations would take place in the wrong context. The switch-frame occurs *before* and not *together with* the mouse-2 event (or at least, Emacs may very well process the switch-frame event before receiving the mouse-2 event: it's clearly the case for me where I use focus-follows-mouse so the switch-frame event happens as soon as I move the mouse over the other frame, but it can also be the case in the click-to-focus case depending on timing). I.e. to fix this issue, we need to postpone (some part of) the processing of switch-frame events. E.g. Isearch could handle switch-frame by putting itself in an "about to exit" state, but making it work right is likely to be pretty tricky since the time where we actually do exit would likely be something like pre-command-hook at which point the key sequence has already been looked up in the active keymaps which is wrong since which keymaps are active depends on whether we should have exited Isearch or not. Stefan