Mouse functions
Kapouett opened this issue · 2 comments
Kapouett commented
input::mouse_x() and input::mouse_y() underflow when the cursor is at the top or left edge of the virtual monitor.
It also seems that input::mouse_rel_x() and input::mouse_rel_y() always return 0 (at least on X11), and are also unsigned, which would cause wrong values for left/up movement.
Enet4 commented
Thank you for bringing this up. Would you be able to send a pull request in to solve both concerns?
Kapouett commented
I was able to solve the problem with absolute position easily by just changing mouse_x and mouse_y to i32.
Relative positions seem to be a problem with dos-like rather than the Rust binding.
Edit: dos_like turns the values into floats at some point, which is what breaks them, I'll make a pull request there.