|
@@ -1284,12 +1284,10 @@ static void ImGui_ImplGlfw_ShowWindow(ImGuiViewport* viewport)
|
|
::SetWindowLong(hwnd, GWL_EXSTYLE, ex_style);
|
|
::SetWindowLong(hwnd, GWL_EXSTYLE, ex_style);
|
|
}
|
|
}
|
|
|
|
|
|
- // GLFW hack: install hook for WM_NCHITTEST message handler
|
|
|
|
-#if !GLFW_HAS_MOUSE_PASSTHROUGH && GLFW_HAS_WINDOW_HOVERED && defined(_WIN32)
|
|
|
|
|
|
+ // GLFW hack: install WndProc for mouse source event and WM_NCHITTEST message handler.
|
|
::SetPropA(hwnd, "IMGUI_VIEWPORT", viewport);
|
|
::SetPropA(hwnd, "IMGUI_VIEWPORT", viewport);
|
|
vd->PrevWndProc = (WNDPROC)::GetWindowLongPtrW(hwnd, GWLP_WNDPROC);
|
|
vd->PrevWndProc = (WNDPROC)::GetWindowLongPtrW(hwnd, GWLP_WNDPROC);
|
|
::SetWindowLongPtrW(hwnd, GWLP_WNDPROC, (LONG_PTR)ImGui_ImplGlfw_WndProc);
|
|
::SetWindowLongPtrW(hwnd, GWLP_WNDPROC, (LONG_PTR)ImGui_ImplGlfw_WndProc);
|
|
-#endif
|
|
|
|
|
|
|
|
#if !GLFW_HAS_FOCUS_ON_SHOW
|
|
#if !GLFW_HAS_FOCUS_ON_SHOW
|
|
// GLFW hack: GLFW 3.2 has a bug where glfwShowWindow() also activates/focus the window.
|
|
// GLFW hack: GLFW 3.2 has a bug where glfwShowWindow() also activates/focus the window.
|