- int addwidth = (window_rect.right - window_rect.left) - (client_rect.right - client_rect.left);
- int addheight = (window_rect.bottom - window_rect.top) - (client_rect.bottom - client_rect.top);
- SetWindowPos((HWND)hwnd, NULL, 0, 0, w + addwidth, h + addheight, SWP_NOZORDER | SWP_NOMOVE);
+ int width = (window_rect.right - window_rect.left) - (client_rect.right - client_rect.left) + w;
+ int height = (window_rect.bottom - window_rect.top) - (client_rect.bottom - client_rect.top) + h;
+ SetWindowPos((HWND)hwnd, NULL, 0, 0, width, height, SWP_NOZORDER | SWP_NOMOVE);