2012-11-16 14:01 UTC+0100 Viktor Szakats (harbour syenar.net)
* src/rtl/gtwvt/gtwvt.c
* src/rtl/gtwvt/gtwvt.h
! made gfx drawing functions work again by disabling
compositing on the first drawing call
* contrib/hbodbc/hbodbc.hbp
+ enabled automatic MM after Przemek's changes.
For me however, both odbcdemo.prg and testodbc.prg
GPFs on exit. Maybe it's related to SQLDisconnect()
calls?
* contrib/hbodbc/odbc.c
! SQLALLOCENV() after my prev change to use ODBC 3 APIs
to call some weird API to avoid an error.
* contrib/hbodbc/tests/testodbc.prg
* contrib/hbodbc/todbc.prg
* disabled manual memory management hacks on
prg level
* contrib/rddsql/hbrddsql.h
* contrib/sddfb/sddfb.c
! uncrustified
* doc/howtorep.txt
+ added reference to commit.hb
* contrib/gtwvg/class.prg
* contrib/gtwvg/gtwvg.hbx
* contrib/gtwvg/menubar.prg
* contrib/gtwvg/paint.prg
* contrib/gtwvg/syswnd.prg
! fixed few casing and where it was used
* extras/gtwvw/gtwvw.hbx
* extras/gtwvw/wvt2wvw.ch
! fixed few casing and where it was used
* contrib/hbgd/gd.ch
* minor
This commit is contained in:
@@ -16,13 +16,55 @@
|
||||
The license applies to all entries newer than 2009-04-28.
|
||||
*/
|
||||
|
||||
2012-11-16 14:01 UTC+0100 Viktor Szakats (harbour syenar.net)
|
||||
* src/rtl/gtwvt/gtwvt.c
|
||||
* src/rtl/gtwvt/gtwvt.h
|
||||
! made gfx drawing functions work again by disabling
|
||||
compositing on the first drawing call
|
||||
|
||||
* contrib/hbodbc/hbodbc.hbp
|
||||
+ enabled automatic MM after Przemek's changes.
|
||||
For me however, both odbcdemo.prg and testodbc.prg
|
||||
GPFs on exit. Maybe it's related to SQLDisconnect()
|
||||
calls?
|
||||
|
||||
* contrib/hbodbc/odbc.c
|
||||
! SQLALLOCENV() after my prev change to use ODBC 3 APIs
|
||||
to call some weird API to avoid an error.
|
||||
|
||||
* contrib/hbodbc/tests/testodbc.prg
|
||||
* contrib/hbodbc/todbc.prg
|
||||
* disabled manual memory management hacks on
|
||||
prg level
|
||||
|
||||
* contrib/rddsql/hbrddsql.h
|
||||
* contrib/sddfb/sddfb.c
|
||||
! uncrustified
|
||||
|
||||
* doc/howtorep.txt
|
||||
+ added reference to commit.hb
|
||||
|
||||
* contrib/gtwvg/class.prg
|
||||
* contrib/gtwvg/gtwvg.hbx
|
||||
* contrib/gtwvg/menubar.prg
|
||||
* contrib/gtwvg/paint.prg
|
||||
* contrib/gtwvg/syswnd.prg
|
||||
! fixed few casing and where it was used
|
||||
|
||||
* extras/gtwvw/gtwvw.hbx
|
||||
* extras/gtwvw/wvt2wvw.ch
|
||||
! fixed few casing and where it was used
|
||||
|
||||
* contrib/hbgd/gd.ch
|
||||
* minor
|
||||
|
||||
2012-11-16 13:52 UTC+0200 Mindaugas Kavaliauskas (dbtopas/at/dbtopas.lt)
|
||||
* harbour/contrib/rddsql/hbrddsql.h
|
||||
* added missing constant
|
||||
|
||||
2012-11-16 13:35 UTC+0200 Mindaugas Kavaliauskas (dbtopas/at/dbtopas.lt)
|
||||
* harbour/contrib/sddfb/sddfb.c
|
||||
! added missing query execution :), multiple field type/value decoding
|
||||
! added missing query execution :), multiple field type/value decoding
|
||||
changes, etc.
|
||||
|
||||
2012-11-16 11:35 UTC+0100 Przemyslaw Czerpak (druzus/at/poczta.onet.pl)
|
||||
@@ -161,6 +203,8 @@
|
||||
|
||||
* README
|
||||
+ added some legal text from old readme under docs
|
||||
+ added notes on configuring text editors
|
||||
when used with Harbour
|
||||
|
||||
2012-11-15 23:08 UTC+0100 Viktor Szakats (harbour syenar.net)
|
||||
* doc/clipper.txt
|
||||
@@ -193,7 +237,7 @@
|
||||
* contrib/hbct/doc/en/token1.txt
|
||||
* contrib/hbct/doc/en/token2.txt
|
||||
* contrib/hbct/doc/en/trig.txt
|
||||
! some fixes to prev. (my regex is not yet perfect)
|
||||
! some fixes to prev. (my regex is not yet perfect) (it wasn't the regex)
|
||||
|
||||
2012-11-15 19:10 UTC+0100 Viktor Szakats (harbour syenar.net)
|
||||
* contrib/hbct/doc/en/*.txt
|
||||
|
||||
@@ -208,7 +208,7 @@ METHOD WvtDialog:New( nRows, nCols, cTitle, cFont, nFontHeight, nFontWidth, nFon
|
||||
::oldMenuBlock := SetKey( Wvt_SetMenuKeyEvent() )
|
||||
|
||||
::oldTooltipWidth := Wvt_GetToolTipWidth()
|
||||
::oldTooltipBkColor := Wvt_GetToolTipBKColor()
|
||||
::oldTooltipBkColor := Wvt_GetToolTipBkColor()
|
||||
::oldTooltipTextColor := Wvt_GetToolTipTextColor()
|
||||
|
||||
::nRows := nRows
|
||||
@@ -494,7 +494,6 @@ METHOD WvtDialog:Inkey()
|
||||
|
||||
IF ::oCurObj:nType == DLG_OBJ_BROWSE
|
||||
SELECT( ::oCurObj:cAlias )
|
||||
|
||||
ENDIF
|
||||
|
||||
::Eval( ::oCurObj:bOnFocus, ::oCurObj )
|
||||
@@ -914,7 +913,7 @@ METHOD WvtObject:CreatePopup()
|
||||
LOCAL i, nID
|
||||
|
||||
IF ! Empty( ::aPopup ) .AND. ::hPopup == nil
|
||||
::hPopup := Wvt_CreatePOPUPMenu()
|
||||
::hPopup := Wvt_CreatePopupMenu()
|
||||
|
||||
FOR i := 1 TO Len( ::aPopup )
|
||||
|
||||
|
||||
@@ -73,13 +73,13 @@ DYNAMIC Wvg_CheckMenuItem
|
||||
DYNAMIC Wvg_CheckRadioButton
|
||||
DYNAMIC Wvg_ChooseColor
|
||||
DYNAMIC Wvg_ChooseFont
|
||||
DYNAMIC Wvg_ChooseFont_GetLOGFont
|
||||
DYNAMIC Wvg_ChooseFont_GetLogFont
|
||||
DYNAMIC Wvg_ClearGUIObjects
|
||||
DYNAMIC Wvg_ClientToScreen
|
||||
DYNAMIC Wvg_ColorRect
|
||||
DYNAMIC Wvg_CreateBrush
|
||||
DYNAMIC Wvg_CreateMenu
|
||||
DYNAMIC Wvg_CreatePOPUPMenu
|
||||
DYNAMIC Wvg_CreatePopupMenu
|
||||
DYNAMIC Wvg_CreateToolTipWindow
|
||||
DYNAMIC Wvg_CreateWindowEx
|
||||
DYNAMIC Wvg_DefWindowProc
|
||||
@@ -209,7 +209,7 @@ DYNAMIC Wvg_TreeView_SetBkColor
|
||||
DYNAMIC Wvg_TreeView_SetLineColor
|
||||
DYNAMIC Wvg_TreeView_SetTextColor
|
||||
DYNAMIC Wvg_TreeView_ShowExpanded
|
||||
DYNAMIC Wvg_TVIS_Expanded
|
||||
DYNAMIC Wvg_TVIs_Expanded
|
||||
DYNAMIC Wvg_UpdateWindow
|
||||
DYNAMIC WvtBanner
|
||||
DYNAMIC WvtBrowse
|
||||
@@ -245,7 +245,7 @@ DYNAMIC Wvt_CreateDialogDynamic
|
||||
DYNAMIC Wvt_CreateDialogModal
|
||||
DYNAMIC Wvt_CreateFont
|
||||
DYNAMIC Wvt_CreateMenu
|
||||
DYNAMIC Wvt_CreatePOPUPMenu
|
||||
DYNAMIC Wvt_CreatePopupMenu
|
||||
DYNAMIC Wvt_DeleteMenu
|
||||
DYNAMIC Wvt_DestroyMenu
|
||||
DYNAMIC Wvt_DialogBox
|
||||
@@ -289,16 +289,16 @@ DYNAMIC Wvt_GetFontHandle
|
||||
DYNAMIC Wvt_GetFontInfo
|
||||
DYNAMIC Wvt_GetLastMenuEvent
|
||||
DYNAMIC Wvt_GetMenu
|
||||
DYNAMIC Wvt_GetOpenFilename
|
||||
DYNAMIC Wvt_GetOpenFileName
|
||||
DYNAMIC Wvt_GetPaintRect
|
||||
DYNAMIC Wvt_GetPalette
|
||||
DYNAMIC Wvt_GetRGBColor
|
||||
DYNAMIC Wvt_GetRGBColorByString
|
||||
DYNAMIC Wvt_GetSaveFilename
|
||||
DYNAMIC Wvt_GetSaveFileName
|
||||
DYNAMIC Wvt_GetScreenHeight
|
||||
DYNAMIC Wvt_GetScreenWidth
|
||||
DYNAMIC Wvt_GetTitle
|
||||
DYNAMIC Wvt_GetToolTipBKColor
|
||||
DYNAMIC Wvt_GetToolTipBkColor
|
||||
DYNAMIC Wvt_GetToolTipTextColor
|
||||
DYNAMIC Wvt_GetToolTipWidth
|
||||
DYNAMIC Wvt_GetWindowHandle
|
||||
|
||||
@@ -556,7 +556,7 @@ METHOD WvgMenu:create( oParent, aPresParams, lVisible )
|
||||
|
||||
::className := "POPUPMENU"
|
||||
|
||||
::hMenu := Wvg_CreatePOPUPMenu()
|
||||
::hMenu := Wvg_CreatePopupMenu()
|
||||
|
||||
RETURN Self
|
||||
|
||||
|
||||
@@ -471,7 +471,7 @@ cDefName: DEFAULT file name
|
||||
|
||||
Returns: If OFN_ALLOWMULTISELECT ? Array of files selected : FileName.
|
||||
*/
|
||||
FUNCTION Wvt_GetOpenFilename( hWnd, cPath, cTitle, acFilter, nFlags, cInitDir, cDefExt, nFilterIndex, cDefName )
|
||||
FUNCTION Wvt_GetOpenFileName( hWnd, cPath, cTitle, acFilter, nFlags, cInitDir, cDefExt, nFilterIndex, cDefName )
|
||||
|
||||
LOCAL cRet, aTmp, xRet, i
|
||||
|
||||
@@ -514,7 +514,7 @@ nIndex: Index position of types
|
||||
|
||||
Returns: FileName.
|
||||
*/
|
||||
FUNCTION Wvt_GetSaveFilename( hWnd, cDefName, cTitle, acFilter, nFlags, cInitDir, cDefExt, nFilterIndex )
|
||||
FUNCTION Wvt_GetSaveFileName( hWnd, cDefName, cTitle, acFilter, nFlags, cInitDir, cDefExt, nFilterIndex )
|
||||
|
||||
LOCAL cRet, aTmp, xRet, i, cPath
|
||||
|
||||
|
||||
@@ -411,7 +411,7 @@ METHOD GetWvgFont( aFont ) CLASS WvgFontDialog
|
||||
LOCAL oWvgFont
|
||||
|
||||
IF ! HB_ISARRAY( aFont )
|
||||
aFont := Wvg_ChooseFont_GetLOGFont( ::hWnd )
|
||||
aFont := Wvg_ChooseFont_GetLogFont( ::hWnd )
|
||||
ENDIF
|
||||
|
||||
oWvgFont := WvgFont():new()
|
||||
@@ -436,47 +436,47 @@ METHOD GetWvgFont( aFont ) CLASS WvgFontDialog
|
||||
*/
|
||||
CREATE CLASS WvgFont
|
||||
|
||||
VAR hFont
|
||||
VAR oPS
|
||||
VAR hdc
|
||||
VAR hFont
|
||||
VAR oPS
|
||||
VAR hdc
|
||||
|
||||
VAR familyName INIT ""
|
||||
VAR height INIT 0
|
||||
VAR nominalPointSize INIT 0
|
||||
VAR familyName INIT ""
|
||||
VAR height INIT 0
|
||||
VAR nominalPointSize INIT 0
|
||||
|
||||
VAR width INIT 0
|
||||
VAR widthClass INIT .F.
|
||||
VAR width INIT 0
|
||||
VAR widthClass INIT .F.
|
||||
|
||||
VAR bold INIT .F.
|
||||
VAR weightClass INIT FW_DONTCARE
|
||||
VAR bold INIT .F.
|
||||
VAR weightClass INIT FW_DONTCARE
|
||||
|
||||
VAR italic INIT .F.
|
||||
VAR strikeout INIT .F.
|
||||
VAR underscore INIT .F.
|
||||
VAR codePage INIT DEFAULT_CHARSET
|
||||
VAR italic INIT .F.
|
||||
VAR strikeout INIT .F.
|
||||
VAR underscore INIT .F.
|
||||
VAR codePage INIT DEFAULT_CHARSET
|
||||
|
||||
VAR FIXED INIT .F.
|
||||
VAR antiAliased INIT .F.
|
||||
VAR fixed INIT .F.
|
||||
VAR antiAliased INIT .F.
|
||||
|
||||
VAR compoundName INIT ""
|
||||
METHOD setCompoundName( cName ) INLINE ::compoundName := cName
|
||||
VAR compoundName INIT ""
|
||||
METHOD setCompoundName( cName ) INLINE ::compoundName := cName
|
||||
|
||||
VAR generic INIT .T.
|
||||
VAR generic INIT .T.
|
||||
|
||||
VAR baseLine INIT 0 READONLY
|
||||
VAR dbcs INIT .F.
|
||||
VAR kerning INIT .F.
|
||||
VAR mbcs INIT .F.
|
||||
VAR vector INIT .F.
|
||||
VAR outlined INIT .F.
|
||||
VAR baseLine INIT 0 READONLY
|
||||
VAR dbcs INIT .F.
|
||||
VAR kerning INIT .F.
|
||||
VAR mbcs INIT .F.
|
||||
VAR vector INIT .F.
|
||||
VAR outlined INIT .F.
|
||||
|
||||
VAR aFontInfo INIT {}
|
||||
VAR aFontInfo INIT {}
|
||||
|
||||
METHOD new( oPS )
|
||||
METHOD create( cFontName )
|
||||
METHOD configure( cFontName )
|
||||
METHOD list()
|
||||
METHOD createFont()
|
||||
METHOD new( oPS )
|
||||
METHOD create( cFontName )
|
||||
METHOD configure( cFontName )
|
||||
METHOD list()
|
||||
METHOD createFont()
|
||||
|
||||
DESTRUCTOR destroy()
|
||||
|
||||
|
||||
@@ -126,7 +126,7 @@
|
||||
#define gdDisposalRestoreBackground 2
|
||||
#define gdDisposalRestorePrevious 3
|
||||
|
||||
/* FSG - text alignment */
|
||||
/* Text alignment */
|
||||
#define gdAlignLeft 0
|
||||
#define gdAlignCenter 1
|
||||
#define gdAlignRight 2
|
||||
|
||||
@@ -22,8 +22,8 @@
|
||||
# Automatic memory management. Causes
|
||||
# memory corruption, so it's disabled
|
||||
# until fixed:
|
||||
#-D_HBODBC_AUTO_MM_
|
||||
#-cflag=-D_HBODBC_AUTO_MM_
|
||||
-D_HBODBC_AUTO_MM_
|
||||
-cflag=-D_HBODBC_AUTO_MM_
|
||||
|
||||
hbodbc.hbx
|
||||
|
||||
|
||||
@@ -101,7 +101,7 @@
|
||||
It does not cause any speed or memory overhead so I left it
|
||||
as example for more complicated cases and as base for some
|
||||
potential extensions. [druzus]
|
||||
*/
|
||||
*/
|
||||
|
||||
/* Required by headers on Windows */
|
||||
#if defined( HB_OS_WIN )
|
||||
@@ -252,10 +252,8 @@ static HB_GARBAGE_FUNC( hb_SQLHDBC_Mark )
|
||||
PHB_SQLHDBC pHDbc = ( PHB_SQLHDBC ) Cargo;
|
||||
|
||||
if( pHDbc->pHEnvItm )
|
||||
{
|
||||
/* mark parent item handler as used */
|
||||
hb_gcMark( pHDbc->pHEnvItm );
|
||||
}
|
||||
}
|
||||
|
||||
static const HB_GC_FUNCS s_gcSQLHDBCFuncs =
|
||||
@@ -338,10 +336,8 @@ static HB_GARBAGE_FUNC( hb_SQLHSTMT_Mark )
|
||||
PHB_SQLHSTMT pHStmt = ( PHB_SQLHSTMT ) Cargo;
|
||||
|
||||
if( pHStmt->pHDbcItm )
|
||||
{
|
||||
/* mark parent item handler as used */
|
||||
hb_gcMark( pHStmt->pHDbcItm );
|
||||
}
|
||||
}
|
||||
static const HB_GC_FUNCS s_gcSQLHSTMTFuncs =
|
||||
{
|
||||
@@ -382,14 +378,20 @@ static void hb_SQLHSTMT_stor( PHB_ITEM pHDbcItm, SQLHSTMT hStmt, int iParam )
|
||||
|
||||
HB_FUNC( SQLALLOCENV ) /* @hEnv --> nRetCode */
|
||||
{
|
||||
SQLHENV hEnv;
|
||||
SQLHENV hEnv;
|
||||
SQLRETURN result;
|
||||
|
||||
#if ODBCVER >= 0x0300
|
||||
hb_retni( SQLAllocHandle( SQL_HANDLE_ENV, SQL_NULL_HANDLE, &hEnv ) );
|
||||
result = SQLAllocHandle( SQL_HANDLE_ENV, SQL_NULL_HANDLE, &hEnv );
|
||||
|
||||
if( SQL_SUCCEEDED( result ) )
|
||||
SQLSetEnvAttr( hEnv, SQL_ATTR_ODBC_VERSION, ( SQLPOINTER ) SQL_OV_ODBC3, SQL_IS_UINTEGER );
|
||||
#else
|
||||
hb_retni( SQLAllocEnv( &hEnv ) );
|
||||
result = SQLAllocEnv( &hEnv );
|
||||
#endif
|
||||
|
||||
hb_retni( result );
|
||||
|
||||
hb_SQLHENV_stor( hEnv, 1 );
|
||||
}
|
||||
|
||||
@@ -508,7 +510,7 @@ HB_FUNC( SQLALLOCSTMT ) /* hDbc, @hStmt --> nRetCode */
|
||||
{
|
||||
if( hb_SQLHDBC_is( 1 ) )
|
||||
{
|
||||
SQLHDBC hDbc = hb_SQLHDBC_par( 1 );
|
||||
SQLHDBC hDbc = hb_SQLHDBC_par( 1 );
|
||||
SQLHSTMT hStmt;
|
||||
|
||||
#if ODBCVER >= 0x0300
|
||||
|
||||
@@ -66,7 +66,7 @@ PROCEDURE Main()
|
||||
? Str( nRows, 4 ), " row(s) affected."
|
||||
|
||||
#if defined( _HBODBC_AUTO_MM_ )
|
||||
hStmt := NIL // TOFIX: There should be no GPF even without this line
|
||||
// hStmt := NIL // TOFIX: There should be no GPF even without this line
|
||||
|
||||
SQLDisconnect( hDbc )
|
||||
#else
|
||||
|
||||
@@ -209,7 +209,7 @@ METHOD SetAutoCommit( lEnable ) CLASS TODBC
|
||||
METHOD Destroy() CLASS TODBC
|
||||
|
||||
#if defined( _HBODBC_AUTO_MM_ )
|
||||
::hStmt := NIL // TOFIX: There should be no GPF even without this line
|
||||
// ::hStmt := NIL // TOFIX: There should be no GPF even without this line
|
||||
|
||||
SQLDisconnect( ::hDbc ) // Disconnects from Driver
|
||||
|
||||
|
||||
@@ -95,7 +95,7 @@ typedef struct _SQLBASEAREA
|
||||
HB_ULONG ulRecCount; /* Total records */
|
||||
HB_ULONG ulRecMax; /* Size of pRow, pRowFlags buffer */
|
||||
|
||||
void ** pRow; /* array of native pointers or cached PHB_ITEM */
|
||||
void ** pRow; /* array of native pointers or cached PHB_ITEM */
|
||||
HB_BYTE * pRowFlags;
|
||||
|
||||
void * pRecord; /* current record */
|
||||
@@ -142,8 +142,8 @@ typedef struct _MIXKEY
|
||||
|
||||
typedef struct _MIXNODE
|
||||
{
|
||||
unsigned int Leaf;
|
||||
unsigned int KeyCount;
|
||||
unsigned int Leaf;
|
||||
unsigned int KeyCount;
|
||||
struct _MIXNODE * Parent;
|
||||
struct _MIXNODE * Child[ MIX_NODE_ORDER + 1 ];
|
||||
} MIXNODE, * PMIXNODE;
|
||||
@@ -151,8 +151,8 @@ typedef struct _MIXNODE
|
||||
|
||||
typedef struct _MIXNODELEAF
|
||||
{
|
||||
unsigned int Leaf;
|
||||
unsigned int KeyCount;
|
||||
unsigned int Leaf;
|
||||
unsigned int KeyCount;
|
||||
struct _MIXNODE * Parent;
|
||||
} MIXNODELEAF, * PMIXNODELEAF;
|
||||
|
||||
@@ -202,7 +202,6 @@ typedef struct _SQLMIXAREA
|
||||
} SQLMIXAREA, * SQLMIXAREAP;
|
||||
|
||||
|
||||
|
||||
/*
|
||||
====================================================================
|
||||
SQLDD
|
||||
|
||||
@@ -110,19 +110,21 @@ static void hb_firebirddd_init( void * cargo )
|
||||
HB_FUNC_TRANSLATE( SDDFB, SQLBASE )
|
||||
|
||||
HB_INIT_SYMBOLS_BEGIN( firebirddd__InitSymbols )
|
||||
{ "SDDFB", {HB_FS_PUBLIC|HB_FS_LOCAL}, {HB_FUNCNAME( SDDFB )}, NULL },
|
||||
{
|
||||
"SDDFB", { HB_FS_PUBLIC | HB_FS_LOCAL }, { HB_FUNCNAME( SDDFB ) }, NULL
|
||||
},
|
||||
HB_INIT_SYMBOLS_END( firebirddd__InitSymbols )
|
||||
|
||||
HB_CALL_ON_STARTUP_BEGIN( _hb_firebirddd_init_ )
|
||||
hb_vmAtInit( hb_firebirddd_init, NULL );
|
||||
hb_vmAtInit( hb_firebirddd_init, NULL );
|
||||
HB_CALL_ON_STARTUP_END( _hb_firebirddd_init_ )
|
||||
|
||||
#if defined( HB_PRAGMA_STARTUP )
|
||||
#pragma startup firebirddd__InitSymbols
|
||||
#pragma startup _hb_firebirddd_init_
|
||||
#elif defined( HB_DATASEG_STARTUP )
|
||||
#define HB_DATASEG_BODY HB_DATASEG_FUNC( firebirddd__InitSymbols ) \
|
||||
HB_DATASEG_FUNC( _hb_firebirddd_init_ )
|
||||
#define HB_DATASEG_BODY HB_DATASEG_FUNC( firebirddd__InitSymbols ) \
|
||||
HB_DATASEG_FUNC( _hb_firebirddd_init_ )
|
||||
#include "hbiniseg.h"
|
||||
#endif
|
||||
|
||||
@@ -170,10 +172,8 @@ static HB_ERRCODE fbConnect( SQLDDCONNECTION * pConnection, PHB_ITEM pItem )
|
||||
|
||||
if( isc_attach_database( status, ( short ) hb_arrayGetCLen( pItem, 5 ), hb_arrayGetCPtr( pItem, 5 ),
|
||||
&hDb, ( short ) i, parambuf ) )
|
||||
{
|
||||
/* TODO: error code in status[1]; */
|
||||
return HB_FAILURE;
|
||||
}
|
||||
pConnection->pSDDConn = hb_xgrab( sizeof( SDDCONN ) );
|
||||
( ( SDDCONN * ) pConnection->pSDDConn )->hDb = hDb;
|
||||
#if 0
|
||||
@@ -253,7 +253,7 @@ static HB_ERRCODE fbOpen( SQLBASEAREAP pArea )
|
||||
return HB_FAILURE;
|
||||
}
|
||||
|
||||
if( isc_dsql_execute( status, &hTrans, &hStmt, 1, NULL) )
|
||||
if( isc_dsql_execute( status, &hTrans, &hStmt, 1, NULL ) )
|
||||
{
|
||||
hb_errRT_FireBirdDD( EG_OPEN, ESQLDD_EXECUTE, "Execute statement failed", pArea->szQuery, ( HB_ERRCODE ) isc_sqlcode( status ) );
|
||||
isc_dsql_free_statement( status, &hStmt, DSQL_drop );
|
||||
@@ -264,11 +264,11 @@ static HB_ERRCODE fbOpen( SQLBASEAREAP pArea )
|
||||
|
||||
if( pSqlda->sqld > pSqlda->sqln )
|
||||
{
|
||||
uiFields = pSqlda->sqld;
|
||||
hb_xfree( pSqlda );
|
||||
pSqlda = ( XSQLDA * ) hb_xgrab( XSQLDA_LENGTH( uiFields ) );
|
||||
pSqlda->sqln = uiFields;
|
||||
pSqlda->version = 1;
|
||||
uiFields = pSqlda->sqld;
|
||||
hb_xfree( pSqlda );
|
||||
pSqlda = ( XSQLDA * ) hb_xgrab( XSQLDA_LENGTH( uiFields ) );
|
||||
pSqlda->sqln = uiFields;
|
||||
pSqlda->version = 1;
|
||||
|
||||
if( isc_dsql_describe( status, &hStmt, SQL_DIALECT_V5, pSqlda ) )
|
||||
{
|
||||
@@ -310,10 +310,10 @@ static HB_ERRCODE fbOpen( SQLBASEAREAP pArea )
|
||||
char * pStr;
|
||||
|
||||
pFieldInfo.uiType = HB_FT_STRING;
|
||||
pFieldInfo.uiLen = pVar->sqllen;
|
||||
pVar->sqldata = ( char* ) hb_xgrab( sizeof( char ) * pVar->sqllen + 2 );
|
||||
pFieldInfo.uiLen = pVar->sqllen;
|
||||
pVar->sqldata = ( char * ) hb_xgrab( sizeof( char ) * pVar->sqllen + 2 );
|
||||
|
||||
pStr = ( char * ) memset( hb_xgrab( pFieldInfo.uiLen ), ' ', pFieldInfo.uiLen );
|
||||
pStr = ( char * ) memset( hb_xgrab( pFieldInfo.uiLen ), ' ', pFieldInfo.uiLen );
|
||||
pItem = hb_itemPutCL( NULL, pStr, pFieldInfo.uiLen );
|
||||
hb_xfree( pStr );
|
||||
break;
|
||||
@@ -325,11 +325,11 @@ static HB_ERRCODE fbOpen( SQLBASEAREAP pArea )
|
||||
char * pStr;
|
||||
|
||||
pFieldInfo.uiType = HB_FT_VARLENGTH;
|
||||
pFieldInfo.uiLen = pVar->sqllen;
|
||||
pFieldInfo.uiLen = pVar->sqllen;
|
||||
/* pVar->sqltype = SQL_TEXT; Coercing */
|
||||
pVar->sqldata = ( char* ) hb_xgrab( sizeof( char ) * pVar->sqllen + 2 );
|
||||
pVar->sqldata = ( char * ) hb_xgrab( sizeof( char ) * pVar->sqllen + 2 );
|
||||
|
||||
pStr = ( char * ) memset( hb_xgrab( pFieldInfo.uiLen ), ' ', pFieldInfo.uiLen );
|
||||
pStr = ( char * ) memset( hb_xgrab( pFieldInfo.uiLen ), ' ', pFieldInfo.uiLen );
|
||||
pItem = hb_itemPutCL( NULL, pStr, pFieldInfo.uiLen );
|
||||
hb_xfree( pStr );
|
||||
break;
|
||||
@@ -339,72 +339,72 @@ static HB_ERRCODE fbOpen( SQLBASEAREAP pArea )
|
||||
if( pVar->sqlscale < 0 )
|
||||
{
|
||||
pFieldInfo.uiType = HB_FT_LONG;
|
||||
pFieldInfo.uiLen = 7;
|
||||
pFieldInfo.uiDec = - pVar->sqlscale;
|
||||
pFieldInfo.uiLen = 7;
|
||||
pFieldInfo.uiDec = -pVar->sqlscale;
|
||||
|
||||
pItem = hb_itemPutNDLen( NULL, 0.0, 6 - pFieldInfo.uiDec, ( int ) pFieldInfo.uiDec );
|
||||
}
|
||||
else
|
||||
{
|
||||
pFieldInfo.uiType = HB_FT_INTEGER;
|
||||
pFieldInfo.uiLen = 2;
|
||||
pFieldInfo.uiLen = 2;
|
||||
|
||||
pItem = hb_itemPutNILen( NULL, 0, 6 );
|
||||
}
|
||||
pVar->sqldata = ( char* ) hb_xgrab( sizeof( short ) );
|
||||
pVar->sqldata = ( char * ) hb_xgrab( sizeof( short ) );
|
||||
break;
|
||||
|
||||
case SQL_LONG:
|
||||
if( pVar->sqlscale < 0 )
|
||||
{
|
||||
pFieldInfo.uiType = HB_FT_LONG;
|
||||
pFieldInfo.uiLen = 12;
|
||||
pFieldInfo.uiDec = - pVar->sqlscale;
|
||||
pFieldInfo.uiLen = 12;
|
||||
pFieldInfo.uiDec = -pVar->sqlscale;
|
||||
|
||||
pItem = hb_itemPutNDLen( NULL, 0.0, 11 - pFieldInfo.uiDec, ( int ) pFieldInfo.uiDec );
|
||||
}
|
||||
else
|
||||
{
|
||||
pFieldInfo.uiType = HB_FT_INTEGER;
|
||||
pFieldInfo.uiLen = 4;
|
||||
pFieldInfo.uiLen = 4;
|
||||
|
||||
pItem = hb_itemPutNLLen( NULL, 0, 11 );
|
||||
}
|
||||
pVar->sqldata = ( char* ) hb_xgrab( sizeof( long ) );
|
||||
pVar->sqldata = ( char * ) hb_xgrab( sizeof( long ) );
|
||||
break;
|
||||
|
||||
case SQL_FLOAT:
|
||||
pFieldInfo.uiType = HB_FT_DOUBLE;
|
||||
pFieldInfo.uiLen = 8;
|
||||
pFieldInfo.uiDec = - pVar->sqlscale;
|
||||
pVar->sqldata = ( char* ) hb_xgrab( sizeof( float ) );
|
||||
pFieldInfo.uiLen = 8;
|
||||
pFieldInfo.uiDec = -pVar->sqlscale;
|
||||
pVar->sqldata = ( char * ) hb_xgrab( sizeof( float ) );
|
||||
|
||||
pItem = hb_itemPutNDLen( NULL, * ( float * ) pVar->sqldata, 20 - pFieldInfo.uiDec, pFieldInfo.uiDec );
|
||||
pItem = hb_itemPutNDLen( NULL, *( float * ) pVar->sqldata, 20 - pFieldInfo.uiDec, pFieldInfo.uiDec );
|
||||
break;
|
||||
|
||||
case SQL_DOUBLE:
|
||||
pFieldInfo.uiType = HB_FT_DOUBLE;
|
||||
pFieldInfo.uiLen = 8;
|
||||
pFieldInfo.uiDec = - pVar->sqlscale;
|
||||
pVar->sqldata = ( char* ) hb_xgrab( sizeof( double ) );
|
||||
pFieldInfo.uiLen = 8;
|
||||
pFieldInfo.uiDec = -pVar->sqlscale;
|
||||
pVar->sqldata = ( char * ) hb_xgrab( sizeof( double ) );
|
||||
|
||||
pItem = hb_itemPutNDLen( NULL, * ( float * ) pVar->sqldata, 20 - pFieldInfo.uiDec, pFieldInfo.uiDec );
|
||||
pItem = hb_itemPutNDLen( NULL, *( float * ) pVar->sqldata, 20 - pFieldInfo.uiDec, pFieldInfo.uiDec );
|
||||
break;
|
||||
|
||||
case SQL_TIMESTAMP:
|
||||
pFieldInfo.uiType = HB_FT_TIMESTAMP;
|
||||
pFieldInfo.uiLen = 8;
|
||||
pVar->sqldata = ( char* ) hb_xgrab( sizeof( ISC_TIMESTAMP ) );
|
||||
pFieldInfo.uiLen = 8;
|
||||
pVar->sqldata = ( char * ) hb_xgrab( sizeof( ISC_TIMESTAMP ) );
|
||||
|
||||
pItem = hb_itemPutTDT( NULL, 0, 0 );
|
||||
break;
|
||||
|
||||
default: /* other fields as binary string */
|
||||
pFieldInfo.uiType = HB_FT_STRING;
|
||||
pFieldInfo.uiLen = pVar->sqllen;
|
||||
pVar->sqldata = ( char* ) hb_xgrab( sizeof( char ) * pVar->sqllen );
|
||||
pFieldInfo.uiLen = pVar->sqllen;
|
||||
pVar->sqldata = ( char * ) hb_xgrab( sizeof( char ) * pVar->sqllen );
|
||||
|
||||
pItem = hb_itemNew( NULL );
|
||||
pItem = hb_itemNew( NULL );
|
||||
bError = HB_TRUE;
|
||||
break;
|
||||
}
|
||||
@@ -491,49 +491,49 @@ static HB_ERRCODE fbGoTo( SQLBASEAREAP pArea, HB_ULONG ulRecNo )
|
||||
LPFIELD pField;
|
||||
pVar = pSDDData->pSqlda->sqlvar + ui;
|
||||
|
||||
if( ( pVar->sqltype & 1 ) && ( * pVar->sqlind < 0 ) )
|
||||
if( ( pVar->sqltype & 1 ) && ( *pVar->sqlind < 0 ) )
|
||||
continue; /* NIL value */
|
||||
|
||||
pField = pArea->area.lpFields + ui;
|
||||
iType = pVar->sqltype & ~1;
|
||||
switch ( iType )
|
||||
iType = pVar->sqltype & ~1;
|
||||
switch( iType )
|
||||
{
|
||||
case SQL_TEXT:
|
||||
pItem = hb_itemPutCL( NULL, pVar->sqldata, pVar->sqllen );
|
||||
break;
|
||||
|
||||
case SQL_VARYING:
|
||||
pItem = hb_itemPutCL( NULL, pVar->sqldata + 2, * ( short * ) pVar->sqldata );
|
||||
pItem = hb_itemPutCL( NULL, pVar->sqldata + 2, *( short * ) pVar->sqldata );
|
||||
break;
|
||||
|
||||
case SQL_SHORT:
|
||||
if( pField->uiDec == 0 )
|
||||
pItem = hb_itemPutNILen( NULL, * ( short * ) pVar->sqldata, 6 );
|
||||
pItem = hb_itemPutNILen( NULL, *( short * ) pVar->sqldata, 6 );
|
||||
else
|
||||
pItem = hb_itemPutNDLen( NULL, hb_numDecConv( * ( short * ) pVar->sqldata, ( int ) pField->uiDec ),
|
||||
pItem = hb_itemPutNDLen( NULL, hb_numDecConv( *( short * ) pVar->sqldata, ( int ) pField->uiDec ),
|
||||
6 - pField->uiDec, ( int ) pField->uiDec );
|
||||
break;
|
||||
|
||||
case SQL_LONG:
|
||||
pItem = hb_itemPutNL( NULL, * ( long * ) pVar->sqldata );
|
||||
pItem = hb_itemPutNL( NULL, *( long * ) pVar->sqldata );
|
||||
if( pField->uiDec == 0 )
|
||||
pItem = hb_itemPutNLLen( NULL, * ( short * ) pVar->sqldata, 11 );
|
||||
pItem = hb_itemPutNLLen( NULL, *( short * ) pVar->sqldata, 11 );
|
||||
else
|
||||
pItem = hb_itemPutNDLen( NULL, hb_numDecConv( * ( long * ) pVar->sqldata, ( int ) pField->uiDec ),
|
||||
pItem = hb_itemPutNDLen( NULL, hb_numDecConv( *( long * ) pVar->sqldata, ( int ) pField->uiDec ),
|
||||
11 - pField->uiDec, ( int ) pField->uiDec );
|
||||
break;
|
||||
|
||||
case SQL_FLOAT:
|
||||
pItem = hb_itemPutNDLen( NULL, * ( float * ) pVar->sqldata, 20 - pField->uiDec, pField->uiDec );
|
||||
pItem = hb_itemPutNDLen( NULL, *( float * ) pVar->sqldata, 20 - pField->uiDec, pField->uiDec );
|
||||
break;
|
||||
|
||||
case SQL_DOUBLE:
|
||||
pItem = hb_itemPutNDLen( NULL, * ( double * ) pVar->sqldata, 20 - pField->uiDec, pField->uiDec );
|
||||
pItem = hb_itemPutNDLen( NULL, *( double * ) pVar->sqldata, 20 - pField->uiDec, pField->uiDec );
|
||||
break;
|
||||
|
||||
case SQL_TIMESTAMP:
|
||||
pItem = hb_itemPutTDT( NULL, (( ISC_TIMESTAMP * ) pVar->sqldata )->timestamp_date + 2400001,
|
||||
(( ISC_TIMESTAMP * ) pVar->sqldata )->timestamp_time / 10 );
|
||||
pItem = hb_itemPutTDT( NULL, ( ( ISC_TIMESTAMP * ) pVar->sqldata )->timestamp_date + 2400001,
|
||||
( ( ISC_TIMESTAMP * ) pVar->sqldata )->timestamp_time / 10 );
|
||||
break;
|
||||
|
||||
default:
|
||||
|
||||
@@ -112,6 +112,10 @@ by Viktor Szakats
|
||||
- Removed
|
||||
; Comment
|
||||
|
||||
- Best is to use commit.hb script to add new entry:
|
||||
<harbour dir>$ hbrun bin/commit.hb
|
||||
Then add the change descriptions.
|
||||
|
||||
- In case of incompatible changes, add the word 'INCOMPATIBLE' to
|
||||
the text.
|
||||
|
||||
|
||||
@@ -106,7 +106,7 @@ DYNAMIC wvw_CreateDialogDynamic
|
||||
DYNAMIC wvw_CreateDialogModal
|
||||
DYNAMIC wvw_CreateFont
|
||||
DYNAMIC wvw_CreateMenu
|
||||
DYNAMIC wvw_CreatePOPUPMenu
|
||||
DYNAMIC wvw_CreatePopupMenu
|
||||
DYNAMIC wvw_cxCreate
|
||||
DYNAMIC wvw_cxDestroy
|
||||
DYNAMIC wvw_cxEnable
|
||||
|
||||
@@ -20,7 +20,7 @@ MEMVAR _wvwtemp_
|
||||
/* ==================================================== */
|
||||
|
||||
#xtranslate Wvt_CreateMenu ( [<vlist,...>] ) => wvw_CreateMenu ( [<vlist>] )
|
||||
#xtranslate Wvt_CreatePOPUPMenu ( [<vlist,...>] ) => wvw_CreatePOPUPMenu ( [<vlist>] )
|
||||
#xtranslate Wvt_CreatePopupMenu ( [<vlist,...>] ) => wvw_CreatePopupMenu ( [<vlist>] )
|
||||
#xtranslate Wvt_AppendMenu ( [<vlist,...>] ) => wvw_AppendMenu ( [<vlist>] )
|
||||
#xtranslate Wvt_DeleteMenu ( [<vlist,...>] ) => wvw_DeleteMenu ( [<vlist>] )
|
||||
#xtranslate Wvt_DestroyMenu ( [<vlist,...>] ) => wvw_DestroyMenu ( [<vlist>] )
|
||||
@@ -163,7 +163,7 @@ MEMVAR _wvwtemp_
|
||||
#xtranslate Wvt_SetToolTipTextColor ( [<vlist,...>] ) => wvw_SetToolTipTextColor ( NIL [, <vlist>] )
|
||||
#xtranslate Wvt_SetToolTipTitle ( [<vlist,...>] ) => wvw_SetToolTipTitle ( NIL [, <vlist>] )
|
||||
#xtranslate Wvt_GetToolTipWidth ( [<vlist,...>] ) => wvw_GetToolTipWidth ( NIL [, <vlist>] )
|
||||
#xtranslate Wvt_GetToolTipBKColor ( [<vlist,...>] ) => wvw_GetToolTipBkColor ( NIL [, <vlist>] )
|
||||
#xtranslate Wvt_GetToolTipBkColor ( [<vlist,...>] ) => wvw_GetToolTipBkColor ( NIL [, <vlist>] )
|
||||
#xtranslate Wvt_GetToolTipTextColor ( [<vlist,...>] ) => wvw_GetToolTipTextColor ( NIL [, <vlist>] )
|
||||
|
||||
/* Timer functions. WARNING: WVT implementation is slightly different. */
|
||||
|
||||
@@ -386,6 +386,8 @@ static PHB_GTWVT hb_gt_wvt_New( PHB_GT pGT, HINSTANCE hInstance, int iCmdShow )
|
||||
pWVT->bResizing = HB_FALSE;
|
||||
pWVT->bAlreadySizing = HB_FALSE;
|
||||
|
||||
pWVT->bComposited = HB_FALSE;
|
||||
|
||||
return pWVT;
|
||||
}
|
||||
|
||||
@@ -750,7 +752,7 @@ static void hb_gt_wvt_FitSize( PHB_GTWVT pWVT )
|
||||
* This code never seems to get executed with "Lucida Console"
|
||||
* Width scaling with some Heights is an issue with Courier New and Terminal
|
||||
* Height scaling with some Widths is an issue with Consolas and Terminal
|
||||
* but this code lets us adjust it here and try creating the font again. [HVB]
|
||||
* but this code lets us adjust it here and try creating the font again. [HVB]
|
||||
*/
|
||||
|
||||
if( iCalcWidth == 0 && iCalcHeight == 0 )
|
||||
@@ -1041,6 +1043,7 @@ static void hb_gt_wvt_Composited( PHB_GTWVT pWVT, HB_BOOL fEnable )
|
||||
#else
|
||||
if( hb_iswinvista() && ! GetSystemMetrics( SM_REMOTESESSION ) )
|
||||
{
|
||||
pWVT->bComposited = fEnable;
|
||||
if( fEnable )
|
||||
SetWindowLongPtr( pWVT->hWnd, GWL_EXSTYLE, GetWindowLongPtr( pWVT->hWnd, GWL_EXSTYLE ) | WS_EX_COMPOSITED );
|
||||
else
|
||||
@@ -3084,6 +3087,9 @@ static int hb_gt_wvt_gfx_Primitive( PHB_GT pGT, int iType, int iTop, int iLeft,
|
||||
|
||||
if( pWVT->hWnd )
|
||||
{
|
||||
if( pWVT->bComposited )
|
||||
hb_gt_wvt_Composited( pWVT, HB_FALSE );
|
||||
|
||||
switch( iType )
|
||||
{
|
||||
case HB_GFX_ACQUIRESCREEN:
|
||||
|
||||
@@ -199,6 +199,8 @@ typedef struct
|
||||
HB_BOOL bResizing;
|
||||
HB_BOOL bAlreadySizing;
|
||||
|
||||
HB_BOOL bComposited;
|
||||
|
||||
RECT ciLast; /* need in WM_ENTERSIZEMOVE processing and hb_gt_wvt_PaintText() function [HVB] */
|
||||
|
||||
} HB_GTWVT, * PHB_GTWVT;
|
||||
|
||||
Reference in New Issue
Block a user