Normally the Alt key opens the menu in Windows.
I need this to be disabled, because I need Alt key for my application. (It is an emulator of old computer, so I need to m
How about checking for WM_SYSCOMMAND
, and when wParam is SC_KEYMENU
, return 0?
Update / exact solution:
if(wParam==SC_KEYMENU && (lParam>>16)<=0) return 0;
return DefWindowProc(hwnd, message, wParam, lParam);
Description: If lParam>>16
is positive then menu is activated by mouse, when it is zero or negative then menu is activated by Alt or Alt+something.