Author: jimtabor
Date: Thu Jul 3 02:05:50 2008
New Revision: 34274
URL: http://svn.reactos.org/svn/reactos?rev=34274&view=rev
Log:
- Fixed an issue with Avira AntiVir Personal, reported by Christoph von Wittich.
- GetLastActivePopup is unimplemented and returns a zero. So User32 locally checks and sees the zero and passes it to win32k for processing. There an (kbug) exception is thrown.
Modified:
trunk/reactos/subsystems/win32/win32k/ntuser/window.c
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/window.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/ntuser/window.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/ntuser/window.c [iso-8859-1] Thu Jul 3 02:05:50 2008
@@ -3633,6 +3633,8 @@
}
Wnd = Window->Wnd;
+
+ if (!Wnd) return 0; // No go on zero.
if ((INT)Index >= 0)
{
Author: jimtabor
Date: Wed Jul 2 23:51:51 2008
New Revision: 34270
URL: http://svn.reactos.org/svn/reactos?rev=34270&view=rev
Log:
Bug 972:
- Fixes the problem of selecting Explorer START menu than mouse over and clicking another application.
- Doesn't fix the problem of selecting Explorer START menu than mouse over to the opened file Explorer and clicking on it.
- Why, one might ask? The file Explorer shares the same TID.
Modified:
trunk/reactos/subsystems/win32/win32k/ntuser/focus.c
Modified: trunk/reactos/subsystems/win32/win32k/ntuser/focus.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
==============================================================================
--- trunk/reactos/subsystems/win32/win32k/ntuser/focus.c [iso-8859-1] (original)
+++ trunk/reactos/subsystems/win32/win32k/ntuser/focus.c [iso-8859-1] Wed Jul 2 23:51:51 2008
@@ -96,6 +96,42 @@
MAKEWPARAM(MouseActivate ? WA_CLICKACTIVE : WA_ACTIVE,
UserGetWindowLong(hWnd, GWL_STYLE, FALSE) & WS_MINIMIZE),
(LPARAM)hWndPrev);
+
+ if (Window && hWndPrev)
+ {
+ PWINDOW_OBJECT cWindow;
+ HWND *List, *phWnd;
+ HANDLE OldTID = IntGetWndThreadId(UserGetWindowObject(hWndPrev));
+ HANDLE NewTID = IntGetWndThreadId(Window);
+
+ DPRINT("SendActiveMessage Old -> %x, New -> %x\n", OldTID, NewTID);
+
+ if (OldTID != NewTID)
+ {
+ if ((List = IntWinListChildren(UserGetWindowObject(IntGetDesktopWindow()))))
+ {
+ for (phWnd = List; *phWnd; ++phWnd)
+ {
+ cWindow = UserGetWindowObject(*phWnd);
+ if (cWindow && (IntGetWndThreadId(cWindow) == OldTID))
+ { // FALSE if the window is being deactivated,
+ // ThreadId that owns the window being activated.
+ co_IntSendMessage(*phWnd, WM_ACTIVATEAPP, FALSE, (LPARAM)NewTID);
+ }
+ }
+ for (phWnd = List; *phWnd; ++phWnd)
+ {
+ cWindow = UserGetWindowObject(*phWnd);
+ if (cWindow && (IntGetWndThreadId(cWindow) == NewTID))
+ { // TRUE if the window is being activated,
+ // ThreadId that owns the window being deactivated.
+ co_IntSendMessage(*phWnd, WM_ACTIVATEAPP, TRUE, (LPARAM)OldTID);
+ }
+ }
+ ExFreePool(List);
+ }
+ }
+ }
}
}