[PATCH] dix: Always add valuator information if present
Daniel Stone
daniel at fooishbar.org
Sun Dec 16 09:45:49 PST 2007
On Sun, Dec 16, 2007 at 06:12:41PM +0100, Magnus Vigerlöf wrote:
> On söndag 16 december 2007, Daniel Stone wrote:
> > Er, except they won't, because DeviceKeyButtonPointer includes both
> > event_{x,y} and root_{x,y}, so you always have the first two axes (as I
> > just verified with people.fd.o/~daniels/xiread.c and my trackpoint). If
> > you want to get extended axes, hmm. Okay, turns out I misread the spec,
> > and it said that relative devices _may_ report all zeros in the valuator
> > fields, not must, as I thought. I'll merge a slightly modified version;
> > only send separate valuators if there are more than two, or it's a
> > motion notify.
>
> Hmmm... Ok, I'm not so familiar with the spec, of the thoughts behind how
> events should be generated. I only saw a difference in behaviour and checked
> what was different..
>
> As long as the net result will be that the coordinates in the InputDevice
> coordinate space will be included in the event that reaches the XClient (for
> example Gimp that doesn't look at the screen-scaled x&y, but will use the
> high-resolution axis that a Wacom tablet will provide).
Ah! Good point. Yes, we always want to send valuators if they're at all
scaled. But given that we need to send all valuators on motion events
anyway, it doesn't make sense overoptimising the button case.
> The linuxwacom driver always send 6 axis so it shouldn't be a problem for us.
> But if we have a slightly more simple device which only have two axis and a
> few buttons (I'm not sure if acecad falls into this category), won't the
> above restrictions ensure that the extended axes will get '0' again?
Well, not zero, just not sent. :)
Cheers,
Daniel
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.x.org/archives/xorg/attachments/20071216/0a7c2bbd/attachment.pgp>
More information about the xorg
mailing list