diff options
author | Peter Hutterer <peter@cs.unisa.edu.au> | 2008-05-23 11:51:53 +0930 |
---|---|---|
committer | Peter Hutterer <peter@cs.unisa.edu.au> | 2008-05-23 12:01:37 +0930 |
commit | 6c9e9f8a40e20fb1761440acd2755f5fd31f4d44 (patch) | |
tree | 51093ef132aceaef19cfe43df0d42f9124b2157e /Xext | |
parent | fb146cbb0f28e4e480e5d16d61476ac46b5d00ce (diff) |
input: instead of lastx/y, use a last.valuators[] array on the device.
During GetPointerEvents (and others), we need to access the last coordinates
posted for this device from the driver (not as posted to the client!). Lastx/y
is ok if we only have two axes, but with more complex devices we also need to
transition between all other axes.
ABI break, recompile your input drivers.
Diffstat (limited to 'Xext')
-rw-r--r-- | Xext/xtest.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Xext/xtest.c b/Xext/xtest.c index a42faa791..58e20ef81 100644 --- a/Xext/xtest.c +++ b/Xext/xtest.c @@ -470,16 +470,16 @@ ProcXTestFakeInput(client) ev->u.keyButtonPointer.rootX, ev->u.keyButtonPointer.rootY, FALSE); } - dev->lastx = ev->u.keyButtonPointer.rootX; - dev->lasty = ev->u.keyButtonPointer.rootY; + dev->last.valuators[0] = ev->u.keyButtonPointer.rootX; + dev->last.valuators[1] = ev->u.keyButtonPointer.rootY; break; case ButtonPress: case ButtonRelease: if (!extension) dev = PickPointer(client); - ev->u.keyButtonPointer.rootX = dev->lastx; - ev->u.keyButtonPointer.rootY = dev->lasty; + ev->u.keyButtonPointer.rootX = dev->last.valuators[0]; + ev->u.keyButtonPointer.rootY = dev->last.valuators[1]; if (!ev->u.u.detail || ev->u.u.detail > dev->button->numButtons) { client->errorValue = ev->u.u.detail; |