Only call ConfigureWindow from winRaiseWindow if the windows message
authorAlexander Gottwald <alexander.gottwald@s1999.tu-chemnitz.de>
Sun, 8 May 2005 21:14:55 +0000 (21:14 +0000)
committerAlexander Gottwald <alexander.gottwald@s1999.tu-chemnitz.de>
Sun, 8 May 2005 21:14:55 +0000 (21:14 +0000)
    dispatch loop is running.

hw/xwin/ChangeLog
hw/xwin/winblock.c
hw/xwin/winmultiwindowwndproc.c

index 20977ed..4f161e5 100644 (file)
@@ -1,3 +1,10 @@
+2005-05-08  Alexander Gottwald  <ago at freedesktop dot org>
+
+       * winmultiwindowwndproc.c:
+       * winblock.c:
+       Only call ConfigureWindow from winRaiseWindow if the windows
+       message dispatch loop is running.
+
 2005-05-02  Alexander Gottwald  <ago at freedesktop dot org>
 
        * winerror.c:
index 1d21faf..ec2d16e 100644 (file)
@@ -41,6 +41,8 @@ extern HWND                   g_hDlgExit;
 extern HWND                    g_hDlgAbout;
 
 
+Bool winInBlockHandler = FALSE;
+
 /* See Porting Layer Definition - p. 6 */
 void
 winBlockHandler (int nScreen,
@@ -87,6 +89,9 @@ winBlockHandler (int nScreen,
 winBlockHandler_ProcessMessages:
 #endif
 
+
+
+  winInBlockHandler = TRUE;
   /* Process all messages on our queue */
   while (PeekMessage (&msg, NULL, 0, 0, PM_REMOVE))
     {
@@ -100,4 +105,5 @@ winBlockHandler_ProcessMessages:
          DispatchMessage (&msg);
        }
     }
+  winInBlockHandler = FALSE;
 }
index 93ddcd4..56e5156 100755 (executable)
@@ -266,10 +266,11 @@ ValidateSizing (HWND hwnd, WindowPtr pWin,
 }
 
 extern Bool winInDestroyWindowsWindow;
+extern Bool winInBlockHandler; 
 static Bool winInRaiseWindow = FALSE;
 static void winRaiseWindow(WindowPtr pWin)
 {
-  if (!winInDestroyWindowsWindow && !winInRaiseWindow)
+  if (winInBlockHandler && !winInDestroyWindowsWindow && !winInRaiseWindow)
   {
     BOOL oldstate = winInRaiseWindow;
     winInRaiseWindow = TRUE;