Files
2025-09-29 00:52:08 +02:00

22 lines
620 B
C++
Executable File

#ifndef __INPUT_HOOK_H__
#define __INPUT_HOOK_H__
#pragma once
class InputHook
{
public:
bool Initialize();
void Remove();
typedef void(*TKeyboardFn)(DWORD key, WORD repeats, BYTE scanCode, BOOL isExtended, BOOL isWithAlt, BOOL wasDownBefore, BOOL isUpNow);
void keyboardHandlerRegister(TKeyboardFn function);
void keyboardHandlerUnregister(TKeyboardFn function);
HWND getWindow() { return hWindow; }
bool FindGameWindow();
protected:
HWND hWindow;
}; extern InputHook iHook;
static LRESULT APIENTRY WndProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam);
#endif // __INPUT_HOOK_H__