Skip to content

Commit

Permalink
Respond to WM_CLOSE as WinGUI does
Browse files Browse the repository at this point in the history
  • Loading branch information
Ray Chason authored and Ray Chason committed Feb 10, 2024
1 parent a3abc82 commit 9ff74e9
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions os2gui/pdcscrn.c
Original file line number Diff line number Diff line change
Expand Up @@ -1858,6 +1858,17 @@ static MRESULT EXPENTRY WndProc (const HWND hwnd,
}
break;

case WM_CLOSE:
if( !PDC_get_function_key( FUNCTION_KEY_SHUT_DOWN))
{
final_cleanup( );
/*PDC_bDone = TRUE;*/
exit( 0);
}
else
add_key_to_queue( PDC_get_function_key( FUNCTION_KEY_SHUT_DOWN));
return 0;

case WM_COMMAND:
case WM_SYSCOMMAND:
switch (SHORT1FROMMP(wParam))
Expand Down

0 comments on commit 9ff74e9

Please sign in to comment.