Update of /cvsroot/htoolkit/port/src/cbits/Win32
In directory sc8-pr-cvs1:/tmp/cvs-serv28211/src/cbits/Win32
Modified Files:
Window.c
Log Message:
bugfixes
Index: Window.c
===================================================================
RCS file: /cvsroot/htoolkit/port/src/cbits/Win32/Window.c,v
retrieving revision 1.53
retrieving revision 1.54
diff -C2 -d -r1.53 -r1.54
*** Window.c 10 Oct 2003 13:15:30 -0000 1.53
--- Window.c 10 Oct 2003 22:30:41 -0000 1.54
***************
*** 40,44 ****
while (hCtrl)
{
! if (GetWindowLong(hWnd,GWL_STYLE) & WS_VISIBLE)
{
GetWindowRect(hCtrl,&rect);
--- 40,44 ----
while (hCtrl)
{
! if (GetWindowLong(hCtrl,GWL_STYLE) & WS_VISIBLE)
{
GetWindowRect(hCtrl,&rect);
***************
*** 68,72 ****
// fill background for all windows except GroupBox
! if (_stricmp(buffer, "HGROUPBOX") != 0 && (GetWindowLong(hWnd,GWL_STYLE) & WS_VISIBLE))
{
GetWindowRect(hCtrl,&rect);
--- 68,72 ----
// fill background for all windows except GroupBox
! if (_stricmp(buffer, "HGROUPBOX") != 0 && (GetWindowLong(hCtrl,GWL_STYLE) & WS_VISIBLE))
{
GetWindowRect(hCtrl,&rect);
***************
*** 827,831 ****
"HCOMPOUND",
NULL,
! WS_CHILD | WS_BORDER | WS_VISIBLE | WS_HSCROLL | WS_VSCROLL,
0,0,0,0,
form,
--- 827,831 ----
"HCOMPOUND",
NULL,
! WS_CHILD | WS_BORDER | WS_HSCROLL | WS_VSCROLL,
0,0,0,0,
form,
***************
*** 1217,1221 ****
void osSetControlVisible(WindowHandle ctrl, BOOL visible)
{
! SetWindowLong(ctrl, GWL_STYLE, GetWindowLong(ctrl, GWL_STYLE) | WS_VISIBLE);
}
--- 1217,1234 ----
void osSetControlVisible(WindowHandle ctrl, BOOL visible)
{
! RECT rect;
! HWND hParent;
! LONG lStyle;
!
! lStyle = GetWindowLong(ctrl, GWL_STYLE);
! lStyle = visible ? (lStyle | WS_VISIBLE) : (lStyle & ~WS_VISIBLE);
! SetWindowLong(ctrl, GWL_STYLE, lStyle);
!
! hParent = GetParent(ctrl);
!
! GetWindowRect(ctrl, &rect);
! ScreenToClient(hParent, ((LPPOINT) &rect) );
! ScreenToClient(hParent, ((LPPOINT) &rect)+1);
! InvalidateRect(GetParent(ctrl),&rect,FALSE);
}
|