Change trigger event on Windows to KEY_DOWN

This commit is contained in:
Federico Terzi 2019-09-16 14:47:26 +02:00
parent 077bf76887
commit ce45cd1ca1

View File

@ -204,8 +204,8 @@ LRESULT CALLBACK window_procedure(HWND window, unsigned int msg, WPARAM wp, LPAR
// Convert the input data
RAWINPUT* raw = reinterpret_cast<RAWINPUT*>(lpb.data());
// Make sure it's a keyboard type event, relative to a key release.
if (raw->header.dwType == RIM_TYPEKEYBOARD && raw->data.keyboard.Message == WM_KEYUP)
// Make sure it's a keyboard type event, relative to a key press.
if (raw->header.dwType == RIM_TYPEKEYBOARD && raw->data.keyboard.Message == WM_KEYDOWN)
{
DWORD currentTick = GetTickCount();