From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: [PATCH 2/2] avoid: ignore mouse when it is hidden Date: Mon, 18 Oct 2010 17:10:58 -0400 Message-ID: References: <1287067949-23750-1-git-send-email-julien@danjou.info> <1287067949-23750-3-git-send-email-julien@danjou.info> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1287436293 21139 80.91.229.12 (18 Oct 2010 21:11:33 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 18 Oct 2010 21:11:33 +0000 (UTC) Cc: emacs-devel@gnu.org To: Julien Danjou Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Oct 18 23:11:31 2010 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1P7wzM-0004br-TU for ged-emacs-devel@m.gmane.org; Mon, 18 Oct 2010 23:11:25 +0200 Original-Received: from localhost ([127.0.0.1]:50462 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1P7wzM-0002jZ-0U for ged-emacs-devel@m.gmane.org; Mon, 18 Oct 2010 17:11:24 -0400 Original-Received: from [140.186.70.92] (port=49848 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1P7wz9-0002hf-9E for emacs-devel@gnu.org; Mon, 18 Oct 2010 17:11:12 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1P7wz8-0002aD-4l for emacs-devel@gnu.org; Mon, 18 Oct 2010 17:11:11 -0400 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.181]:51426 helo=ironport2-out.pppoe.ca) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1P7wz8-0002a9-2Z for emacs-devel@gnu.org; Mon, 18 Oct 2010 17:11:10 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AjALAP9UvExMCpO7/2dsb2JhbACgUnlywC2FSQSSGQ X-IronPort-AV: E=Sophos;i="4.57,346,1283745600"; d="scan'208";a="80053210" Original-Received: from 76-10-147-187.dsl.teksavvy.com (HELO pastel.home) ([76.10.147.187]) by ironport2-out.pppoe.ca with ESMTP/TLS/ADH-AES256-SHA; 18 Oct 2010 17:11:09 -0400 Original-Received: by pastel.home (Postfix, from userid 20848) id C0DB6A822C; Mon, 18 Oct 2010 17:10:58 -0400 (EDT) In-Reply-To: <1287067949-23750-3-git-send-email-julien@danjou.info> (Julien Danjou's message of "Thu, 14 Oct 2010 16:52:29 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:131822 Archived-At: > (defun mouse-avoidance-ignore-p () > (let ((mp (mouse-position))) > - (or executing-kbd-macro ; don't check inside macro > + (or (not (frame-pointer-visible-p)) ; The pointer is hidden > + executing-kbd-macro ; don't check inside macro > (null (cadr mp)) ; don't move unless in an Emacs frame > (not (eq (car mp) (selected-frame))) > ;; Don't do anything if last event was a mouse event. Installed as well, Stefan