Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Close Win32 Window Properly in WGL Example #504

Merged
merged 1 commit into from
Jan 25, 2025
Merged

Conversation

carsonalh
Copy link
Contributor

The created window in this example would not close when the 'x' button was pressed. Fixed the handling of WM_CLOSE and WM_QUIT to be DestroyWindow(hWnd) instead of PostQuitMessage(0).

Source: https://learn.microsoft.com/en-us/windows/win32/learnwin32/closing-the-window .

Window did not respond properly to closing via the 'x' button.  Tested
on Windows 10.
@Dav1dde Dav1dde merged commit 7acc116 into Dav1dde:glad2 Jan 25, 2025
1 check failed
@Dav1dde
Copy link
Owner

Dav1dde commented Jan 25, 2025

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants