--- a/WinWorkstation.st Mon Nov 25 17:45:15 2013 +0100
+++ b/WinWorkstation.st Tue Nov 26 20:20:32 2013 +0100
@@ -557,6 +557,7 @@
# define NDPRINTF2(x) { if (__debugNative__ > 1) console_printf x;}
# define DDPRINTF(x) { if (__debug__ & 2) console_printf x;}
# define DDDPRINTF(x) { if (__debug__ & 4) console_printf x;}
+# define DDDDPRINTF(x) { if (__debug__ & 16) console_printf x;}
# define BMDPRINTF(x) { if (__debug__ & 2) console_printf x;}
# define EVENT_PRINTF(x) { if (__debug__ & 8) console_printf x;}
# define EVENT_PRINTF2(x) { if (__debug__ & 4) console_printf x;}
@@ -577,6 +578,7 @@
# define NDPRINTF2(x) /* */
# define DDPRINTF(x) /* */
# define DDDPRINTF(x) /* */
+# define DDDDPRINTF(x) /* */
# define BMDPRINTF(x) /* */
# define EVENT_PRINTF(x) /* */
# define EVENT_PRINTF2(x) /* */
@@ -2246,7 +2248,7 @@
console_fprintf(stderr, "WinWorkstation [info]: errregion\n");
return -1;
case NULLREGION:
- DDPRINTF(("nullregion\n"));
+ DDDDPRINTF(("nullregion\n"));
_DeleteObject(updRgn, __LINE__);
return 0;
case SIMPLEREGION:
@@ -2266,7 +2268,7 @@
/* ok, got the region */
numRects = data.rgnData.rdh.nCount;
pRect = (RECT *)(data.rgnData.Buffer);
- DDPRINTF(("region numRects=%d\n", numRects));
+ DDDDPRINTF(("region numRects=%d\n", numRects));
} else {
/* a big region ... */
GetRgnBox(updRgn, &updRect);
@@ -2966,6 +2968,19 @@
EVENT_PRINTF((" client rect now: %d/%d %d/%d\n",x, y, w, h));
} /* __debug__ */
+#ifdef THIS_IS_WRONG
+ if (!(wp->flags & SWP_NOSIZE)) {
+ EVENT_PRINTF(("w,h: %d/%d vs. %d/%d\n", wp->cx, wp->cy, w, h));
+ w = wp->cx;
+ h = wp->cy;
+ }
+ if (!(wp->flags & SWP_NOMOVE)) {
+ EVENT_PRINTF(("x,y: %d/%d vs. %d/%d\n", wp->x, wp->y, x, y));
+ x = wp->x;
+ y = wp->y;
+ }
+#endif
+ lastPos_win = 0;
if ((w == 0) && (h == 0)) {
EVENT_PRINTF(("w,h = 0.\n"));
@@ -2974,7 +2989,6 @@
SetWindow_iconified(hWnd, 1);
DPRINTF(("WM_WINDOWPOSCHANGED to iconified (flags:0x%x)\n", wp->flags));
enqEvent(0, hWnd, __WM_ICONIFIED, 1, 0, 0, 0, 0, EV_NOTIME);
-
}
} else {
if (GetWindow_iconified(hWnd)) {
@@ -2993,7 +3007,6 @@
* This allows the backend to ignore
* intermediate events.
*/
- lastPos_win = 0;
lastPos_w = w;
lastPos_h = h;
lastPos_x = x;
@@ -3101,6 +3114,8 @@
case WM_SIZE:
DPRINTFIF(__debug_WM_SIZE__ , ("WM_SIZE\n"));
+
+ lastPos_win = 0;
/*
* ignore child window messages ...
*/
@@ -3147,7 +3162,6 @@
* This allows the backend to ignore
* intermediate events.
*/
- lastPos_win = 0;
lastPos_w = w;
lastPos_h = h;
lastPos_x = x;
@@ -4704,7 +4718,7 @@
ReleaseCapture();
}
if (msg.lParam) {
- DDPRINTF(("threadSetCursor %x\n",msg.lParam));
+ DDDDPRINTF(("threadSetCursor %x\n",msg.lParam));
SetCursor((HCURSOR)msg.lParam);
}
continue;
@@ -8086,7 +8100,7 @@
}
if (GetObject(hBitmap, sizeof(bitmap), &bitmap)) {
- DDPRINTF(("bitmap info:%d\n", bitmap.bmBitsPixel));
+ DDDDPRINTF(("bitmap info:%d\n", bitmap.bmBitsPixel));
} else {
DPRINTF(("noinfo returned for bitmap\n"));
/* mhmh - can this happen ? */
@@ -8207,7 +8221,7 @@
__cnt_bitmap++;
RES_BMP_PRINTF(("CreateBitmap %x %d\n",newBitmapHandle,__cnt_bitmap));
#endif
- DDPRINTF(("returning bitmap %x ...\n", newBitmapHandle));
+ DDDDPRINTF(("returning bitmap %x ...\n", newBitmapHandle));
if (allocatedBits) {
free(allocatedBits);
}
@@ -10524,7 +10538,7 @@
w = __intVal(width);
h = __intVal(height);
- DDPRINTF(("displayRectangle: %d/%d -> %d/%d\n",
+ DDDDPRINTF(("displayRectangle: %d/%d -> %d/%d\n",
xL, yT, w, h));
if ((w >= 0) && (h >= 0)) {
@@ -11022,7 +11036,7 @@
if (! gcData )
goto fail;
hDC = _getDC(gcData);
- DDPRINTF(("hDC = %x\n", hDC));
+ DDDDPRINTF(("hDC = %x\n", hDC));
if (_padd != WIN32PADDING) {
int row, col;
@@ -12756,7 +12770,7 @@
%{ /* NOCONTEXT */
- DDPRINTF(("eventsPending mask %x - not implemented\n", __intVal(anEventMask)));
+ DDDPRINTF(("eventsPending mask %x - not implemented\n", __intVal(anEventMask)));
%}.
^ false
!
@@ -19315,11 +19329,11 @@
!WinWorkstation class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libview/WinWorkstation.st,v 1.477 2013-05-27 09:30:04 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libview/WinWorkstation.st,v 1.478 2013-11-26 19:20:32 cg Exp $'
!
version_CVS
- ^ '$Header: /cvs/stx/stx/libview/WinWorkstation.st,v 1.477 2013-05-27 09:30:04 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libview/WinWorkstation.st,v 1.478 2013-11-26 19:20:32 cg Exp $'
! !