mirror of
https://github.com/glfw/glfw.git
synced 2024-11-23 05:24:34 +00:00
Fixed window position on Win32.
This commit is contained in:
parent
11743758f8
commit
41be34eadf
9
src/win32_window.c
Normal file → Executable file
9
src/win32_window.c
Normal file → Executable file
@ -1047,11 +1047,6 @@ static LRESULT CALLBACK windowProc(HWND hWnd, UINT uMsg,
|
|||||||
|
|
||||||
case WM_MOVE:
|
case WM_MOVE:
|
||||||
{
|
{
|
||||||
RECT rect;
|
|
||||||
|
|
||||||
GetClientRect(window->Win32.handle, &rect);
|
|
||||||
AdjustWindowRectEx(&rect, window->Win32.dwStyle, FALSE, window->Win32.dwExStyle);
|
|
||||||
|
|
||||||
// If window is in cursor capture mode, update clipping rect
|
// If window is in cursor capture mode, update clipping rect
|
||||||
if (window->cursorMode == GLFW_CURSOR_CAPTURED)
|
if (window->cursorMode == GLFW_CURSOR_CAPTURED)
|
||||||
{
|
{
|
||||||
@ -1060,9 +1055,7 @@ static LRESULT CALLBACK windowProc(HWND hWnd, UINT uMsg,
|
|||||||
ClipCursor(&ClipWindowRect);
|
ClipCursor(&ClipWindowRect);
|
||||||
}
|
}
|
||||||
|
|
||||||
_glfwInputWindowPos(window,
|
_glfwInputWindowPos(window, LOWORD(lParam), HIWORD(lParam));
|
||||||
LOWORD(lParam) - rect.left,
|
|
||||||
HIWORD(lParam) - rect.top);
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user