diff options
author | Alexander Gottwald <alexander.gottwald@s1999.tu-chemnitz.de> | 2005-01-27 12:27:06 +0000 |
---|---|---|
committer | Alexander Gottwald <alexander.gottwald@s1999.tu-chemnitz.de> | 2005-01-27 12:27:06 +0000 |
commit | 9000b3c06164f9da6407c3ddee30252722e2f2bf (patch) | |
tree | 98843ba231a6b3fbdc13a54775ecc4056b0f263f | |
parent | 9f74348a3357cb5993c6c7480fcf7ad597e8c3e8 (diff) |
winmultiwindowwindow.c
Backout last change. There was a window focus regression
-rw-r--r-- | hw/xwin/ChangeLog | 6 | ||||
-rw-r--r-- | hw/xwin/winmultiwindowwindow.c | 2 | ||||
-rwxr-xr-x | hw/xwin/winmultiwindowwndproc.c | 64 |
3 files changed, 8 insertions, 64 deletions
diff --git a/hw/xwin/ChangeLog b/hw/xwin/ChangeLog index 7c1e14433..b0a80c622 100644 --- a/hw/xwin/ChangeLog +++ b/hw/xwin/ChangeLog @@ -1,3 +1,9 @@ +2005-01-27 Alexander Gottwald <ago at freedesktop dot org> + + * winmultiwindowwindow.c + * winmultiwindowwndproc.c: + Backout last change. There was a window focus regression + 2005-01-24 Alexander Gottwald <ago at freedesktop dot org> * winmultiwindowwindow.c diff --git a/hw/xwin/winmultiwindowwindow.c b/hw/xwin/winmultiwindowwindow.c index 475fa7ddc..5034ec0d6 100644 --- a/hw/xwin/winmultiwindowwindow.c +++ b/hw/xwin/winmultiwindowwindow.c @@ -571,7 +571,7 @@ winCreateWindowsWindow (WindowPtr pWin) /* Change style back to popup, already placed... */ SetWindowLong (hWnd, GWL_STYLE, WS_POPUP | WS_CLIPCHILDREN | WS_CLIPSIBLINGS); SetWindowPos (hWnd, 0, 0, 0, 0, 0, - SWP_FRAMECHANGED | SWP_NOZORDER | SWP_NOMOVE | SWP_NOSIZE | SWP_NOACTIVATE); + SWP_FRAMECHANGED | SWP_NOZORDER | SWP_NOMOVE | SWP_NOSIZE); /* Make sure it gets the proper system menu for a WS_POPUP, too */ GetSystemMenu (hWnd, TRUE); diff --git a/hw/xwin/winmultiwindowwndproc.c b/hw/xwin/winmultiwindowwndproc.c index b2038ae55..3ebd0be7d 100755 --- a/hw/xwin/winmultiwindowwndproc.c +++ b/hw/xwin/winmultiwindowwndproc.c @@ -765,7 +765,6 @@ winTopLevelWindowProc (HWND hwnd, UINT message, /* Pass the message to the root window */ SendMessage (hwndScreen, message, wParam, lParam); -#if 0 if (LOWORD(wParam) != WA_INACTIVE) { /* Raise the window to the top in Z order */ @@ -779,7 +778,6 @@ winTopLevelWindowProc (HWND hwnd, UINT message, if (!pWin || !pWin->overrideRedirect) /* for OOo menus */ winSendMessageToWM (s_pScreenPriv->pWMInfo, &wmMsg); } -#endif return 0; case WM_ACTIVATEAPP: @@ -935,7 +933,7 @@ winTopLevelWindowProc (HWND hwnd, UINT message, ErrorF ("overridden window is shown\n"); #endif SetWindowPos (hwnd, HWND_TOPMOST, 0, 0, 0, 0, - SWP_NOMOVE | SWP_NOSIZE | SWP_NOACTIVATE); + SWP_NOMOVE | SWP_NOSIZE); } /* Setup the Window Manager message */ @@ -955,7 +953,6 @@ winTopLevelWindowProc (HWND hwnd, UINT message, return ValidateSizing (hwnd, pWin, wParam, lParam); case WM_WINDOWPOSCHANGING: -#if 0 if (lParam != 0) { WINDOWPOS *windowpos = (WINDOWPOS *)lParam; @@ -992,67 +989,8 @@ winTopLevelWindowProc (HWND hwnd, UINT message, winSendMessageToWM (s_pScreenPriv->pWMInfo, &wmMsg); } } -#endif break; case WM_WINDOWPOSCHANGED: - { - LPWINDOWPOS pWinPos = (LPWINDOWPOS) lParam; - - if (!(pWinPos->flags & SWP_NOZORDER)) - { -#if CYGWINDOWING_DEBUG - winDebug ("\twindow z order was changed\n"); -#endif - if (pWinPos->hwndInsertAfter == HWND_TOP - ||pWinPos->hwndInsertAfter == HWND_TOPMOST - ||pWinPos->hwndInsertAfter == HWND_NOTOPMOST) - { -#if CYGWINDOWING_DEBUG - winDebug ("\traise to top\n"); -#endif - /* Raise the window to the top in Z order */ - wmMsg.msg = WM_WM_RAISE; - if (fWMMsgInitialized) - winSendMessageToWM (s_pScreenPriv->pWMInfo, &wmMsg); - } - else if (pWinPos->hwndInsertAfter == HWND_BOTTOM) - { - } - else - { - /* Check if this window is top of X windows. */ - HWND hWndAbove = NULL; - DWORD dwCurrentProcessID = GetCurrentProcessId (); - DWORD dwWindowProcessID = 0; - - for (hWndAbove = pWinPos->hwndInsertAfter; - hWndAbove != NULL; - hWndAbove = GetNextWindow (hWndAbove, GW_HWNDPREV)) - { - /* Ignore other XWin process's window */ - GetWindowThreadProcessId (hWndAbove, &dwWindowProcessID); - - if ((dwWindowProcessID == dwCurrentProcessID) - && GetProp (hWndAbove, WIN_WINDOW_PROP) - && !IsWindowVisible (hWndAbove) - && !IsIconic (hWndAbove) ) /* ignore minimized windows */ - break; - } - /* If this is top of X windows in Windows stack, - raise it in X stack. */ - if (hWndAbove == NULL) - { -#if CYGWINDOWING_DEBUG - winDebug ("\traise to top\n"); -#endif - /* Raise the window to the top in Z order */ - wmMsg.msg = WM_WM_RAISE; - if (fWMMsgInitialized) - winSendMessageToWM (s_pScreenPriv->pWMInfo, &wmMsg); - } - } - } - } /* * Pass the message to DefWindowProc to let the function * break down WM_WINDOWPOSCHANGED to WM_MOVE and WM_SIZE. |