You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Short overview
Slight misalignment of moveMouse on Windows
Steps to reproduce error
The following code periodically gives the coordinates obtained by getMousePos to moveMouse, so the mouse cursor is expected to be stationary, but in my Windows environment the cursor gradually moves up until the y-coordinate becomes a multiple of 135.
The corresponding code in robotjs appears to differ in the rounding process and the correction according to the sign of the coordinates.
With this as a reference, if CalculateAbsoluteCoordinates is changed as follows, the problem in the test code above is no longer apparent.
Version
2.1.8
Short overview
Slight misalignment of moveMouse on Windows
Steps to reproduce error
The following code periodically gives the coordinates obtained by
getMousePos
tomoveMouse
, so the mouse cursor is expected to be stationary, but in my Windows environment the cursor gradually moves up until the y-coordinate becomes a multiple of 135.Detailed error description
I have not been able to track down the details, but I suspect the problem is in the following code
https://github.com/nut-tree/libnut/blob/9f366a9f551bb653a3e43106804edf83cfeb696c/src/win32/mouse.c#L35-L38
The corresponding code in robotjs appears to differ in the rounding process and the correction according to the sign of the coordinates.
With this as a reference, if
CalculateAbsoluteCoordinates
is changed as follows, the problem in the test code above is no longer apparent.This change seemed to cause a new left-right misalignment, but for some reason it did not, and I still do not know why...
The text was updated successfully, but these errors were encountered: