diff options
author | Jon TURNEY <jon.turney@dronecode.org.uk> | 2012-02-06 16:39:00 +0000 |
---|---|---|
committer | Jon TURNEY <jon.turney@dronecode.org.uk> | 2012-03-31 11:37:05 +0100 |
commit | 6ecb76308587874ba85e910c4b1163d365f4f37c (patch) | |
tree | 7c5b5ff0971a655b982132f8c57ca2059b82598a | |
parent | e6eb148e040597e059d9bd80d8fc988af5186acd (diff) |
Fix winUpdateWindowPosition() not to assume WS_EX_APPWINDOW style
Also improve it's debug output a bit
-rw-r--r-- | hw/xwin/winmultiwindowwm.c | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/hw/xwin/winmultiwindowwm.c b/hw/xwin/winmultiwindowwm.c index 4dc08d33c..159c27a7b 100644 --- a/hw/xwin/winmultiwindowwm.c +++ b/hw/xwin/winmultiwindowwm.c @@ -1889,13 +1889,11 @@ winUpdateWindowPosition (HWND hWnd, Bool reshape, HWND *zstyle) /* Setup a rectangle with the X window position and size */ SetRect (&rcNew, iX, iY, iX + iWidth, iY + iHeight); -#if 0 - ErrorF ("winUpdateWindowPosition - (%d, %d)-(%d, %d)\n", - rcNew.left, rcNew.top, - rcNew.right, rcNew.bottom); -#endif + winDebug("winUpdateWindowPosition - drawable extent (%d, %d)-(%d, %d)\n", + rcNew.left, rcNew.top, + rcNew.right, rcNew.bottom); - AdjustWindowRectEx (&rcNew, GetWindowLongPtr (hWnd, GWL_STYLE), FALSE, WS_EX_APPWINDOW); + AdjustWindowRectEx (&rcNew, GetWindowLongPtr (hWnd, GWL_STYLE), FALSE, GetWindowLongPtr (hWnd, GWL_EXSTYLE)); /* Don't allow window decoration to disappear off to top-left as a result of this adjustment */ if (rcNew.left < GetSystemMetrics(SM_XVIRTUALSCREEN)) @@ -1912,11 +1910,9 @@ winUpdateWindowPosition (HWND hWnd, Bool reshape, HWND *zstyle) rcNew.bottom += iDy; } -#if 0 - ErrorF ("winUpdateWindowPosition - (%d, %d)-(%d, %d)\n", - rcNew.left, rcNew.top, - rcNew.right, rcNew.bottom); -#endif + winDebug("winUpdateWindowPosition - Window extent (%d, %d)-(%d, %d)\n", + rcNew.left, rcNew.top, + rcNew.right, rcNew.bottom); /* Position the Windows window */ SetWindowPos (hWnd, *zstyle, rcNew.left, rcNew.top, |