2012-06-20 18:44 UTC-0800 Pritpal Bedi (bedipritpal@hotmail.com)

* contrib/hbqt/qtcore/qth/QDataStream.qth
  * contrib/hbqt/qtcore/qth/QEventLoop.qth
  * contrib/hbqt/qtcore/qth/QResource.qth
  * contrib/hbqt/qtcore/qth/QSettings.qth
  * contrib/hbqt/qtgui/qth/QCompleter.qth
  * contrib/hbqt/qtgui/qth/QFontDialog.qth
  * contrib/hbqt/qtgui/qth/QFontMetrics.qth
  * contrib/hbqt/qtgui/qth/QFontMetricsF.qth
  * contrib/hbqt/qtgui/qth/QGraphicsLinearLayout.qth
  * contrib/hbqt/qtgui/qth/QGraphicsProxyWidget.qth
  * contrib/hbqt/qtgui/qth/QGraphicsView.qth
  * contrib/hbqt/qtgui/qth/QSlider.qth
  * contrib/hbqt/qtgui/qth/QSystemTrayIcon.qth
  * contrib/hbqt/qtgui/qth/QWindowStateChangeEvent.qth
    ! Fixed: wrong "else if" in constructors. 
       Now all classes has been scanned for this regression.
       Please report if you find something weired still.
This commit is contained in:
Pritpal Bedi
2012-06-21 01:51:06 +00:00
parent 876106d3ef
commit 7065ffaa42
15 changed files with 59 additions and 43 deletions

View File

@@ -16,6 +16,25 @@
The license applies to all entries newer than 2009-04-28.
*/
2012-06-20 18:44 UTC-0800 Pritpal Bedi (bedipritpal@hotmail.com)
* contrib/hbqt/qtcore/qth/QDataStream.qth
* contrib/hbqt/qtcore/qth/QEventLoop.qth
* contrib/hbqt/qtcore/qth/QResource.qth
* contrib/hbqt/qtcore/qth/QSettings.qth
* contrib/hbqt/qtgui/qth/QCompleter.qth
* contrib/hbqt/qtgui/qth/QFontDialog.qth
* contrib/hbqt/qtgui/qth/QFontMetrics.qth
* contrib/hbqt/qtgui/qth/QFontMetricsF.qth
* contrib/hbqt/qtgui/qth/QGraphicsLinearLayout.qth
* contrib/hbqt/qtgui/qth/QGraphicsProxyWidget.qth
* contrib/hbqt/qtgui/qth/QGraphicsView.qth
* contrib/hbqt/qtgui/qth/QSlider.qth
* contrib/hbqt/qtgui/qth/QSystemTrayIcon.qth
* contrib/hbqt/qtgui/qth/QWindowStateChangeEvent.qth
! Fixed: wrong "else if" in constructors.
Now all classes has been scanned for this regression.
Please report if you find something weired still.
2012-06-20 17:27 UTC-0800 Pritpal Bedi (bedipritpal@hotmail.com)
* contrib/hbqt/qtcore/hbqt_bind.cpp
* contrib/hbqt/qtcore/qth/QLibraryInfo.qth

View File

@@ -39,7 +39,7 @@ HB_FUNC( QT_QDATASTREAM )
{
__HB_RETPTRGC__( new QDataStream( *hbqt_par_QByteArray( 1 ) ) );
}
if( hb_pcount() == 2 && hbqt_par_isDerivedFrom( 1, "QBYTEARRAY" ) && HB_ISNUM( 2 ) )
else if( hb_pcount() == 2 && hbqt_par_isDerivedFrom( 1, "QBYTEARRAY" ) && HB_ISNUM( 2 ) )
{
__HB_RETPTRGC__( new QDataStream( hbqt_par_QByteArray( 1 ), ( QIODevice::OpenMode ) hb_parni( 2 ) ) );
}

View File

@@ -27,17 +27,14 @@ New = pObject
*/
HB_FUNC( QT_QEVENTLOOP )
{
if( hb_pcount() >= 0 )
if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QOBJECT" ) )
{
if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QOBJECT" ) )
{
__HB_RETPTRGC__( new QEventLoop( hbqt_par_QObject( 1 ) ) );
}
else
{
__HB_RETPTRGC__( new QEventLoop( 0 ) );
}
__HB_RETPTRGC__( new QEventLoop( hbqt_par_QObject( 1 ) ) );
}
else
{
__HB_RETPTRGC__( new QEventLoop( 0 ) );
}
}
</CODE>

View File

@@ -36,7 +36,7 @@ HB_FUNC( QT_QRESOURCE )
__HB_RETPTRGC__( new QResource( hb_parstr_utf8( 1, &pText01, NULL ), *hbqt_par_QLocale( 2 ) ) );
hb_strfree( pText01 );
}
if( hb_pcount() == 1 && HB_ISCHAR( 1 ) )
else if( hb_pcount() == 1 && HB_ISCHAR( 1 ) )
{
void * pText01 = NULL;
__HB_RETPTRGC__( new QResource( hb_parstr_utf8( 1, &pText01, NULL ), QLocale() ) );

View File

@@ -39,7 +39,7 @@ HB_FUNC( QT_QSETTINGS )
hb_strfree( pText01 );
hb_strfree( pText02 );
}
if( hb_pcount() == 2 && HB_ISCHAR( 1 ) && HB_ISCHAR( 2 ) )
else if( hb_pcount() == 2 && HB_ISCHAR( 1 ) && HB_ISCHAR( 2 ) )
{
void * pText01 = NULL;
void * pText02 = NULL;

View File

@@ -32,19 +32,19 @@ HB_FUNC( QT_QCOMPLETER )
{
__HB_RETPTRGC__( new QCompleter( hbqt_par_QObject( 1 ) ) );
}
if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QABSTRACTITEMMODEL" ) )
else if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QABSTRACTITEMMODEL" ) )
{
__HB_RETPTRGC__( new QCompleter( hbqt_par_QAbstractItemModel( 1 ) ) );
}
if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QSTRINGLIST" ) )
else if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QSTRINGLIST" ) )
{
__HB_RETPTRGC__( new QCompleter( *hbqt_par_QStringList( 1 ) ) );
}
if( hb_pcount() == 2 && hbqt_par_isDerivedFrom( 1, "QABSTRACTITEMMODEL" ) && hbqt_par_isDerivedFrom( 2, "QOBJECT" ) )
else if( hb_pcount() == 2 && hbqt_par_isDerivedFrom( 1, "QABSTRACTITEMMODEL" ) && hbqt_par_isDerivedFrom( 2, "QOBJECT" ) )
{
__HB_RETPTRGC__( new QCompleter( hbqt_par_QAbstractItemModel( 1 ), hbqt_par_QObject( 2 ) ) );
}
if( hb_pcount() == 2 && hbqt_par_isDerivedFrom( 1, "QSTRINGLIST" ) && hbqt_par_isDerivedFrom( 2, "QOBJECT" ) )
else if( hb_pcount() == 2 && hbqt_par_isDerivedFrom( 1, "QSTRINGLIST" ) && hbqt_par_isDerivedFrom( 2, "QOBJECT" ) )
{
__HB_RETPTRGC__( new QCompleter( *hbqt_par_QStringList( 1 ), hbqt_par_QObject( 2 ) ) );
}

View File

@@ -30,7 +30,7 @@ HB_FUNC( QT_QFONTDIALOG )
{
__HB_RETPTRGC__( new QFontDialog( hbqt_par_QWidget( 1 ) ) );
}
if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QFONT" ) )
else if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QFONT" ) )
{
__HB_RETPTRGC__( new QFontDialog( *hbqt_par_QFont( 1 ) ) );
}

View File

@@ -35,7 +35,7 @@ HB_FUNC( QT_QFONTMETRICS )
{
__HB_RETPTRGC__( new QFontMetrics( *hbqt_par_QFontMetrics( 1 ) ) );
}
if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QFONT" ) )
else if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QFONT" ) )
{
__HB_RETPTRGC__( new QFontMetrics( *hbqt_par_QFont( 1 ) ) );
}

View File

@@ -36,11 +36,11 @@ HB_FUNC( QT_QFONTMETRICSF )
{
__HB_RETPTRGC__( new QFontMetricsF( *hbqt_par_QFontMetrics( 1 ) ) );
}
if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QFONTMETRICSF" ) )
else if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QFONTMETRICSF" ) )
{
__HB_RETPTRGC__( new QFontMetricsF( *hbqt_par_QFontMetricsF( 1 ) ) );
}
if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QFONT" ) )
else if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QFONT" ) )
{
__HB_RETPTRGC__( new QFontMetricsF( *hbqt_par_QFont( 1 ) ) );
}

View File

@@ -29,22 +29,22 @@ New =
*/
HB_FUNC( QT_QGRAPHICSLINEARLAYOUT )
{
if( hb_pcount() == 1 && HB_ISNUM( 1 ) )
{
__HB_RETPTRGC__( new QGraphicsLinearLayout( ( Qt::Orientation ) hb_parni( 1 ) ) );
}
else if( hb_pcount() == 2 && HB_ISNUM( 1 ) && hbqt_par_isDerivedFrom( 2, "QGRAPHICSLAYOUTITEM" ) )
{
__HB_RETPTRGC__( new QGraphicsLinearLayout( ( Qt::Orientation ) hb_parni( 1 ), hbqt_par_QGraphicsLayoutItem( 2 ) ) );
}
else if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QGRAPHICSLAYOUTITEM" ) )
{
__HB_RETPTRGC__( new QGraphicsLinearLayout( hbqt_par_QGraphicsLayoutItem( 1 ) ) );
}
else
{
__HB_RETPTRGC__( new QGraphicsLinearLayout() );
}
if( hb_pcount() == 1 && HB_ISNUM( 1 ) )
{
__HB_RETPTRGC__( new QGraphicsLinearLayout( ( Qt::Orientation ) hb_parni( 1 ) ) );
}
else if( hb_pcount() == 2 && HB_ISNUM( 1 ) && hbqt_par_isDerivedFrom( 2, "QGRAPHICSLAYOUTITEM" ) )
{
__HB_RETPTRGC__( new QGraphicsLinearLayout( ( Qt::Orientation ) hb_parni( 1 ), hbqt_par_QGraphicsLayoutItem( 2 ) ) );
}
else if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QGRAPHICSLAYOUTITEM" ) )
{
__HB_RETPTRGC__( new QGraphicsLinearLayout( hbqt_par_QGraphicsLayoutItem( 1 ) ) );
}
else
{
__HB_RETPTRGC__( new QGraphicsLinearLayout() );
}
}
</CODE>

View File

@@ -32,7 +32,7 @@ HB_FUNC( QT_QGRAPHICSPROXYWIDGET )
{
__HB_RETPTRGC__( new QGraphicsProxyWidget( hbqt_par_QGraphicsItem( 1 ) ) );
}
if( hb_pcount() == 2 && hbqt_par_isDerivedFrom( 1, "QWIDGET" ) && HB_ISNUM( 2 ) )
else if( hb_pcount() == 2 && hbqt_par_isDerivedFrom( 1, "QWIDGET" ) && HB_ISNUM( 2 ) )
{
__HB_RETPTRGC__( new QGraphicsProxyWidget( hbqt_par_QGraphicsItem( 1 ), ( Qt::WindowFlags ) hb_parni( 2 ) ) );
}

View File

@@ -33,7 +33,7 @@ HB_FUNC( QT_QGRAPHICSVIEW )
{
__HB_RETPTRGC__( new QGraphicsView( hbqt_par_QGraphicsScene( 1 ), hbqt_par_QWidget( 2 ) ) );
}
if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QGRAPHICSSCENE" ) )
else if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QGRAPHICSSCENE" ) )
{
__HB_RETPTRGC__( new QGraphicsView( hbqt_par_QGraphicsScene( 1 ), 0 ) );
}

View File

@@ -31,11 +31,11 @@ HB_FUNC( QT_QSLIDER )
{
__HB_RETPTRGC__( new QSlider( ( Qt::Orientation ) hb_parni( 1 ), hbqt_par_QWidget( 2 ) ) );
}
if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QWIDGET" ) )
else if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QWIDGET" ) )
{
__HB_RETPTRGC__( new QSlider( hbqt_par_QWidget( 1 ) ) );
}
if( hb_pcount() == 2 && HB_ISNUM( 1 ) && hbqt_par_isDerivedFrom( 2, "QWIDGET" ) )
else if( hb_pcount() == 2 && HB_ISNUM( 1 ) && hbqt_par_isDerivedFrom( 2, "QWIDGET" ) )
{
__HB_RETPTRGC__( new QSlider( ( Qt::Orientation ) hb_parni( 1 ), hbqt_par_QWidget( 2 ) ) );
}

View File

@@ -32,11 +32,11 @@ HB_FUNC( QT_QSYSTEMTRAYICON )
{
__HB_RETPTRGC__( new QSystemTrayIcon( hbqt_par_QObject( 1 ) ) );
}
if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QICON" ) )
else if( hb_pcount() == 1 && hbqt_par_isDerivedFrom( 1, "QICON" ) )
{
__HB_RETPTRGC__( new QSystemTrayIcon( *hbqt_par_QIcon( 1 ) ) );
}
if( hb_pcount() == 2 && hbqt_par_isDerivedFrom( 1, "QICON" ) && hbqt_par_isDerivedFrom( 2, "QOBJECT" ) )
else if( hb_pcount() == 2 && hbqt_par_isDerivedFrom( 1, "QICON" ) && hbqt_par_isDerivedFrom( 2, "QOBJECT" ) )
{
__HB_RETPTRGC__( new QSystemTrayIcon( *hbqt_par_QIcon( 1 ), hbqt_par_QObject( 2 ) ) );
}

View File

@@ -32,7 +32,7 @@ HB_FUNC( QT_QWINDOWSTATECHANGEEVENT )
{
__HB_RETPTRGC__( new QWindowStateChangeEvent( ( Qt::WindowStates ) hb_parni( 1 ), hb_parl( 2 ) ) );
}
if( hb_pcount() == 1 && HB_ISNUM( 1 ) )
else if( hb_pcount() == 1 && HB_ISNUM( 1 ) )
{
__HB_RETPTRGC__( new QWindowStateChangeEvent( ( Qt::WindowStates ) hb_parni( 1 ) ) );
}