From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Lennart Staflin Newsgroups: gmane.emacs.devel Subject: Re: Mac emacs scroll bars Date: Fri, 9 Jul 2004 17:27:44 +0200 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: <866D3BF8-D1BC-11D8-ACC3-00039343C89C@lysator.liu.se> References: <7627C10A-CF84-11D8-8F92-00050260B859@duke.edu> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 (Apple Message framework v618) Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1089387274 22629 80.91.224.253 (9 Jul 2004 15:34:34 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 9 Jul 2004 15:34:34 +0000 (UTC) Cc: emacs-devel Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Fri Jul 09 17:34:25 2004 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1BixIa-00050V-00 for ; Fri, 09 Jul 2004 17:28:28 +0200 Original-Received: from lists.gnu.org ([199.232.76.165]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1BixIZ-0003du-00 for ; Fri, 09 Jul 2004 17:28:27 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1BixKi-0004Wh-1Y for emacs-devel@quimby.gnus.org; Fri, 09 Jul 2004 11:30:40 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1BixKZ-0004WS-5C for emacs-devel@gnu.org; Fri, 09 Jul 2004 11:30:31 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1BixKX-0004WG-EO for emacs-devel@gnu.org; Fri, 09 Jul 2004 11:30:30 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1BixKX-0004WD-BU for emacs-devel@gnu.org; Fri, 09 Jul 2004 11:30:29 -0400 Original-Received: from [62.79.79.112] (helo=smtp130.tiscali.dk) by monty-python.gnu.org with esmtp (TLSv1:DES-CBC3-SHA:168) (Exim 4.34) id 1BixHv-0005bW-Tf for emacs-devel@gnu.org; Fri, 09 Jul 2004 11:27:48 -0400 Original-Received: from [172.17.0.3] (h49n2c1o1036.bredband.skanova.com [81.227.25.49]) by smtp130.tiscali.dk (8.12.11/8.12.11) with ESMTP id i69FRhD4024798; Fri, 9 Jul 2004 17:27:44 +0200 (CEST) (envelope-from lenst@lysator.liu.se) In-Reply-To: Original-To: YAMAMOTO Mitsuharu X-Mailer: Apple Mail (2.618) 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: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:25556 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:25556 On 9 jul 2004, at 11:53, YAMAMOTO Mitsuharu wrote: > (defun mac-scroll-ignore-events () > ;; Ignore confusing non-mouse events > (while (not (eq (event-basic-type (read-event)) 'mouse-1)) > nil)) > You should not ignore all events but mouse-1, unless you are sure that there will be a mouse-1 event before any other interesting event. I don't think that is guaranteed, because of the way events are simplified/translated. The code can be called from a double mouse down event translated to single mouse down and then there won't be a mouse-1 event, but a double-mouse-1 (or whatever it is called). You end up stuck in the loop ignoring events that should be handled. //Lennart Staflin