summaryrefslogtreecommitdiffstats
path: root/src/sql/tqsqlmanager_p.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/sql/tqsqlmanager_p.cpp')
-rw-r--r--src/sql/tqsqlmanager_p.cpp80
1 files changed, 40 insertions, 40 deletions
diff --git a/src/sql/tqsqlmanager_p.cpp b/src/sql/tqsqlmanager_p.cpp
index 64345bde2..75f37d239 100644
--- a/src/sql/tqsqlmanager_p.cpp
+++ b/src/sql/tqsqlmanager_p.cpp
@@ -57,7 +57,7 @@ class TQSqlCursorManagerPrivate
{
public:
TQSqlCursorManagerPrivate()
- : cur( 0 ), autoDelete( FALSE )
+ : cur( 0 ), autoDelete( false )
{}
TQString ftr;
@@ -166,7 +166,7 @@ TQString TQSqlCursorManager::filter() const
/*! \internal
- Sets auto-delete to \a enable. If TRUE, the default cursor will
+ Sets auto-delete to \a enable. If true, the default cursor will
be deleted when necessary.
\sa autoDelete()
@@ -180,7 +180,7 @@ void TQSqlCursorManager::setAutoDelete( bool enable )
/*! \internal
- Returns TRUE if auto-deletion is enabled, otherwise FALSE.
+ Returns true if auto-deletion is enabled, otherwise false.
\sa setAutoDelete()
@@ -194,7 +194,7 @@ bool TQSqlCursorManager::autoDelete() const
/*! \internal
Sets the default cursor used by the manager to \a cursor. If \a
- autoDelete is TRUE (the default is FALSE), the manager takes
+ autoDelete is true (the default is false), the manager takes
ownership of the \a cursor pointer, which will be deleted when the
manager is destroyed, or when setCursor() is called again. To
activate the \a cursor use refresh().
@@ -229,7 +229,7 @@ TQSqlCursor* TQSqlCursorManager::cursor() const
/*! \internal
Refreshes the manager using the default cursor. The manager's
- filter and sort are applied. Returns TRUE on success, FALSE if an
+ filter and sort are applied. Returns true on success, false if an
error occurred or there is no current cursor.
\sa setFilter() setSort()
@@ -240,7 +240,7 @@ bool TQSqlCursorManager::refresh()
{
TQSqlCursor* cur = cursor();
if ( !cur )
- return FALSE;
+ return false;
TQString currentFilter = d->ftr;
TQStringList currentSort = d->srt;
TQSqlIndex newSort = TQSqlIndex::fromStringList( currentSort, cur );
@@ -249,20 +249,20 @@ bool TQSqlCursorManager::refresh()
/* \internal
- Returns TRUE if the \a buf field values that correspond to \a idx
+ Returns true if the \a buf field values that correspond to \a idx
match the field values in \a cur that correspond to \a idx.
*/
static bool index_matches( const TQSqlCursor* cur, const TQSqlRecord* buf,
const TQSqlIndex& idx )
{
- bool indexEquals = FALSE;
+ bool indexEquals = false;
for ( uint i = 0; i < idx.count(); ++i ) {
const TQString fn( idx.field(i)->name() );
if ( cur->value( fn ) == buf->value( fn ) )
- indexEquals = TRUE;
+ indexEquals = true;
else {
- indexEquals = FALSE;
+ indexEquals = false;
break;
}
}
@@ -352,16 +352,16 @@ bool TQSqlCursorManager::findBuffer( const TQSqlIndex& idx, int atHint )
#endif
TQSqlCursor* cur = cursor();
if ( !cur )
- return FALSE;
+ return false;
if ( !cur->isActive() )
- return FALSE;
+ return false;
if ( !idx.count() ) {
if ( cur->at() == TQSql::BeforeFirst )
cur->next();
- return FALSE;
+ return false;
}
TQSqlRecord* buf = cur->editBuffer();
- bool indexEquals = FALSE;
+ bool indexEquals = false;
#ifdef QT_DEBUG_DATAMANAGER
tqDebug(" Checking hint...");
#endif
@@ -402,7 +402,7 @@ bool TQSqlCursorManager::findBuffer( const TQSqlIndex& idx, int atHint )
if ( !cur->seek( mid ) )
break;
if ( index_matches( cur, buf, idx ) ) {
- indexEquals = TRUE;
+ indexEquals = true;
break;
}
int c = compare_recs( buf, cur, cur->sort() );
@@ -416,7 +416,7 @@ bool TQSqlCursorManager::findBuffer( const TQSqlIndex& idx, int atHint )
if ( !cur->seek( mid ) )
break;
if ( index_matches( cur, buf, idx ) ) {
- indexEquals = TRUE;
+ indexEquals = true;
break;
}
} while ( compare_recs( buf, cur, cur->sort() ) == 0 );
@@ -428,7 +428,7 @@ bool TQSqlCursorManager::findBuffer( const TQSqlIndex& idx, int atHint )
if ( !cur->seek( mid ) )
break;
if ( index_matches( cur, buf, idx ) ) {
- indexEquals = TRUE;
+ indexEquals = true;
break;
}
} while ( compare_recs( buf, cur, cur->sort() ) == 0 );
@@ -453,7 +453,7 @@ bool TQSqlCursorManager::findBuffer( const TQSqlIndex& idx, int atHint )
cur->seek( startIdx );
}
for ( ;; ) {
- indexEquals = FALSE;
+ indexEquals = false;
indexEquals = index_matches( cur, buf, idx );
if ( indexEquals )
break;
@@ -620,8 +620,8 @@ class TQDataManagerPrivate
{
public:
TQDataManagerPrivate()
- : mode( TQSql::None ), autoEd( TRUE ), confEdits( 3 ),
- confCancs( FALSE ) {}
+ : mode( TQSql::None ), autoEd( true ), confEdits( 3 ),
+ confCancs( false ) {}
TQSql::Op mode;
bool autoEd;
TQBitArray confEdits;
@@ -727,7 +727,7 @@ void TQDataManager::setAutoEdit( bool autoEdit )
/*! \internal
- Returns TRUE if auto-edit mode is enabled; otherwise returns FALSE.
+ Returns true if auto-edit mode is enabled; otherwise returns false.
*/
@@ -738,8 +738,8 @@ bool TQDataManager::autoEdit() const
/*! \internal
- If \a confirm is TRUE, all edit operations (inserts, updates and
- deletes) will be confirmed by the user. If \a confirm is FALSE (the
+ If \a confirm is true, all edit operations (inserts, updates and
+ deletes) will be confirmed by the user. If \a confirm is false (the
default), all edits are posted to the database immediately.
*/
@@ -750,8 +750,8 @@ void TQDataManager::setConfirmEdits( bool confirm )
/*! \internal
- If \a confirm is TRUE, all inserts will be confirmed by the user.
- If \a confirm is FALSE (the default), all edits are posted to the
+ If \a confirm is true, all inserts will be confirmed by the user.
+ If \a confirm is false (the default), all edits are posted to the
database immediately.
*/
@@ -763,8 +763,8 @@ void TQDataManager::setConfirmInsert( bool confirm )
/*! \internal
- If \a confirm is TRUE, all updates will be confirmed by the user.
- If \a confirm is FALSE (the default), all edits are posted to the
+ If \a confirm is true, all updates will be confirmed by the user.
+ If \a confirm is false (the default), all edits are posted to the
database immediately.
*/
@@ -776,8 +776,8 @@ void TQDataManager::setConfirmUpdate( bool confirm )
/*! \internal
- If \a confirm is TRUE, all deletes will be confirmed by the user.
- If \a confirm is FALSE (the default), all edits are posted to the
+ If \a confirm is true, all deletes will be confirmed by the user.
+ If \a confirm is false (the default), all edits are posted to the
database immediately.
*/
@@ -789,8 +789,8 @@ void TQDataManager::setConfirmDelete( bool confirm )
/*! \internal
- Returns TRUE if the table confirms all edit operations (inserts,
- updates and deletes), otherwise returns FALSE.
+ Returns true if the table confirms all edit operations (inserts,
+ updates and deletes), otherwise returns false.
*/
bool TQDataManager::confirmEdits() const
@@ -800,8 +800,8 @@ bool TQDataManager::confirmEdits() const
/*! \internal
- Returns TRUE if the table confirms inserts, otherwise returns
- FALSE.
+ Returns true if the table confirms inserts, otherwise returns
+ false.
*/
bool TQDataManager::confirmInsert() const
@@ -811,8 +811,8 @@ bool TQDataManager::confirmInsert() const
/*! \internal
- Returns TRUE if the table confirms updates, otherwise returns
- FALSE.
+ Returns true if the table confirms updates, otherwise returns
+ false.
*/
bool TQDataManager::confirmUpdate() const
@@ -822,8 +822,8 @@ bool TQDataManager::confirmUpdate() const
/*! \internal
- Returns TRUE if the table confirms deletes, otherwise returns
- FALSE.
+ Returns true if the table confirms deletes, otherwise returns
+ false.
*/
bool TQDataManager::confirmDelete() const
@@ -833,8 +833,8 @@ bool TQDataManager::confirmDelete() const
/*! \internal
- If \a confirm is TRUE, all cancels will be confirmed by the user
- through a message box. If \a confirm is FALSE (the default), all
+ If \a confirm is true, all cancels will be confirmed by the user
+ through a message box. If \a confirm is false (the default), all
cancels occur immediately.
*/
@@ -845,7 +845,7 @@ void TQDataManager::setConfirmCancels( bool confirm )
/*! \internal
- Returns TRUE if the table confirms cancels, otherwise returns FALSE.
+ Returns true if the table confirms cancels, otherwise returns false.
*/
bool TQDataManager::confirmCancels() const