From: Toni Wilen Date: Thu, 2 May 2024 17:16:54 +0000 (+0300) Subject: Fix magic mouse without enabled mouse driver X-Git-Tag: 5300~20 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=9795b4c0c5f8e8c635ac3d7e57b9581bfe89880e;p=francis%2Fwinuae.git Fix magic mouse without enabled mouse driver --- diff --git a/od-win32/win32.cpp b/od-win32/win32.cpp index 33775bcf..af0c4b72 100644 --- a/od-win32/win32.cpp +++ b/od-win32/win32.cpp @@ -1067,6 +1067,8 @@ static void setmouseactive2(struct AmigaMonitor *mon, int active, bool allowpaus return; } + //write_log(_T("setmouseactive(%d)\n"), active); + if (active < 0) active = 1; @@ -1074,13 +1076,17 @@ static void setmouseactive2(struct AmigaMonitor *mon, int active, bool allowpaus mon->mouseposx = mon->mouseposy = 0; - if (isfullscreen () <= 0 && (currprefs.input_mouse_untrap & MOUSEUNTRAP_MAGIC) && currprefs.input_tablet > 0) { - if (mousehack_alive()) { - releasecapture(mon); + if (isfullscreen() <= 0 && (currprefs.input_mouse_untrap & MOUSEUNTRAP_MAGIC)) { + if (currprefs.input_tablet > 0) { + if (mousehack_alive()) { + releasecapture(mon); + recapture = 0; + return; + } + SetCursor(normalcursor); + } else { recapture = 0; - return; } - SetCursor (normalcursor); } bool gotfocus = false;