- Fix CORE-1161 and CORE-6651.
- Minor fixups.

svn path=/trunk/; revision=61142
This commit is contained in:
James Tabor
2013-11-29 03:43:41 +00:00
parent f520777963
commit 2f7e31bc07
3 changed files with 37 additions and 4 deletions
+10 -2
View File
@@ -518,8 +518,16 @@ IntSetFocusMessageQueue(PUSER_MESSAGE_QUEUE NewQueue)
gpqForegroundPrev = Old;
}
// Only one Q can have active foreground even when there are more than one desktop.
if (NewQueue) gpqForeground = pdo->ActiveMessageQueue;
else gpqForeground = NULL;
if (NewQueue)
{
gpqForeground = pdo->ActiveMessageQueue;
}
else
{
gpqForeground = NULL;
ERR("ptiLastInput is CLEARED!!\n");
ptiLastInput = NULL; // ReactOS hacks,,,, should check for process death.
}
}
PWND FASTCALL
+26 -1
View File
@@ -138,6 +138,31 @@ co_IntSendActivateMessages(PWND WindowPrev, PWND Window, BOOL MouseActivate, BOO
}
}
////
//// CORE-1161 and CORE-6651
if (Window->spwndPrev)
{
HWND *phwndTopLevel, *phwndCurrent;
PWND pwndCurrent, pwndDesktop;
pwndDesktop = UserGetDesktopWindow();
if (Window->spwndParent == pwndDesktop )
{
phwndTopLevel = IntWinListChildren(pwndDesktop);
phwndCurrent = phwndTopLevel;
while(*phwndCurrent)
{
pwndCurrent = UserGetWindowObject(*phwndCurrent);
if (pwndCurrent && pwndCurrent->spwndOwner == Window )
{
co_WinPosSetWindowPos(pwndCurrent, HWND_TOP, 0, 0, 0, 0, SWP_NOSIZE|SWP_NOMOVE|SWP_NOACTIVATE);
}
phwndCurrent++;
}
ExFreePool(phwndTopLevel);
}
}
////
OldTID = WindowPrev ? IntGetWndThreadId(WindowPrev) : NULL;
NewTID = IntGetWndThreadId(Window);
ptiOld = WindowPrev ? WindowPrev->head.pti : NULL;
@@ -184,7 +209,7 @@ co_IntSendActivateMessages(PWND WindowPrev, PWND Window, BOOL MouseActivate, BOO
}
}
}
ExFreePool(List);//ExFreePoolWithTag(List, USERTAG_WINDOWLIST);
ExFreePoolWithTag(List, USERTAG_WINDOWLIST);
}
}
if (WindowPrev)
+1 -1
View File
@@ -359,7 +359,7 @@ done:
//ERR("WinPosActivateOtherWindow Set Active 0x%p\n",WndTo);
if (!co_IntSetActiveWindow(WndTo,FALSE,TRUE,FALSE)) /* Ok for WndTo to be NULL here */
{
co_IntSetActiveWindow(0,FALSE,TRUE,FALSE);
co_IntSetActiveWindow(NULL,FALSE,TRUE,FALSE);
}
if (WndTo) UserDerefObjectCo(WndTo);
}