diff options
| author | Michele Calgaro <michele.calgaro@yahoo.it> | 2025-03-22 14:06:03 +0900 |
|---|---|---|
| committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2025-03-23 10:40:15 +0900 |
| commit | e7c7a00cc24697ba5ce25a236089608091975f5a (patch) | |
| tree | 85fb5906cd3c781cdb5f26b09920860e49e31bb4 /src/modules/help/index.cpp | |
| parent | a2bd363864dea4771da98b4c6f7ba85ca75a3784 (diff) | |
| download | kvirc-e7c7a00cc24697ba5ce25a236089608091975f5a.tar.gz kvirc-e7c7a00cc24697ba5ce25a236089608091975f5a.zip | |
Replace TRUE/FALSE with boolean values true/false
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
(cherry picked from commit 291b4f5da2f98283b7c98ee90401df7c3cb34dad)
Diffstat (limited to 'src/modules/help/index.cpp')
| -rw-r--r-- | src/modules/help/index.cpp | 48 |
1 files changed, 24 insertions, 24 deletions
diff --git a/src/modules/help/index.cpp b/src/modules/help/index.cpp index 1596d4e..82c5f57 100644 --- a/src/modules/help/index.cpp +++ b/src/modules/help/index.cpp @@ -37,8 +37,8 @@ Index::Index( const TQString &dp, const TQString &hp ) : TQObject( 0, 0 ), dict( 8999 ), docPath( dp ) { - alreadyHaveDocList = FALSE; - lastWindowClosed = FALSE; + alreadyHaveDocList = false; + lastWindowClosed = false; connect( tqApp, TQ_SIGNAL( lastWindowClosed() ), this, TQ_SLOT( setLastWinClosed() ) ); } @@ -51,8 +51,8 @@ Index::Index( const TQStringList &dl, const TQString &hp ) { docList = dl; - alreadyHaveDocList = TRUE; - lastWindowClosed = FALSE; + alreadyHaveDocList = true; + lastWindowClosed = false; connect( tqApp, TQ_SIGNAL( lastWindowClosed() ), this, TQ_SLOT( setLastWinClosed() ) ); } @@ -63,7 +63,7 @@ void Index::setLastWinClosed() { - lastWindowClosed = TRUE; + lastWindowClosed = true; } @@ -163,7 +163,7 @@ void Index::parseDocument( const TQString &filename, int docNum ) TQString text = s.read(); if (text.isNull()) return; - bool valid = TRUE; + bool valid = true; const TQChar *buf = text.unicode(); TQChar str[64]; TQChar c = buf[0]; @@ -171,7 +171,7 @@ void Index::parseDocument( const TQString &filename, int docNum ) int i = 0; while ( (uint)j < text.length() ) { if ( c == '<' || c == '&' ) { - valid = FALSE; + valid = false; if ( i > 1 ) insertInDict( TQString(str,i), docNum ); i = 0; @@ -179,7 +179,7 @@ void Index::parseDocument( const TQString &filename, int docNum ) continue; } if ( ( c == '>' || c == ';' ) && !valid ) { - valid = TRUE; + valid = true; c = buf[++j]; continue; } @@ -379,7 +379,7 @@ TQStringList Index::query( const TQStringList &terms, const TQStringList &termSe while ( C != minDocs.end() ) { - bool found = FALSE; + bool found = false; for ( It = docs.begin(); It != docs.end(); ++It ) { @@ -387,7 +387,7 @@ TQStringList Index::query( const TQStringList &terms, const TQStringList &termSe (*C).frequency += (*It).frequency; - found = TRUE; + found = true; break; @@ -462,9 +462,9 @@ TQString Index::getDocumentTitle( const TQString &fileName ) - int start = text.find( "<title>", 0, FALSE ) + 7; + int start = text.find( "<title>", 0, false ) + 7; - int end = text.find( "</title>", 0, FALSE ); + int end = text.find( "</title>", 0, false ); @@ -493,7 +493,7 @@ TQStringList Index::getWildcardTerms( const TQString &term ) int index = 0; - bool found = FALSE; + bool found = false; TQString text( it.currentKey() ); @@ -501,7 +501,7 @@ TQStringList Index::getWildcardTerms( const TQString &term ) if ( *iter == "*" ) { - found = TRUE; + found = true; continue; @@ -509,7 +509,7 @@ TQStringList Index::getWildcardTerms( const TQString &term ) if ( iter == terms.begin() && (*iter)[0] != text[0] ) { - found = FALSE; + found = false; break; @@ -523,7 +523,7 @@ TQStringList Index::getWildcardTerms( const TQString &term ) if ( index != (int)text.length() - (int)(*iter).length() ) { - found = FALSE; + found = false; break; @@ -533,7 +533,7 @@ TQStringList Index::getWildcardTerms( const TQString &term ) if ( index != -1 ) { - found = TRUE; + found = true; index += (*iter).length(); @@ -541,7 +541,7 @@ TQStringList Index::getWildcardTerms( const TQString &term ) } else { - found = FALSE; + found = false; break; @@ -697,7 +697,7 @@ bool Index::searchForPattern( const TQStringList &patterns, const TQStringList & tqWarning( "cannot open file %s", fileName.ascii() ); - return FALSE; + return false; } @@ -719,7 +719,7 @@ bool Index::searchForPattern( const TQStringList &patterns, const TQStringList & TQString text = s.read(); - bool valid = TRUE; + bool valid = true; const TQChar *buf = text.unicode(); @@ -735,7 +735,7 @@ bool Index::searchForPattern( const TQStringList &patterns, const TQStringList & if ( c == '<' || c == '&' ) { - valid = FALSE; + valid = false; if ( i > 1 ) @@ -751,7 +751,7 @@ bool Index::searchForPattern( const TQStringList &patterns, const TQStringList & if ( ( c == '>' || c == ';' ) && !valid ) { - valid = TRUE; + valid = true; c = buf[++j]; @@ -837,9 +837,9 @@ bool Index::searchForPattern( const TQStringList &patterns, const TQStringList & if ( a.count() ) - return TRUE; + return true; - return FALSE; + return false; } |
