Fix menu mouse position on high pixel density displays - #1012
Conversation
SDL_GetMouseState returns points, M_PixelToMenuCanvasCoord expects pixels. IN_GetMousePos scales between the two; the console already uses it. No change when pixel density is 1.
|
In original report:
To confirm, was it just windowed that was wrong, or also fullscreen ? I"ll test for Windows, thank you for the fix. @Perlence do you confirm the bug, and the fix on your side ? Hum. the |
|
Can confirm, in 1.36.0, mouse movement doesn't select the menu items in both fullscreen and windowed modes. However, the console text selection works: Screen.Recording.2026-09-01.at.22.29.04_edit.movThe fix works: Screen.Recording.2026-09-01.at.22.33.25_edit.mov |
|
OK @AllMelody Now that I really looked at the code :) your patch makes perfect sense, we don't need the I don't see what could break here. Thanks for your contribution ! and thanks @Perlence for the confirmation ! |
SDL_GetMouseState returns points, M_PixelToMenuCanvasCoord expects pixels. IN_GetMousePos scales between the two; the console already uses it.
No change when pixel density is 1. Not tested on Windows or Linux. Fixes #1011 locally for me.