From 03578273c366872d159fd77ed53fac697d04e193 Mon Sep 17 00:00:00 2001 From: James Tabor Date: Wed, 4 Jul 2012 22:51:16 +0000 Subject: [PATCH] [Win32k] - Add zap active and focus call. Fix comments. svn path=/trunk/; revision=56831 --- reactos/win32ss/user/ntuser/event.c | 4 ++-- reactos/win32ss/user/ntuser/simplecall.c | 11 ++++++++++- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/reactos/win32ss/user/ntuser/event.c b/reactos/win32ss/user/ntuser/event.c index 66212d89469..ef10b9bce9c 100644 --- a/reactos/win32ss/user/ntuser/event.c +++ b/reactos/win32ss/user/ntuser/event.c @@ -246,8 +246,8 @@ IntNotifyWinEvent( // Must be inside the event window. if ( (pEH->eventMin <= Event) && (pEH->eventMax >= Event)) { -// If all process || all thread || other thread same process -// If ^skip own thread && ((Pid && CPid == Pid && ^skip own process) || all process) + // if all process || all thread || other thread same process + // if ^skip own thread && ((Pid && CPid == Pid && ^skip own process) || all process) if ( (!pEH->idProcess || pEH->idProcess == PtrToUint(pti->pEThread->Cid.UniqueProcess)) && (!(pEH->Flags & WINEVENT_SKIPOWNPROCESS) || pEH->head.pti->ppi != pti->ppi) && (!pEH->idThread || pEH->idThread == PtrToUint(pti->pEThread->Cid.UniqueThread)) && diff --git a/reactos/win32ss/user/ntuser/simplecall.c b/reactos/win32ss/user/ntuser/simplecall.c index f76501eedad..94a2f7dfc36 100644 --- a/reactos/win32ss/user/ntuser/simplecall.c +++ b/reactos/win32ss/user/ntuser/simplecall.c @@ -118,7 +118,16 @@ NtUserCallNoParam(DWORD Routine) RETURN( (DWORD_PTR)IntReleaseCapture()); case NOPARAM_ROUTINE_LOADUSERAPIHOOK: - RETURN(UserLoadApiHook()); + RETURN(UserLoadApiHook()); + + case NOPARAM_ROUTINE_ZAPACTIVEANDFOUS: + { + PTHREADINFO pti = PsGetCurrentThreadWin32Thread(); + ERR("Zapping the Active and Focus window out of the Queue!\n"); + pti->MessageQueue->spwndFocus = NULL; + pti->MessageQueue->spwndActive = NULL; + RETURN(0); + } default: ERR("Calling invalid routine number 0x%x in NtUserCallNoParam\n", Routine);