We have to activate MDI child windows.

This commit is contained in:
Thuy Nguyen 1999-10-13 13:53:10 +00:00 committed by Alexandre Julliard
parent 8f16613b2d
commit 22614a3390
2 changed files with 4 additions and 1 deletions

View file

@ -606,6 +606,7 @@ static LONG MDI_ChildActivate( WND *clientPtr, HWND hWndChild )
if( clientInfo->hwndChildMaximized != hWndChild ) {
if( hWndChild ) {
clientInfo->hwndActiveChild = hWndChild;
clientInfo->hwndChildMaximized = hWndChild;
ShowWindow( hWndChild, SW_SHOWMAXIMIZED);
} else
ShowWindow( clientInfo->hwndActiveChild, SW_SHOWNORMAL );

View file

@ -1375,7 +1375,9 @@ BOOL WINAPI ShowWindow( HWND hwnd, INT cmd )
else
{
/* We can't activate a child window */
if (wndPtr->dwStyle & WS_CHILD) swp |= SWP_NOACTIVATE | SWP_NOZORDER;
if ((wndPtr->dwStyle & WS_CHILD) &&
!(wndPtr->dwExStyle & WS_EX_MDICHILD))
swp |= SWP_NOACTIVATE | SWP_NOZORDER;
if (!(swp & MINMAX_NOSWP))
SetWindowPos( hwnd, HWND_TOP, newPos.left, newPos.top,
newPos.right, newPos.bottom, LOWORD(swp) );