-Fix sending WM_KILLFOCUS when we give focus to a window of a different thread

Fixes bugs 1546 and 1603

svn path=/trunk/; revision=47103
This commit is contained in:
Giannis Adamopoulos 2010-05-05 10:08:23 +00:00
parent 79121eccea
commit e3ce00b76b

View file

@ -227,6 +227,7 @@ co_IntSetForegroundAndFocusWindow(PWINDOW_OBJECT Window, PWINDOW_OBJECT FocusWin
if (PrevForegroundQueue != 0)
{
hWndPrev = PrevForegroundQueue->ActiveWindow;
hWndFocusPrev = PrevForegroundQueue->FocusWindow;
}
if (hWndPrev == hWnd)
@ -235,9 +236,6 @@ co_IntSetForegroundAndFocusWindow(PWINDOW_OBJECT Window, PWINDOW_OBJECT FocusWin
return TRUE;
}
hWndFocusPrev = (PrevForegroundQueue == FocusWindow->pti->MessageQueue
? FocusWindow->pti->MessageQueue->FocusWindow : NULL);
/* FIXME: Call hooks. */
co_IntSendDeactivateMessages(hWndPrev, hWnd);