Skip to content

Commit

Permalink
Delegate Back To DefWindowProc
Browse files Browse the repository at this point in the history
We were not handling the event because one of the things we need to happen, ALT+F4 sending WM_CLOSE, was not happening. Since we are not handling the event, we should call DefWindowProc.
  • Loading branch information
RobertBColton committed Jun 28, 2020
1 parent e1590f8 commit 930ee6c
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions ENIGMAsystem/SHELL/Platforms/Win32/WINDOWScallback.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -200,13 +200,11 @@ namespace enigma
keybdstatus[key]=1;
if (key!=18)
{
if ((lParam&(1<<29))>0) {
if (wParam == VK_F4) PostMessage(hWnd, WM_SYSCOMMAND, SC_CLOSE, 0);
last_keybdstatus[18]=keybdstatus[18], keybdstatus[18]=1;
} else
last_keybdstatus[18]=keybdstatus[18], keybdstatus[18]=0;
if ((lParam&(1<<29))>0)
last_keybdstatus[18]=keybdstatus[18], keybdstatus[18]=1;
else last_keybdstatus[18]=keybdstatus[18], keybdstatus[18]=0;
}
return 0;
break;
}
case WM_SYSKEYUP: {
int key = enigma_user::keyboard_get_map(wParam);
Expand Down

0 comments on commit 930ee6c

Please sign in to comment.