Browse Source

Fixed borderless window client area calculation

Sam Lantinga 1 year ago
parent
commit
483155bbf9
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/video/windows/SDL_windowsevents.c

+ 2 - 2
src/video/windows/SDL_windowsevents.c

@@ -1424,8 +1424,8 @@ WIN_WindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
             if (!(window_flags & SDL_WINDOW_RESIZABLE)) {
                 int w, h;
                 NCCALCSIZE_PARAMS *params = (NCCALCSIZE_PARAMS *)lParam;
-                w = data->window->windowed.w;
-                h = data->window->windowed.h;
+                w = data->window->floating.w;
+                h = data->window->floating.h;
                 params->rgrc[0].right = params->rgrc[0].left + w;
                 params->rgrc[0].bottom = params->rgrc[0].top + h;
             }