+ added X/Y overflow for Mouse emulation

This commit is contained in:
ekeeke31 2009-04-21 15:23:32 +00:00
parent 3f6925dc8a
commit 60cdda4c53

View File

@ -207,6 +207,8 @@ uint32 mouse_read()
case 4: /* Axis sign and overflow */ case 4: /* Axis sign and overflow */
if (input.analog[2][0] < 0) temp |= 0x01; if (input.analog[2][0] < 0) temp |= 0x01;
if (input.analog[2][1] < 0) temp |= 0x02; if (input.analog[2][1] < 0) temp |= 0x02;
if (abs(input.analog[2][0]) > 255) temp |= 0x04;
if (abs(input.analog[2][1]) > 255) temp |= 0x08;
break; break;
case 5: /* Buttons state */ case 5: /* Buttons state */