From ad5fd96419e98950dafeebafa963d5302c5baeaa Mon Sep 17 00:00:00 2001 From: rexim Date: Wed, 3 Dec 2025 04:25:34 +0700 Subject: [PATCH] Fix Ctrl+Scroll not working in RGFW version --- src/main_rgfw.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main_rgfw.c b/src/main_rgfw.c index 30899ce..79f2e98 100644 --- a/src/main_rgfw.c +++ b/src/main_rgfw.c @@ -43,7 +43,7 @@ u64 RGFW_getTimerValue(void) { QueryPerformanceCounter((LARGE_INTEGER*)&value); return value; } -#else +#else // TODO: make RGFW_getTimerFreq, RGFW_getTimerValue, RGFW_sleep compile on the rest of the platforms (Windows, MacOS) void RGFW_sleep(u64 ms) { struct timespec time; @@ -384,8 +384,8 @@ int main(int argc, char **argv) } break; } } break; - case RGFW_mouseButtonPressed: { - if (event.key.mod & RGFW_modControl) { + case RGFW_mouseScroll: { + if (RGFW_isKeyDown(RGFW_controlL) || RGFW_isKeyDown(RGFW_controlR)) { if (event.scroll.y > 0) { state.user_scale += SCALE_FACTOR * state.user_scale; } else if (event.scroll.y < 0) {