How can a Win32 application respond to only the first WM_KEYDOWN notification? The MSDN docs claim bit 30 "Specifies the previous key state. The value is 1 if the key is down before the message is sent, or it is zero if the key is up." but bit 30 is always 0 in my WndProc.
case WM_KEYDOWN:
// ToDo - stop multiple notifications for repeating keys
printf("WM_KEYDOWN %i %i", wParam, lParam & 30);
return 0;
Is lParam & 30 the wrong way to ask for this? Am I doing something else wrong?