Switch focus to activated window even if no window previously had the

focus.
This commit is contained in:
Joshua Thielen 2001-10-24 02:43:24 +00:00 committed by Alexandre Julliard
parent 51349422b9
commit e0f0a2ebbf
1 changed files with 1 additions and 1 deletions

View File

@ -1377,7 +1377,7 @@ BOOL WINPOS_SetActiveWindow( HWND hWnd, BOOL fMouse, BOOL fChangeFocus)
{ {
HWND hOldFocus = PERQDATA_GetFocusWnd( pNewActiveQueue->pQData ); HWND hOldFocus = PERQDATA_GetFocusWnd( pNewActiveQueue->pQData );
if ( hOldFocus && GetAncestor( hOldFocus, GA_ROOT ) != hwndActive ) if ( !hOldFocus || GetAncestor( hOldFocus, GA_ROOT ) != hwndActive )
FOCUS_SwitchFocus( pNewActiveQueue, hOldFocus, FOCUS_SwitchFocus( pNewActiveQueue, hOldFocus,
(wndPtr && (wndPtr->dwStyle & WS_MINIMIZE))? (wndPtr && (wndPtr->dwStyle & WS_MINIMIZE))?
0 : hwndActive ); 0 : hwndActive );