https://git.reactos.org/?p=reactos.git;a=commitdiff;h=820dbfccd015d8890d5948b6abd5089e8ab8cf86

commit 820dbfccd015d8890d5948b6abd5089e8ab8cf86
Author:     Joachim Henze <[email protected]>
AuthorDate: Sun Feb 23 13:55:27 2020 +0100
Commit:     Joachim Henze <[email protected]>
CommitDate: Sun Feb 23 13:56:05 2020 +0100

    [NTUSER] Fix regression CORE-11828
    
    Fixes symptom "mouse pointer vanishes when closing
    applications via x in title-bar"
    
    The bug in WIN32SS was unhidden by SVN r65496 == git
    5c1a8109c84ed0aefdac2488ff666070a7ae52f6
    , when we introduced explorer_new. The old explorer
    had a workaround built within.
    
    Many thanks to patches author James Tabor.
    I intend to backport into 0.4.13RC as well.
---
 win32ss/user/ntuser/main.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/win32ss/user/ntuser/main.c b/win32ss/user/ntuser/main.c
index 95ab58474c9..be31889664d 100644
--- a/win32ss/user/ntuser/main.c
+++ b/win32ss/user/ntuser/main.c
@@ -420,6 +420,16 @@ UserDeleteW32Thread(PTHREADINFO pti)
    ExFreePoolWithTag(pti, USERTAG_THREADINFO);
 
    IntDereferenceProcessInfo(ppi);
+
+   {
+      // Find another queue for mouse cursor.
+      MSG msg;
+      msg.message = WM_MOUSEMOVE;
+      msg.wParam = UserGetMouseButtonsState();
+      msg.lParam = MAKELPARAM(gpsi->ptCursor.x, gpsi->ptCursor.y);
+      msg.pt = gpsi->ptCursor;
+      co_MsqInsertMouseMessage(&msg, 0, 0, TRUE);
+   }
 }
 
 NTSTATUS

Reply via email to