blob: 3e25586fab7ca5acf23b9e2d8f246ff443e4370b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
$NetBSD: patch-bl,v 1.1 2005/06/07 02:43:26 xtraeme Exp $
--- programs/Xserver/hw/xfree86/common/xf86Xinput.c.orig 2005-05-16 23:20:56.000000000 +0900
+++ programs/Xserver/hw/xfree86/common/xf86Xinput.c 2005-05-16 23:23:25.000000000 +0900
@@ -932,15 +932,10 @@
/* modeled from xf86Events.c */
if (device->ptrfeed->ctrl.threshold) {
if ((abs(dx) + abs(dy)) >= device->ptrfeed->ctrl.threshold) {
- local->dxremaind = ((float)dx * (float)(device->ptrfeed->ctrl.num)) /
- (float)(device->ptrfeed->ctrl.den) + local->dxremaind;
- valuator[0] = (int)local->dxremaind;
- local->dxremaind = local->dxremaind - (float)valuator[0];
-
- local->dyremaind = ((float)dy * (float)(device->ptrfeed->ctrl.num)) /
- (float)(device->ptrfeed->ctrl.den) + local->dyremaind;
- valuator[1] = (int)local->dyremaind;
- local->dyremaind = local->dyremaind - (float)valuator[1];
+ valuator[0] = (dx * device->ptrfeed->ctrl.num) /
+ device->ptrfeed->ctrl.den;
+ valuator[1] = (dy * device->ptrfeed->ctrl.num) /
+ device->ptrfeed->ctrl.den;
}
}
else if (dx || dy) {
|