summaryrefslogtreecommitdiff
path: root/hw/xwin/winmultiwindowwndproc.c
diff options
context:
space:
mode:
authorColin Harrison <colin.harrison@virgin.net>2009-10-01 14:47:22 +0100
committerJon TURNEY <jon.turney@dronecode.org.uk>2009-10-14 20:28:11 +0100
commit83d120b90482d356be730f63aead0f8e44a4e846 (patch)
tree56f1f0d92b16df90977432d9b2150c3d76d993c7 /hw/xwin/winmultiwindowwndproc.c
parent78c87bdad1feab91c2a39e01513b4b0826665f06 (diff)
Xming: Fix various 'ISO C90 forbids mixed declarations and code' warnings
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Diffstat (limited to 'hw/xwin/winmultiwindowwndproc.c')
-rw-r--r--hw/xwin/winmultiwindowwndproc.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/hw/xwin/winmultiwindowwndproc.c b/hw/xwin/winmultiwindowwndproc.c
index 543a1652f..d14ceee9c 100644
--- a/hw/xwin/winmultiwindowwndproc.c
+++ b/hw/xwin/winmultiwindowwndproc.c
@@ -282,11 +282,11 @@ static void winRaiseWindow(WindowPtr pWin)
if (!winInDestroyWindowsWindow && !winInRaiseWindow)
{
BOOL oldstate = winInRaiseWindow;
+ XID vlist[1] = { 0 };
winInRaiseWindow = TRUE;
/* Call configure window directly to make sure it gets processed
* in time
*/
- XID vlist[1] = { 0 };
ConfigureWindow(pWin, CWStackMode, vlist, serverClient);
winInRaiseWindow = oldstate;
}
@@ -416,12 +416,14 @@ winTopLevelWindowProc (HWND hwnd, UINT message,
winReorderWindowsMultiWindow ();
/* Fix a 'round title bar corner background should be transparent not black' problem when first painted */
- RECT rWindow;
- HRGN hRgnWindow;
- GetWindowRect(hwnd, &rWindow);
- hRgnWindow = CreateRectRgnIndirect(&rWindow);
- SetWindowRgn (hwnd, hRgnWindow, TRUE);
- DeleteObject(hRgnWindow);
+ {
+ RECT rWindow;
+ HRGN hRgnWindow;
+ GetWindowRect(hwnd, &rWindow);
+ hRgnWindow = CreateRectRgnIndirect(&rWindow);
+ SetWindowRgn (hwnd, hRgnWindow, TRUE);
+ DeleteObject(hRgnWindow);
+ }
SetWindowLongPtr(hwnd, GWLP_USERDATA, (LONG_PTR)XMING_SIGNATURE);
@@ -897,10 +899,10 @@ winTopLevelWindowProc (HWND hwnd, UINT message,
}
else /* It is an overridden window so make it top of Z stack */
{
+ HWND forHwnd = GetForegroundWindow();
#if CYGWINDOWING_DEBUG
ErrorF ("overridden window is shown\n");
#endif
- HWND forHwnd = GetForegroundWindow();
if (forHwnd != NULL)
{
if (GetWindowLongPtr(forHwnd, GWLP_USERDATA) & (LONG_PTR)XMING_SIGNATURE)