[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Need a direction to XInput support in NSEvent.

From: Adam Fedor
Subject: Re: Need a direction to XInput support in NSEvent.
Date: Thu, 29 Jan 2004 08:40:33 -0700

On Thursday, January 29, 2004, at 01:29 AM, Banlu Kemiyatorn wrote:

Tilts are the angles that the device do to the tablet plane in X and Y axis.
If deltas were used in a mouse event, how can application know about
original event. And there's no event on tilt angles changing. You will
know the tilt angles once on each movement event arriving.

What is device id used for and how would the front-end deal with it?
maybe use button number? I'd rather not overload things too much, but it
depends on how much you need and how much is useful (and trying not to
add new ivars).

Device id is used to specify the device that cause the event. XInput allow many devices working at the same time. (such as cursor, stylus, eraser, mouse,
4d mouse, keyboard(s?))

I was talking about overloading the meaning of delta[XYZ] to mean instead tiltX, tiltY, rotation (for example). For instance, you could set the event type to NSOtherMouse, use the buttonNumber field to specify the device id or perhaps there should be some consistent mapping between the buttonNumber and the type of device (we don't currently set or use buttonNumber).

An alternative would be to define your own special event sub-type under the NSAppKitEvent or NSSystemEvent type. As an absolute last resort we could define a new event type with it's own ivars and init method - but that would potentially make things incompatible with MacOS X

reply via email to

[Prev in Thread] Current Thread [Next in Thread]