2012-01-16 17:32 UTC-0800 Pritpal Bedi (bedipritpal@hotmail.com)

* contrib/gtwvg/gtwvg.c
  * contrib/gtwvg/gtwvg.h
  * contrib/gtwvg/hbgtwvg.ch
    + Implemented: HB_GTI_MAXIMIZABLE message.
       hb_gtInfo( HB_GTI_MAXIMIZABLE, TRUE/FALSE ) -> lPrevState
    TODO: implement in GTWVT if deemed fit.
This commit is contained in:
Pritpal Bedi
2012-01-17 01:35:26 +00:00
parent ec338e6fc0
commit fc3e2909a8
4 changed files with 36 additions and 0 deletions

View File

@@ -16,6 +16,14 @@
The license applies to all entries newer than 2009-04-28.
*/
2012-01-16 17:32 UTC-0800 Pritpal Bedi (bedipritpal@hotmail.com)
* contrib/gtwvg/gtwvg.c
* contrib/gtwvg/gtwvg.h
* contrib/gtwvg/hbgtwvg.ch
+ Implemented: HB_GTI_MAXIMIZABLE message.
hb_gtInfo( HB_GTI_MAXIMIZABLE, TRUE/FALSE ) -> lPrevState
TODO: implement in GTWVT if deemed fit.
2012-01-16 16:50 UTC-0800 Pritpal Bedi (bedipritpal@hotmail.com)
* contrib/gtwvg/gtwvg.c
+ Extended: hb_gtInfo( HB_GTI_SPEC, HB_GTS_SETPOSITION, [{x,y}] )

View File

@@ -428,6 +428,7 @@ static PHB_GTWVT hb_gt_wvt_New( PHB_GT pGT, HINSTANCE hInstance, int iCmdShow )
pWVT->bSelectCopy = HB_TRUE;
pWVT->bResizable = HB_TRUE;
pWVT->bMaximizable = HB_TRUE;
pWVT->bClosable = HB_TRUE;
{
@@ -3441,6 +3442,31 @@ static HB_BOOL hb_gt_wvt_Info( PHB_GT pGT, int iType, PHB_GT_INFO pInfo )
}
break;
}
case HB_GTI_MAXIMIZABLE:
{
pInfo->pResult = hb_itemPutL( pInfo->pResult, pWVT->bMaximizable );
if( pWVT->hWnd )
{
if( pInfo->pNewVal )
{
BOOL bMax = hb_itemGetL( pInfo->pNewVal );
HB_GTWVT_LONG_PTR style = GetWindowLongPtr( pWVT->hWnd, GWL_STYLE );
if( bMax && ( ! pWVT->bMaximizable ) )
{
style = style | WS_MAXIMIZEBOX;
}
else if( ( ! bMax ) && pWVT->bMaximizable )
{
style = style & ~WS_MAXIMIZEBOX;
}
SetWindowLongPtr( pWVT->hWnd, GWL_STYLE, style );
SetWindowPos( pWVT->hWnd, NULL, 0, 0, 0, 0,
SWP_NOACTIVATE | SWP_DRAWFRAME | SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER | SWP_DEFERERASE );
}
}
break;
}
case HB_GTI_RESIZABLE:
pInfo->pResult = hb_itemPutL( pInfo->pResult, pWVT->bResizable );
if( pInfo->pNewVal )

View File

@@ -394,6 +394,7 @@ typedef struct
HB_BOOL bBeginMarked;
HB_BOOL bResizable;
HB_BOOL bMaximizable;
HB_BOOL bSelectCopy;
void * hSelectCopy;

View File

@@ -86,6 +86,7 @@
#define HB_GTI_SETPOSANDSIZE 78
#define HB_GTI_REFRESH 79
#define HB_GTI_NOTIFIERBLOCKGUI 80
#define HB_GTI_MAXIMIZABLE 81
/* Presentation Parameters | HB_GTI_PRESPARAMS */
#define HB_GTI_PP_EXSTYLE 1