1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-10 07:04:03 +00:00
freebsd-ports/x11/XFree86-4-libraries/files/patch-mouse.c
Eric Anholt 6c42faf2e8 Add patches for last commit (fixing scrollwheel on -current, and enabling
SYSVIPC to aid nv binary drivers)

Approved by:	mdodd
2002-08-05 07:33:22 +00:00

12 lines
522 B
C

--- programs/Xserver/hw/xfree86/input/mouse/mouse.c.orig Wed Dec 19 08:05:22 2001
+++ programs/Xserver/hw/xfree86/input/mouse/mouse.c Fri Aug 2 15:35:01 2002
@@ -1505,7 +1505,7 @@
dy = - ((char)(pBuf[2]) + (char)(pBuf[4]));
/* FreeBSD sysmouse sends additional data bytes */
if (pMse->protoPara[4] >= 8) {
- dz = ((char)(pBuf[5] << 1) + (char)(pBuf[6] << 1)) / 2;
+ dz = ((signed char)(pBuf[5] << 1) + (signed char)(pBuf[6] << 1)) >> 1;
buttons |= (int)(~pBuf[7] & 0x07) << 3;
}
break;