-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The two screen calibration clicks return the same position in Wayland #8
Comments
Even by copy pasting the exact screen calibration code, I was unable to reproduce getting two clicks with the same position. I watched the program run in the console, and it's not because it's registering the same click twice (at least not directly). It waited for the second click to print the same coordinates again. |
Confirming, neither this nor #7 affect the Windows version, even with the same old mouse, keyboard, and PyAutoGUI libraries. |
I was later able to reproduce by making the IDLE window lose focus, that is, clicking an area outside it. Note, if I clicked outside it and then clicked inside, the mouse position was reported correctly. |
Using PyAutoGUI's Mouse Info app, I discovered that position stops reporting as updated when the mouse is not over IDLE or the Mouse Info window. Thus, the mouse position getting system is restricted. |
PyAutoGUI uses Xlib, so the mouse module must be having a separate issue? |
Oddly, the mouse module has the exact same behavior. |
I caused Wayland to grant input control to Python first, but this did not make the position reporting work correctly. |
Oh, the mouse module might just use the device reading for buttons, but still use xlib position sensing, which relies on XWayland, which is probably limited to the creating window. |
Test to do: Have the mouse fix window maximized behind the emulator window, and see if that lets position reporting work as the mouse cursor is over both of them. |
Did not work. However, I found out that OTHER windows from DIFFERENT processes that are also using XWayland let the system work. Maybe if I could somehow make MelonDS launch with XWayland? |
TYJ, that does work! See this article for information on how to do it:
|
The text was updated successfully, but these errors were encountered: