Hi Pritpal, On 2010 Jan 18, at 18:54, vouch...@users.sourceforge.net wrote:
> Revision: 13633 > > http://harbour-project.svn.sourceforge.net/harbour-project/?rev=13633&view=rev > Author: vouchcac > Date: 2010-01-18 17:54:15 +0000 (Mon, 18 Jan 2010) > > Log Message: > ----------- > 2010-01-18 09:14 UTC-0800 Pritpal Bedi (prit...@vouchcac.com) > Modified: trunk/harbour/contrib/hbqt/hbqt_base.cpp > =================================================================== > --- trunk/harbour/contrib/hbqt/hbqt_base.cpp 2010-01-18 16:03:09 UTC (rev > 13632) > +++ trunk/harbour/contrib/hbqt/hbqt_base.cpp 2010-01-18 17:54:15 UTC (rev > 13633) > @@ -78,6 +78,16 @@ > hb_retptr( object->findChild< QObject * >( hbqt_par_QString( 2 ) ) ); > } > > +HB_FUNC( HBQT_ISEMPTYQTPOINTER ) > +{ > + QGC_POINTER * p = ( QGC_POINTER * ) hb_parptrGC( hbqt_gcFuncs(), 1 ); > + > + if( p && p->ph ) > + hb_retl( false ); > + else > + hb_retl( true ); > +} Should be HB_TRUE and HB_FALSE, since they are passed to hb_retl() which is a Harbour API. > Modified: trunk/harbour/contrib/hbqt/hbqt_hbevents.cpp > =================================================================== > --- trunk/harbour/contrib/hbqt/hbqt_hbevents.cpp 2010-01-18 16:03:09 UTC > (rev 13632) > +++ trunk/harbour/contrib/hbqt/hbqt_hbevents.cpp 2010-01-18 17:54:15 UTC > (rev 13633) > + > +bool HBEvents::hbConnect( PHB_ITEM pObj, int iEvent, PHB_ITEM bBlock ) > +{ > + HB_SYMBOL_UNUSED( pObj ); > + HB_SYMBOL_UNUSED( iEvent ); > + HB_SYMBOL_UNUSED( bBlock ); > + > + QObject * object = ( QObject* ) hbqt_pPtrFromObj( 1 ); /* get > sender */ > + > + if( object ) > { > - HB_TRACE( HB_TR_DEBUG, ( "PTR_rel_HBEvents : Object not > created with - new" ) ); > - p->ph = NULL; > + PHB_ITEM codeblock = hb_itemNew( hb_param( 3, HB_IT_BLOCK | > HB_IT_BYREF ) ); > + //PHB_ITEM codeblock = hb_itemNew( bBlock ); > + > + char prop[ 20 ]; > + hb_snprintf( prop, sizeof( prop ), "%s%i%s", "P", iEvent, "P" ); /* > Make it a unique identifier */ > + > + listBlock << codeblock; > + listObj << object; /* TOFIX: Reference to GC collected > pointer is stored. */ > + > + object->setProperty( prop, ( int ) listBlock.size() ); > + > + return HB_TRUE; > } > + return HB_FALSE; Should be true and false, since the return value here is 'bool', plain C++ type. [ There may be other mis-uses, but I hope you get the general idea. ] Brgds, Viktor _______________________________________________ Harbour mailing list (attachment size limit: 40KB) Harbour@harbour-project.org http://lists.harbour-project.org/mailman/listinfo/harbour