Fixed #5406: Ensure mouse wheel rotation step is never zero
authorArmin Novak <armin.novak@thincast.com>
Tue, 25 Jun 2019 08:31:17 +0000 (10:31 +0200)
committerArmin Novak <armin.novak@thincast.com>
Tue, 25 Jun 2019 08:31:17 +0000 (10:31 +0200)
thank you @victorking528

client/Mac/MRDPView.m

index 47f2975..bdc3c32 100644 (file)
@@ -434,6 +434,9 @@ DWORD WINAPI mac_client_thread(void* param)
                return;
 
        /* send out all accumulated rotations */
+       if (units > WheelRotationMask)
+               units = WheelRotationMask;
+
        while (units != 0)
        {
                /* limit to maximum value in WheelRotationMask (9bit signed value) */