mirror of
https://github.com/reactos/reactos.git
synced 2024-08-08 04:08:29 +00:00
Added WH_GETMESSAGE support.
svn path=/trunk/; revision=34498
This commit is contained in:
parent
4c46f5b78e
commit
c66063fbaa
|
@ -570,7 +570,7 @@ NtUserSetWindowsHookEx(
|
||||||
/* We only (partially) support local WH_CBT hooks and
|
/* We only (partially) support local WH_CBT hooks and
|
||||||
* WH_KEYBOARD_LL/WH_MOUSE_LL hooks for now */
|
* WH_KEYBOARD_LL/WH_MOUSE_LL hooks for now */
|
||||||
if ((WH_CBT != HookId || Global)
|
if ((WH_CBT != HookId || Global)
|
||||||
&& WH_KEYBOARD_LL != HookId && WH_MOUSE_LL != HookId)
|
&& WH_KEYBOARD_LL != HookId && WH_MOUSE_LL != HookId && WH_GETMESSAGE != HookId)
|
||||||
{
|
{
|
||||||
#if 0 /* Removed to get winEmbed working again */
|
#if 0 /* Removed to get winEmbed working again */
|
||||||
UNIMPLEMENTED
|
UNIMPLEMENTED
|
||||||
|
|
|
@ -856,6 +856,10 @@ NtUserPeekMessage(PNTUSERGETMESSAGEINFO UnsafeInfo,
|
||||||
}
|
}
|
||||||
|
|
||||||
Present = co_IntPeekMessage(&Msg, hWnd, MsgFilterMin, MsgFilterMax, RemoveMsg);
|
Present = co_IntPeekMessage(&Msg, hWnd, MsgFilterMin, MsgFilterMax, RemoveMsg);
|
||||||
|
// The WH_GETMESSAGE hook enables an application to monitor messages about to
|
||||||
|
// be returned by the GetMessage or PeekMessage function.
|
||||||
|
co_HOOK_CallHooks( WH_GETMESSAGE, HC_ACTION, RemoveMsg & PM_REMOVE, (LPARAM)&Msg);
|
||||||
|
|
||||||
if (Present)
|
if (Present)
|
||||||
{
|
{
|
||||||
Info.Msg = Msg.Msg;
|
Info.Msg = Msg.Msg;
|
||||||
|
@ -1845,6 +1849,7 @@ NtUserMessageCall(
|
||||||
{
|
{
|
||||||
LRESULT lResult = 0;
|
LRESULT lResult = 0;
|
||||||
PWINDOW_OBJECT Window = NULL;
|
PWINDOW_OBJECT Window = NULL;
|
||||||
|
USER_REFERENCE_ENTRY Ref;
|
||||||
|
|
||||||
UserEnterExclusive();
|
UserEnterExclusive();
|
||||||
|
|
||||||
|
@ -1852,15 +1857,15 @@ NtUserMessageCall(
|
||||||
if (hWnd && (hWnd != INVALID_HANDLE_VALUE) && !(Window = UserGetWindowObject(hWnd)))
|
if (hWnd && (hWnd != INVALID_HANDLE_VALUE) && !(Window = UserGetWindowObject(hWnd)))
|
||||||
{
|
{
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
UserRefObjectCo(Window, &Ref);
|
||||||
switch(dwType)
|
switch(dwType)
|
||||||
{
|
{
|
||||||
case NUMC_DEFWINDOWPROC:
|
case NUMC_DEFWINDOWPROC:
|
||||||
lResult = IntDefWindowProc(Window, Msg, wParam, lParam);
|
lResult = IntDefWindowProc(Window, Msg, wParam, lParam);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
UserDerefObjectCo(Window);
|
||||||
UserLeave();
|
UserLeave();
|
||||||
return lResult;
|
return lResult;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue