43#define IsWindowHotKey(pHK) ( (pHK)->pti == NULL && (pHK)->id == IDHK_WNDKEY )
57 TRACE(
"Debugger hotkeys set up! If you see this you enabled Debug Prints. Congrats!\n");
112 phkNext = pHotKey->
pNext;
115 if (pHotKey->
pWnd == pWnd)
122 pLink = &pHotKey->
pNext;
142 phkNext = pHotKey->
pNext;
145 if (pHotKey->
pti == pti)
152 pLink = &pHotKey->
pNext;
179 pHotKey = pHotKey->
pNext;
219 pHotKey =
IsHotKey(fModifiers, wVk);
241 TRACE(
"Hot key pressed (pWnd %p, id %d)\n", pHotKey->
pWnd, pHotKey->
id);
261 TRACE(
"System Hot key Id %d Key %u\n", pHotKey->
id, wVk );
283 TRACE(
"UPTM Hot key Id %d Key %u\n", pHotKey->
id, wVk );
290 pWnd = pHotKey->
pWnd;
320 TRACE(
"UPM Hot key Id %d Key %u\n", pHotKey->
id, wVk );
340 WARN(
"DefWndGetHotKey\n");
351 pHotKey = pHotKey->
pNext;
368 WARN(
"DefWndSetHotKey wParam 0x%x\n",
wParam);
389 if (pHotKey->
pWnd != pWnd)
395 pHotKey = pHotKey->
pNext;
410 pLink = &pHotKey->
pNext;
411 pHotKey = pHotKey->
pNext;
423 pHotKey->
pWnd = pWnd;
438 *pLink = pHotKey->
pNext;
462 pHotKeyThread = pWnd->
head.pti;
473 WARN(
"Hotkey already exists\n");
485 pHotKey->
pti = pHotKeyThread;
486 pHotKey->
pWnd = pWnd;
507 phkNext = pHotKey->
pNext;
510 if (pHotKey->
pWnd == pWnd && pHotKey->
id ==
id)
521 pLink = &pHotKey->
pNext;
543 TRACE(
"Enter NtUserRegisterHotKey\n");
548 WARN(
"Invalid modifiers: %x\n", fsModifiers);
570 WARN(
"Must be from the same Thread.\n");
578 TRACE(
"Leave NtUserRegisterHotKey, ret=%i\n", bRet);
589 TRACE(
"Enter NtUserUnregisterHotKey\n");
599 TRACE(
"Leave NtUserUnregisterHotKey, ret=%i\n", bRet);
#define DBG_DEFAULT_CHANNEL(ch)
#define ERROR_NOT_ENOUGH_MEMORY
static void cleanup(void)
#define ExAllocatePoolWithTag(hernya, size, tag)
PUSER_MESSAGE_QUEUE gpqForeground
HWND FASTCALL UserGetForegroundWindow(VOID)
#define UserHMGetHandle(obj)
#define ExFreePoolWithTag(_P, _T)
#define ENHANCED_KEYBOARD(Id)
PVOID NTAPI PsGetCurrentThreadWin32Thread(VOID)
PWINSTATION_OBJECT InputWindowStation
VOID FASTCALL UserLeave(VOID)
VOID FASTCALL UserEnterExclusive(VOID)
KEYBOARD_ID KeyboardIdentifier
PWND FASTCALL UserGetWindowObject(HWND hWnd)
#define ValidateHwndNoErr(hwnd)
VOID co_IntShellHookNotify(WPARAM Message, WPARAM wParam, LPARAM lParam)
BOOL APIENTRY NtUserUnregisterHotKey(HWND hWnd, int id)
BOOL FASTCALL UserRegisterHotKey(PWND pWnd, int id, UINT fsModifiers, UINT vk)
static PHOT_KEY FASTCALL IsHotKey(UINT fsModifiers, WORD wVk)
BOOL NTAPI co_UserProcessHotKeys(WORD wVk, BOOL bIsDown)
BOOL APIENTRY NtUserRegisterHotKey(HWND hWnd, int id, UINT fsModifiers, UINT vk)
UINT FASTCALL DefWndGetHotKey(PWND pWnd)
VOID FASTCALL UnregisterThreadHotKeys(PTHREADINFO pti)
VOID FASTCALL SetDebugHotKeys(VOID)
static UCHAR IntSwapModHKF(UINT Input)
#define IsWindowHotKey(pHK)
static UINT FASTCALL IntGetModifiers(PBYTE pKeyState)
VOID FASTCALL UnregisterWindowHotKeys(PWND pWnd)
INT FASTCALL DefWndSetHotKey(PWND pWnd, WPARAM wParam)
BOOL FASTCALL UserUnregisterHotKey(PWND pWnd, int id)
BOOL FASTCALL UserPostMessage(HWND Wnd, UINT Msg, WPARAM wParam, LPARAM lParam)
BOOL FASTCALL UserPostThreadMessage(PTHREADINFO pti, UINT Msg, WPARAM wParam, LPARAM lParam)
ENGAPI VOID APIENTRY EngSetLastError(_In_ ULONG iError)
#define ERROR_WINDOW_OF_OTHER_THREAD
#define ERROR_HOTKEY_ALREADY_REGISTERED
#define ERROR_INVALID_FLAGS