qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] hw/input/ps2.c: fix erratic mouse behavior for


From: Gerd Hoffmann
Subject: Re: [Qemu-devel] [PATCH] hw/input/ps2.c: fix erratic mouse behavior for Windows 3.1
Date: Mon, 20 Aug 2018 07:24:56 +0200
User-agent: NeoMutt/20180622

On Sun, Aug 19, 2018 at 12:35:09AM -0400, John Arbuckle wrote:
> When the user moves the mouse and moves the scroll wheel at the same
> time, the mouse cursor's movement becomes erratic in Windows 3.1. With
> this patch if the mouse is in ps/2 mode and the scroll wheel is used,
> the command queue is reset. This does not fix the erratic mouse
> problem in Windows NT 4.0.

I don't think we need to reset the queue.  Just ignoring the z axis
value for type 0 should do.  Can you try this?

--- a/hw/input/ps2.c
+++ b/hw/input/ps2.c
@@ -661,6 +661,8 @@ static int ps2_mouse_send_packet(PS2MouseState *s)
     /* extra byte for IMPS/2 or IMEX */
     switch(s->mouse_type) {
     default:
+        s->mouse_dz = 0;
+        dz1 = 0;
         break;
     case 3:
         if (dz1 > 127)

cheers,
  Gerd




reply via email to

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