From 883679e96ba4d0d5846f87169320e146bc3f4c10 Mon Sep 17 00:00:00 2001 From: Daniel Collin Date: Sun, 28 Nov 2021 18:03:01 +0100 Subject: [PATCH] Fix for stuck scrollwheel on macOS --- src/native/macosx/MacMiniFB.m | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/native/macosx/MacMiniFB.m b/src/native/macosx/MacMiniFB.m index 4a335b6..90d563c 100644 --- a/src/native/macosx/MacMiniFB.m +++ b/src/native/macosx/MacMiniFB.m @@ -299,7 +299,7 @@ void mfb_topmost(void* window, bool topmost) if(topmost) { win.level = NSFloatingWindowLevel; // set level to floating - } else + } else { win.level = 0; // set to default/normal } @@ -479,6 +479,11 @@ static int update_events() static int generic_update(OSXWindow* win) { + if (win->shared_data) { + win_shared_data->scroll_x = 0.0f; + win_shared_data->scroll_y = 0.0f; + } + int state = update_events(); if (win->shared_data) {