Index: [thread] [date] [subject] [author]
  From: Andrew Apted <ajapted@netspace.net.au>
  To  : ggi-develop@eskimo.com
  Date: Sun, 20 Jun 1999 00:00:18 +1000

Re: libgii - mysterious mouse implementation

Christoph Egger writes:

>  I tried to hack in libgii the third mouse button recognization of a serial
>  mouse using the microsoft-protocol.

If I remember correctly, the third mouse button in ms protocol is a hack
(something like both buttons appear to be pressed at the same time, and
dx=dy=0 -- read the gpm sources for more info).  At the time, I deemed
it too unreliable to be worth supporting.

>  But here I detected a mysterious
>  thing: When I apply the following patch the inputdump demo recognize the
>  middle mouse button as both left and right mouse button...
[SNIP]
>  When I apply the following patch instead, inputdump recognizes the middle
>  mouse button as expected...
[SNIP]
>  Can anyone explain this?

Yes: the `buttons' variable is an internal variable which is a _bitmask_
of the buttons.  The GII_BUTTON thingies are button _numbers_ (1, 2, 3,
4, ...).

"Mystery" solved :-)

Cheers,
___________________________________________________
                                               \  /
  Andrew Apted   <ajapted@netspace.net.au>      \/
 

Index: [thread] [date] [subject] [author]