winkeybd.h
winkeyhook.c Make keyhook feature work in multiwindowmode too Hook windows keys
This commit is contained in:
parent
f417159e51
commit
57387e115c
|
@ -1,3 +1,11 @@
|
|||
2005-01-10 Alexander Gottwald <ago at freedesktop dot org>
|
||||
|
||||
* winkeybd.h
|
||||
* winkeyhook.c
|
||||
* winwndproc.c:
|
||||
Make keyhook feature work in multiwindowmode too
|
||||
Hook windows keys
|
||||
|
||||
2005-01-08 Alexander Gottwald <ago at freedesktop dot org>
|
||||
|
||||
* winblock.c:
|
||||
|
|
|
@ -140,9 +140,9 @@ g_iKeyMap [] = {
|
|||
/* 88 */ 0, 0, 0,
|
||||
/* 89 */ 0, 0, 0,
|
||||
/* 90 */ 0, 0, 0,
|
||||
/* 91 */ 0, 0, 0,
|
||||
/* 92 */ 0, 0, 0,
|
||||
/* 93 */ 0, 0, 0,
|
||||
/* 91 */ VK_LWIN, KEY_LMeta, 0,
|
||||
/* 92 */ VK_RWIN, KEY_RMeta, 0,
|
||||
/* 93 */ VK_APPS, KEY_Menu, 0,
|
||||
/* 94 */ 0, 0, 0,
|
||||
/* 95 */ 0, 0, 0,
|
||||
/* 96 */ 0, 0, 0,
|
||||
|
|
|
@ -65,6 +65,7 @@ winKeyboardMessageHookLL (int iCode, WPARAM wParam, LPARAM lParam)
|
|||
{
|
||||
BOOL fPassKeystroke = FALSE;
|
||||
PKBDLLHOOKSTRUCT p = (PKBDLLHOOKSTRUCT) lParam;
|
||||
HWND hwnd = GetActiveWindow();
|
||||
|
||||
/* Pass keystrokes on to our main message loop */
|
||||
if (iCode == HC_ACTION)
|
||||
|
@ -79,9 +80,7 @@ winKeyboardMessageHookLL (int iCode, WPARAM wParam, LPARAM lParam)
|
|||
case WM_KEYUP: case WM_SYSKEYUP:
|
||||
fPassKeystroke =
|
||||
((p->vkCode == VK_TAB) && ((p->flags & LLKHF_ALTDOWN) != 0))
|
||||
#if 0
|
||||
|| (p->vkCode == VK_LWIN) || (p->vkCode == VK_RWIN)
|
||||
#endif
|
||||
;
|
||||
break;
|
||||
}
|
||||
|
@ -107,7 +106,7 @@ winKeyboardMessageHookLL (int iCode, WPARAM wParam, LPARAM lParam)
|
|||
lParamKey = lParamKey | (0x80000000 & ((p->flags & LLKHF_UP) << 24));
|
||||
|
||||
/* Send message to our main window that has the keyboard focus */
|
||||
PostMessage (g_hwndKeyboardFocus,
|
||||
PostMessage (hwnd,
|
||||
(UINT) wParam,
|
||||
(WPARAM) p->vkCode,
|
||||
lParamKey);
|
||||
|
|
|
@ -1013,7 +1013,7 @@ winWindowProc (HWND hwnd, UINT message,
|
|||
* be returned to Windows. We may be able to trap the Windows keys,
|
||||
* but we should determine if that is desirable before doing so.
|
||||
*/
|
||||
if (wParam == VK_LWIN || wParam == VK_RWIN)
|
||||
if ((wParam == VK_LWIN || wParam == VK_RWIN) && !g_fKeyboardHookLL)
|
||||
break;
|
||||
|
||||
#ifdef XKB
|
||||
|
@ -1054,7 +1054,7 @@ winWindowProc (HWND hwnd, UINT message,
|
|||
* be returned to Windows. We may be able to trap the Windows keys,
|
||||
* but we should determine if that is desirable before doing so.
|
||||
*/
|
||||
if (wParam == VK_LWIN || wParam == VK_RWIN)
|
||||
if ((wParam == VK_LWIN || wParam == VK_RWIN) && !g_fKeyboardHookLL)
|
||||
break;
|
||||
|
||||
/* Ignore the fake Ctrl_L that follows an AltGr release */
|
||||
|
|
Loading…
Reference in New Issue
Block a user