Fixed iconification event for maximized windows.

master
Camilla Berglund ago%!(EXTRA string=11 years)
parent 9ec1a4361b
commit dcc78017b0
  1. 1
      src/win32_platform.h
  2. 11
      src/win32_window.c

@ -159,6 +159,7 @@ typedef struct _GLFWwindowWin32
DWORD dwExStyle;
GLboolean cursorInside;
GLboolean iconified;
// The last received cursor position, regardless of source
int cursorPosX, cursorPosY;

@ -489,10 +489,17 @@ static LRESULT CALLBACK windowProc(HWND hWnd, UINT uMsg,
updateClipRect(window);
}
if (wParam == SIZE_MINIMIZED)
if (!window->win32.iconified && wParam == SIZE_MINIMIZED)
{
window->win32.iconified = GL_TRUE;
_glfwInputWindowIconify(window, GL_TRUE);
else if (wParam == SIZE_RESTORED)
}
else if (window->win32.iconified &&
(wParam == SIZE_RESTORED || wParam == SIZE_MAXIMIZED))
{
window->win32.iconified = GL_FALSE;
_glfwInputWindowIconify(window, GL_FALSE);
}
_glfwInputFramebufferSize(window, LOWORD(lParam), HIWORD(lParam));
_glfwInputWindowSize(window, LOWORD(lParam), HIWORD(lParam));

Loading…
Cancel
Save