From 45be647baf276932ebc37dab8cdefe14483c192a Mon Sep 17 00:00:00 2001 From: Yuhang Zhao <2546789017@qq.com> Date: Sun, 15 May 2022 15:51:09 +0800 Subject: [PATCH] win32: fix another issue related to hit test This issue was hidden due to it's actually not executed. Signed-off-by: Yuhang Zhao <2546789017@qq.com> --- src/core/framelesshelper_win.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/core/framelesshelper_win.cpp b/src/core/framelesshelper_win.cpp index 14c690ef..bb320529 100644 --- a/src/core/framelesshelper_win.cpp +++ b/src/core/framelesshelper_win.cpp @@ -113,10 +113,10 @@ FRAMELESSHELPER_STRING_CONSTANT(FindWindowW) // window is not resizable, the snap layouts feature should also be disabled at the same time, // hence forward everything to the parent window, we don't need to handle anything here. if (data.params.isWindowFixedSize()) { - // Ask the parent window for the hit test result and returns it here, to - // let our homemade title bar still draggable. + // Let the mouse event pass through our fallback title bar window to the root window + // under it, to ensure our homemade title bar keep functional. if (uMsg == WM_NCHITTEST) { - return SendMessageW(parentWindowHandle, uMsg, wParam, lParam); + return HTTRANSPARENT; } // Forward all mouse events to the parent window to let the controls inside // our homemade title bar still continue to work normally. But ignore these