diff options
author | Xiaofei Zhang <Zhangxiaofei@openoffice.org> | 2010-07-29 10:56:19 +0800 |
---|---|---|
committer | Xiaofei Zhang <Zhangxiaofei@openoffice.org> | 2010-07-29 10:56:19 +0800 |
commit | d210c6ccc30466e98240c1409df0550514668d68 (patch) | |
tree | 0c94d52ecaebd283a92275cb372d5ddf926f5131 /rsc/source/tools | |
parent | 7f0993d43019a0ccb7f89c11fc23704c063b902f (diff) |
#i112600#: clean up l10ntools, rsc, sot, svl, tools and unotools
Diffstat (limited to 'rsc/source/tools')
-rw-r--r-- | rsc/source/tools/rscchar.cxx | 10 | ||||
-rw-r--r-- | rsc/source/tools/rscdef.cxx | 184 | ||||
-rw-r--r-- | rsc/source/tools/rsctools.cxx | 14 | ||||
-rw-r--r-- | rsc/source/tools/rsctree.cxx | 28 |
4 files changed, 118 insertions, 118 deletions
diff --git a/rsc/source/tools/rscchar.cxx b/rsc/source/tools/rscchar.cxx index c23022e4222e..f666058617f8 100644 --- a/rsc/source/tools/rscchar.cxx +++ b/rsc/source/tools/rscchar.cxx @@ -53,7 +53,7 @@ |* Letzte Aenderung MM 20.03.91 |* *************************************************************************/ -char * RscChar::MakeUTF8( char * pStr, UINT16 nTextEncoding ) +char * RscChar::MakeUTF8( char * pStr, sal_uInt16 nTextEncoding ) { sal_Size nMaxUniCodeBuf = strlen( pStr ) + 1; char * pOrgStr = new char[ nMaxUniCodeBuf ]; @@ -113,7 +113,7 @@ char * RscChar::MakeUTF8( char * pStr, UINT16 nTextEncoding ) int i = 0; while( '0' <= *pStr && '7' >= *pStr && i != 3 ) { - nChar = nChar * 8 + (BYTE)*pStr - (BYTE)'0'; + nChar = nChar * 8 + (sal_uInt8)*pStr - (sal_uInt8)'0'; ++pStr; i++; } @@ -135,11 +135,11 @@ char * RscChar::MakeUTF8( char * pStr, UINT16 nTextEncoding ) while( isxdigit( *pStr ) && i != 2 ) { if( isdigit( *pStr ) ) - nChar = nChar * 16 + (BYTE)*pStr - (BYTE)'0'; + nChar = nChar * 16 + (sal_uInt8)*pStr - (sal_uInt8)'0'; else if( isupper( *pStr ) ) - nChar = nChar * 16 + (BYTE)*pStr - (BYTE)'A' +10; + nChar = nChar * 16 + (sal_uInt8)*pStr - (sal_uInt8)'A' +10; else - nChar = nChar * 16 + (BYTE)*pStr - (BYTE)'a' +10; + nChar = nChar * 16 + (sal_uInt8)*pStr - (sal_uInt8)'a' +10; ++pStr; i++; } diff --git a/rsc/source/tools/rscdef.cxx b/rsc/source/tools/rscdef.cxx index eb714bbcc3c2..8d7f4610b3db 100644 --- a/rsc/source/tools/rscdef.cxx +++ b/rsc/source/tools/rscdef.cxx @@ -34,7 +34,7 @@ /****************** C o d e **********************************************/ /****************** R s c I d ********************************************/ -BOOL RscId::bNames = TRUE; +sal_Bool RscId::bNames = sal_True; /************************************************************************* |* @@ -46,8 +46,8 @@ BOOL RscId::bNames = TRUE; |* Letzte Aenderung MM 26.06.91 |* *************************************************************************/ -void RscId::SetNames( BOOL bSet ) { bNames = bSet; } -BOOL RscId::IsSetNames() { return bNames; } +void RscId::SetNames( sal_Bool bSet ) { bNames = bSet; } +sal_Bool RscId::IsSetNames() { return bNames; } /************************************************************************* |* @@ -58,8 +58,8 @@ BOOL RscId::IsSetNames() { return bNames; } |* Letzte Aenderung MM 17.05.91 |* *************************************************************************/ -INT32 RscId::GetNumber() const{ - INT32 lVal; +sal_Int32 RscId::GetNumber() const{ + sal_Int32 lVal; aExp.Evaluate( &lVal ); return lVal; } @@ -79,7 +79,7 @@ void RscId::Create( const RscExpType & rExpType ) if( aExp.IsDefinition() ) aExp.aExp.pDef->IncRef(); else if( aExp.IsExpression() ){ - INT32 lValue; + sal_Int32 lValue; aExp.Evaluate( &lValue ); aExp.SetLong( lValue ); @@ -159,7 +159,7 @@ RscId& RscId::operator = ( const RscId& rRscId ){ |* Letzte Aenderung MM 16.05.91 |* *************************************************************************/ -BOOL RscId::operator == ( const RscId& rRscId ) const +sal_Bool RscId::operator == ( const RscId& rRscId ) const { return( GetNumber() == rRscId.GetNumber() ); } @@ -173,7 +173,7 @@ BOOL RscId::operator == ( const RscId& rRscId ) const |* Letzte Aenderung MM 16.05.91 |* *************************************************************************/ -BOOL RscId::operator < ( const RscId& rRscId ) const +sal_Bool RscId::operator < ( const RscId& rRscId ) const { return( GetNumber() < rRscId.GetNumber() ); } @@ -187,21 +187,21 @@ BOOL RscId::operator < ( const RscId& rRscId ) const |* Letzte Aenderung MM 16.05.91 |* *************************************************************************/ -BOOL RscId::operator > ( const RscId& rRscId ) const +sal_Bool RscId::operator > ( const RscId& rRscId ) const { return( GetNumber() > rRscId.GetNumber() ); } /************************************************************************* |* -|* RscId::INT32() +|* RscId::sal_Int32() |* |* Beschreibung |* Ersterstellung MM 16.05.91 |* Letzte Aenderung MM 16.05.91 |* *************************************************************************/ -RscId::operator INT32() const +RscId::operator sal_Int32() const { return( GetNumber() ); } @@ -261,7 +261,7 @@ ByteString RscId::GetMacro() const |* Letzte Aenderung MM 01.11.91 |* *************************************************************************/ -RscDefine::RscDefine( ULONG lKey, const ByteString & rDefName, INT32 lDefId ) +RscDefine::RscDefine( sal_uIntPtr lKey, const ByteString & rDefName, sal_Int32 lDefId ) : StringNode( rDefName ) { nRefCount = 0; @@ -270,7 +270,7 @@ RscDefine::RscDefine( ULONG lKey, const ByteString & rDefName, INT32 lDefId ) pExp = NULL; } -RscDefine::RscDefine( ULONG lKey, const ByteString & rDefName, +RscDefine::RscDefine( sal_uIntPtr lKey, const ByteString & rDefName, RscExpression * pExpression ) : StringNode( rDefName ) { @@ -345,7 +345,7 @@ void RscDefine::ChangeMacro( RscExpression * pExpression ){ pExp->Evaluate( &lId ); } -void RscDefine::ChangeMacro( INT32 lIdentifier ){ +void RscDefine::ChangeMacro( sal_Int32 lIdentifier ){ if( pExp ){ delete pExp; pExp = NULL; @@ -362,8 +362,8 @@ void RscDefine::ChangeMacro( INT32 lIdentifier ){ |* Letzte Aenderung MM 01.11.91 |* *************************************************************************/ -BOOL RscDefine::Evaluate(){ - BOOL bRet = TRUE; +sal_Bool RscDefine::Evaluate(){ + sal_Bool bRet = sal_True; if( pExp ) bRet = !pExp->Evaluate( &lId ); @@ -410,8 +410,8 @@ ByteString RscDefine::GetMacro() |* Letzte Aenderung MM 04.11.91 |* *************************************************************************/ -RscDefine * RscDefineList::New( ULONG lFileKey, const ByteString & rDefName, - INT32 lDefId, ULONG lPos ) +RscDefine * RscDefineList::New( sal_uIntPtr lFileKey, const ByteString & rDefName, + sal_Int32 lDefId, sal_uIntPtr lPos ) { RscDefine * pDef; @@ -421,8 +421,8 @@ RscDefine * RscDefineList::New( ULONG lFileKey, const ByteString & rDefName, return pDef; } -RscDefine * RscDefineList::New( ULONG lFileKey, const ByteString & rDefName, - RscExpression * pExpression, ULONG lPos ) +RscDefine * RscDefineList::New( sal_uIntPtr lFileKey, const ByteString & rDefName, + RscExpression * pExpression, sal_uIntPtr lPos ) { RscDefine * pDef; @@ -442,7 +442,7 @@ RscDefine * RscDefineList::New( ULONG lFileKey, const ByteString & rDefName, |* Letzte Aenderung MM 04.11.91 |* *************************************************************************/ -BOOL RscDefineList::Remove( RscDefine * pDef ){ +sal_Bool RscDefineList::Remove( RscDefine * pDef ){ pDef = RscSubDefList::Remove( pDef ); if( pDef ){ pDef->DefineToNumber(); @@ -452,7 +452,7 @@ BOOL RscDefineList::Remove( RscDefine * pDef ){ return( NULL != pDef ); } -BOOL RscDefineList::Remove( ULONG lIndex ){ +sal_Bool RscDefineList::Remove( sal_uIntPtr lIndex ){ RscDefine * pDef = RscSubDefList::Remove( lIndex ); if( pDef ){ pDef->DefineToNumber(); @@ -462,10 +462,10 @@ BOOL RscDefineList::Remove( ULONG lIndex ){ return( NULL != pDef ); } -BOOL RscDefineList::Remove(){ +sal_Bool RscDefineList::Remove(){ RscDefine * pDef; - pDef = RscSubDefList::Remove( (ULONG)0 ); + pDef = RscSubDefList::Remove( (sal_uIntPtr)0 ); if( pDef ){ pDef->DefineToNumber(); @@ -483,7 +483,7 @@ BOOL RscDefineList::Remove(){ |* Letzte Aenderung MM 12.11.91 |* *************************************************************************/ -BOOL RscDefineList::Befor( const RscDefine * pFree, +sal_Bool RscDefineList::Befor( const RscDefine * pFree, const RscDefine * pDepend ) { RscDefine * pDef; @@ -494,13 +494,13 @@ BOOL RscDefineList::Befor( const RscDefine * pFree, pDef = Next(); while( pDef ){ if( pDef == pDepend ) - return TRUE; + return sal_True; pDef = Next(); } } pDef = Next(); }; - return FALSE; + return sal_False; } /************************************************************************* @@ -535,7 +535,7 @@ void RscDefineList::WriteAll( FILE * fOutput ) |* Letzte Aenderung MM 01.11.91 |* *************************************************************************/ -BOOL RscExpType::Evaluate( INT32 * plValue ) const{ +sal_Bool RscExpType::Evaluate( sal_Int32 * plValue ) const{ if( IsDefinition() ){ aExp.pDef->Evaluate(); // Eventuellen Fehler ignorieren @@ -548,7 +548,7 @@ BOOL RscExpType::Evaluate( INT32 * plValue ) const{ else *plValue = GetLong(); - return TRUE; + return sal_True; } /************************************************************************* @@ -626,9 +626,9 @@ RscExpression::~RscExpression(){ |* Letzte Aenderung MM 01.11.91 |* *************************************************************************/ -BOOL RscExpression::Evaluate( INT32 * plValue ){ - INT32 lLeft; - INT32 lRight; +sal_Bool RscExpression::Evaluate( sal_Int32 * plValue ){ + sal_Int32 lLeft; + sal_Int32 lRight; // linken und rechten Zweig auswerten if( aLeftExp.Evaluate( &lLeft ) && aRightExp.Evaluate( &lRight ) ){ @@ -648,12 +648,12 @@ BOOL RscExpression::Evaluate( INT32 * plValue ){ *plValue = lLeft << lRight; else{ if( 0L == lRight ) - return FALSE; + return sal_False; *plValue = lLeft / lRight; }; - return TRUE; + return sal_True; } - return FALSE; + return sal_False; } /************************************************************************* @@ -712,10 +712,10 @@ ByteString RscExpression::GetMacro() |* *************************************************************************/ RscFile :: RscFile(){ - bLoaded = FALSE; - bIncFile = FALSE; - bDirty = FALSE; - bScanned = FALSE; + bLoaded = sal_False; + bIncFile = sal_False; + bDirty = sal_False; + bScanned = sal_False; } /************************************************************************* @@ -728,11 +728,11 @@ RscFile :: RscFile(){ |* *************************************************************************/ RscFile :: ~RscFile(){ - RscDepend * pDep = Remove( (ULONG)0 ); + RscDepend * pDep = Remove( (sal_uIntPtr)0 ); while( pDep ){ delete pDep; - pDep = Remove( (ULONG)0 ); + pDep = Remove( (sal_uIntPtr)0 ); } //von hinten nach vorne ist besser wegen der Abhaengigkeiten @@ -745,14 +745,14 @@ RscFile :: ~RscFile(){ |* |* RscFile::Depend() |* -|* Beschreibung Diese Methode gibt TRUE zurueck, wenn lDepend +|* Beschreibung Diese Methode gibt sal_True zurueck, wenn lDepend |* existiert und hinter lFree steht, oder wenn |* lDepend nicht existiert. |* Ersterstellung MM 12.11.91 |* Letzte Aenderung MM 12.11.91 |* *************************************************************************/ -BOOL RscFile::Depend( ULONG lDepend, ULONG lFree ){ +sal_Bool RscFile::Depend( sal_uIntPtr lDepend, sal_uIntPtr lFree ){ RscDepend * pDep; pDep = Last(); @@ -760,15 +760,15 @@ BOOL RscFile::Depend( ULONG lDepend, ULONG lFree ){ if( pDep->GetFileKey() == lDepend ){ while( pDep ){ if( pDep->GetFileKey() == lFree ) - return TRUE; + return sal_True; pDep = Prev(); } - return FALSE; + return sal_False; } pDep = Prev(); }; - return TRUE; + return sal_True; } /************************************************************************* @@ -780,14 +780,14 @@ BOOL RscFile::Depend( ULONG lDepend, ULONG lFree ){ |* Letzte Aenderung MM 06.01.92 |* *************************************************************************/ -BOOL RscFile :: InsertDependFile( ULONG lIncFile, ULONG lPos ) +sal_Bool RscFile :: InsertDependFile( sal_uIntPtr lIncFile, sal_uIntPtr lPos ) { RscDepend * pDep; pDep = First(); while( pDep ){ if( pDep->GetFileKey() == lIncFile ) - return TRUE; + return sal_True; pDep = Next(); } @@ -799,7 +799,7 @@ BOOL RscFile :: InsertDependFile( ULONG lIncFile, ULONG lPos ) else Insert( new RscDepend( lIncFile ), lPos ); - return TRUE; + return sal_True; } /************************************************************************* @@ -811,7 +811,7 @@ BOOL RscFile :: InsertDependFile( ULONG lIncFile, ULONG lPos ) |* Letzte Aenderung MM 18.11.91 |* *************************************************************************/ -void RscFile :: RemoveDependFile( ULONG lDepFile ) +void RscFile :: RemoveDependFile( sal_uIntPtr lDepFile ) { RscDepend * pDep = Last(); @@ -915,17 +915,17 @@ void RscDefTree::Remove( RscDefine * pDef ){ |* Letzte Aenderung MM 12.11.91 |* *************************************************************************/ -BOOL RscDefTree::Evaluate( RscDefine * pDef ){ +sal_Bool RscDefTree::Evaluate( RscDefine * pDef ){ if( pDef ){ if( !Evaluate( (RscDefine *)pDef->Left() ) ) - return FALSE; + return sal_False; if( !Evaluate( (RscDefine *)pDef->Right() ) ) - return FALSE; + return sal_False; }; - return TRUE; + return sal_True; } -BOOL RscDefTree::Evaluate(){ +sal_Bool RscDefTree::Evaluate(){ return Evaluate( pDefRoot ); } @@ -973,7 +973,7 @@ RscFileTab :: ~RscFileTab(){ |* Letzte Aenderung MM 16.05.91 |* *************************************************************************/ -ULONG RscFileTab :: Find( const ByteString & rName ) +sal_uIntPtr RscFileTab :: Find( const ByteString & rName ) { RscFile * pFName; @@ -1009,7 +1009,7 @@ RscDefine * RscFileTab::FindDef( const char * pName ){ |* Letzte Aenderung MM 01.11.91 |* *************************************************************************/ -RscDefine * RscFileTab::FindDef( ULONG lFileKey, const ByteString & rName ) +RscDefine * RscFileTab::FindDef( sal_uIntPtr lFileKey, const ByteString & rName ) { RscDefine * pDef = FindDef( rName ); @@ -1030,20 +1030,20 @@ RscDefine * RscFileTab::FindDef( ULONG lFileKey, const ByteString & rName ) |* Letzte Aenderung MM 08.11.91 |* *************************************************************************/ -BOOL RscFileTab::Depend( ULONG lDepend, ULONG lFree ){ +sal_Bool RscFileTab::Depend( sal_uIntPtr lDepend, sal_uIntPtr lFree ){ if( lDepend == lFree ) - return TRUE; + return sal_True; RscFile * pFile = First(); while( pFile ){ if( !pFile->IsIncFile() ){ if( !pFile->Depend( lDepend, lFree ) ) - return FALSE; + return sal_False; }; pFile = Next(); }; - return TRUE; + return sal_True; } /************************************************************************* @@ -1055,17 +1055,17 @@ BOOL RscFileTab::Depend( ULONG lDepend, ULONG lFree ){ |* Letzte Aenderung MM 14.01.92 |* *************************************************************************/ -BOOL RscFileTab::TestDef( ULONG lFileKey, ULONG lPos, +sal_Bool RscFileTab::TestDef( sal_uIntPtr lFileKey, sal_uIntPtr lPos, const RscDefine * pDefDec ) { if( lFileKey == pDefDec->GetFileKey() ){ RscFile * pFile = GetFile( pDefDec->GetFileKey() ); if( pFile && (lPos <= pFile->aDefLst.GetPos( (RscDefine *)pDefDec )) && (lPos != LIST_APPEND) ) - return FALSE; + return sal_False; } else if( !Depend( lFileKey, pDefDec->GetFileKey() ) ) - return FALSE; + return sal_False; return TestDef( lFileKey, lPos, pDefDec->pExp ); } @@ -1079,29 +1079,29 @@ BOOL RscFileTab::TestDef( ULONG lFileKey, ULONG lPos, |* Letzte Aenderung MM 14.01.92 |* *************************************************************************/ -BOOL RscFileTab::TestDef( ULONG lFileKey, ULONG lPos, +sal_Bool RscFileTab::TestDef( sal_uIntPtr lFileKey, sal_uIntPtr lPos, const RscExpression * pExpDec ) { if( !pExpDec ) - return TRUE; + return sal_True; if( pExpDec->aLeftExp.IsExpression() ) if( !TestDef( lFileKey, lPos, pExpDec->aLeftExp.aExp.pExp ) ) - return FALSE; + return sal_False; if( pExpDec->aLeftExp.IsDefinition() ) if( !TestDef( lFileKey, lPos, pExpDec->aLeftExp.aExp.pDef ) ) - return FALSE; + return sal_False; if( pExpDec->aRightExp.IsExpression() ) if( !TestDef( lFileKey, lPos, pExpDec->aRightExp.aExp.pExp ) ) - return FALSE; + return sal_False; if( pExpDec->aRightExp.IsDefinition() ) if( !TestDef( lFileKey, lPos, pExpDec->aRightExp.aExp.pDef ) ) - return FALSE; + return sal_False; - return TRUE; + return sal_True; } /************************************************************************* @@ -1113,8 +1113,8 @@ BOOL RscFileTab::TestDef( ULONG lFileKey, ULONG lPos, |* Letzte Aenderung MM 04.11.91 |* *************************************************************************/ -RscDefine * RscFileTab::NewDef( ULONG lFileKey, const ByteString & rDefName, - INT32 lId, ULONG lPos ) +RscDefine * RscFileTab::NewDef( sal_uIntPtr lFileKey, const ByteString & rDefName, + sal_Int32 lId, sal_uIntPtr lPos ) { RscDefine * pDef = FindDef( rDefName ); @@ -1141,8 +1141,8 @@ RscDefine * RscFileTab::NewDef( ULONG lFileKey, const ByteString & rDefName, |* Letzte Aenderung MM 04.11.91 |* *************************************************************************/ -RscDefine * RscFileTab::NewDef( ULONG lFileKey, const ByteString & rDefName, - RscExpression * pExp, ULONG lPos ) +RscDefine * RscFileTab::NewDef( sal_uIntPtr lFileKey, const ByteString & rDefName, + RscExpression * pExp, sal_uIntPtr lPos ) { RscDefine * pDef = FindDef( rDefName ); @@ -1177,14 +1177,14 @@ RscDefine * RscFileTab::NewDef( ULONG lFileKey, const ByteString & rDefName, |* Letzte Aenderung MM 22.11.91 |* *************************************************************************/ -BOOL RscFileTab::IsDefUsed( const ByteString & rDefName ) +sal_Bool RscFileTab::IsDefUsed( const ByteString & rDefName ) { RscDefine * pDef = FindDef( rDefName ); if( pDef ) return( pDef->GetRefCount() != 2 ); - return FALSE; + return sal_False; } /************************************************************************* @@ -1219,7 +1219,7 @@ void RscFileTab::DeleteDef( const ByteString & rDefName ) |* Letzte Aenderung MM 11.11.91 |* *************************************************************************/ -BOOL RscFileTab::ChangeDef( const ByteString & rDefName, INT32 lId ) +sal_Bool RscFileTab::ChangeDef( const ByteString & rDefName, sal_Int32 lId ) { RscDefine * pDef = FindDef( rDefName ); @@ -1228,7 +1228,7 @@ BOOL RscFileTab::ChangeDef( const ByteString & rDefName, INT32 lId ) //alle Macros neu bewerten return aDefTree.Evaluate(); }; - return( FALSE ); + return( sal_False ); } /************************************************************************* @@ -1240,12 +1240,12 @@ BOOL RscFileTab::ChangeDef( const ByteString & rDefName, INT32 lId ) |* Letzte Aenderung MM 11.11.91 |* *************************************************************************/ -BOOL RscFileTab::ChangeDef( const ByteString & rDefName, +sal_Bool RscFileTab::ChangeDef( const ByteString & rDefName, RscExpression * pExp ) { RscDefine * pDef = FindDef( rDefName ); RscFile * pFile; - ULONG lPos = 0; + sal_uIntPtr lPos = 0; if( pDef ){ pFile = GetFile( pDef->GetFileKey() ); @@ -1263,7 +1263,7 @@ BOOL RscFileTab::ChangeDef( const ByteString & rDefName, // geloescht werden delete pExp; - return( FALSE ); + return( sal_False ); } /************************************************************************* @@ -1275,7 +1275,7 @@ BOOL RscFileTab::ChangeDef( const ByteString & rDefName, |* Letzte Aenderung MM 04.11.91 |* *************************************************************************/ -BOOL RscFileTab::ChangeDefName( const ByteString & rDefName, +sal_Bool RscFileTab::ChangeDefName( const ByteString & rDefName, const ByteString & rNewName ) { RscDefine * pDef = FindDef( rDefName ); @@ -1287,11 +1287,11 @@ BOOL RscFileTab::ChangeDefName( const ByteString & rDefName, aDefTree.Remove( pDef ); pDef->SetName( rNewName ); aDefTree.Insert( pDef ); - return( TRUE ); + return( sal_True ); } }; - return( FALSE ); + return( sal_False ); } /************************************************************************* @@ -1303,7 +1303,7 @@ BOOL RscFileTab::ChangeDefName( const ByteString & rDefName, |* Letzte Aenderung MM 09.12.91 |* *************************************************************************/ -void RscFileTab :: DeleteFileContext( ULONG lFileKey ){ +void RscFileTab :: DeleteFileContext( sal_uIntPtr lFileKey ){ RscFile * pFName; pFName = GetFile( lFileKey ); @@ -1315,7 +1315,7 @@ void RscFileTab :: DeleteFileContext( ULONG lFileKey ){ aDefTree.Remove( pDef ); pDef = pFName->aDefLst.Next(); }; - while( pFName->aDefLst.Remove( (ULONG)0 ) ) ; + while( pFName->aDefLst.Remove( (sal_uIntPtr)0 ) ) ; } } @@ -1328,7 +1328,7 @@ void RscFileTab :: DeleteFileContext( ULONG lFileKey ){ |* Letzte Aenderung MM 16.05.91 |* *************************************************************************/ -void RscFileTab :: DeleteFile( ULONG lFileKey ){ +void RscFileTab :: DeleteFile( sal_uIntPtr lFileKey ){ RscFile * pFName; //Defines freigeben @@ -1355,9 +1355,9 @@ void RscFileTab :: DeleteFile( ULONG lFileKey ){ |* Letzte Aenderung MM 16.05.91 |* *************************************************************************/ -ULONG RscFileTab :: NewCodeFile( const ByteString & rName ) +sal_uIntPtr RscFileTab :: NewCodeFile( const ByteString & rName ) { - ULONG lKey; + sal_uIntPtr lKey; RscFile * pFName; lKey = Find( rName ); @@ -1381,10 +1381,10 @@ ULONG RscFileTab :: NewCodeFile( const ByteString & rName ) |* Letzte Aenderung MM 16.05.91 |* *************************************************************************/ -ULONG RscFileTab :: NewIncFile( const ByteString & rName, +sal_uIntPtr RscFileTab :: NewIncFile( const ByteString & rName, const ByteString & rPath ) { - ULONG lKey; + sal_uIntPtr lKey; RscFile * pFName; lKey = Find( rName ); diff --git a/rsc/source/tools/rsctools.cxx b/rsc/source/tools/rsctools.cxx index 9904cd20d4e7..9632df25c641 100644 --- a/rsc/source/tools/rsctools.cxx +++ b/rsc/source/tools/rsctools.cxx @@ -148,7 +148,7 @@ ByteString GetTmpFileName() /* */ /* Description : appends text files */ /********************************************************************/ -BOOL Append( FILE * fDest, ByteString aTmpFile ) +sal_Bool Append( FILE * fDest, ByteString aTmpFile ) { #define MAX_BUF 4096 char szBuf[ MAX_BUF ]; @@ -159,7 +159,7 @@ BOOL Append( FILE * fDest, ByteString aTmpFile ) if( !fDest || !fSource ){ if( fSource ) fclose( fSource ); - return FALSE; + return sal_False; } else{ do{ // append @@ -169,14 +169,14 @@ BOOL Append( FILE * fDest, ByteString aTmpFile ) fclose( fSource ); }; - return TRUE; + return sal_True; } -BOOL Append( ByteString aOutputSrs, ByteString aTmpFile ) +sal_Bool Append( ByteString aOutputSrs, ByteString aTmpFile ) { FILE * fDest = fopen( aOutputSrs.GetBuffer(), "ab" ); - BOOL bRet = Append( fDest, aTmpFile ); + sal_Bool bRet = Append( fDest, aTmpFile ); if( fDest ) fclose( fDest ); @@ -394,10 +394,10 @@ RscWriteRc::RscWriteRc( RSCBYTEORDER_TYPE nOrder ) short nSwapTest = 1; RSCBYTEORDER_TYPE nMachineOrder; - bSwap = FALSE; + bSwap = sal_False; if( nOrder != RSC_SYSTEMENDIAN ) { - if( (BYTE)*(BYTE *)&nSwapTest ) + if( (sal_uInt8)*(sal_uInt8 *)&nSwapTest ) nMachineOrder = RSC_LITTLEENDIAN; else nMachineOrder = RSC_BIGENDIAN; diff --git a/rsc/source/tools/rsctree.cxx b/rsc/source/tools/rsctree.cxx index 991e32aa580c..e719cc39548e 100644 --- a/rsc/source/tools/rsctree.cxx +++ b/rsc/source/tools/rsctree.cxx @@ -316,12 +316,12 @@ NameNode* NameNode::Search( const void * pSearch ) const{ |* Letzte Aenderung MM 11.01.91 |* *************************************************************************/ -BOOL NameNode::Insert( NameNode * pTN, sal_uInt32* pnDepth ){ +sal_Bool NameNode::Insert( NameNode * pTN, sal_uInt32* pnDepth ){ // Ein Knoten wird in den Baum eingefuegt -// Gibt es einen Knoten mit dem gleichen Namen, dann return FALSE -// sonst return TRUE. Der Knoten wird auf jeden Fall eingefuegt. +// Gibt es einen Knoten mit dem gleichen Namen, dann return sal_False +// sonst return sal_True. Der Knoten wird auf jeden Fall eingefuegt. - BOOL bRet = TRUE; + sal_Bool bRet = sal_True; int nCmp = Compare( pTN ); *pnDepth += 1; @@ -337,7 +337,7 @@ BOOL NameNode::Insert( NameNode * pTN, sal_uInt32* pnDepth ){ else pRight = pTN; if( nCmp == EQUAL ) - bRet = FALSE; + bRet = sal_False; }; return( bRet ); } @@ -351,12 +351,12 @@ BOOL NameNode::Insert( NameNode * pTN, sal_uInt32* pnDepth ){ |* Letzte Aenderung MM 11.01.91 |* *************************************************************************/ -BOOL NameNode::Insert( NameNode * pTN ){ +sal_Bool NameNode::Insert( NameNode * pTN ){ // insert a node in the tree. -// if the node with the same name is in, return FALSE and no insert. +// if the node with the same name is in, return sal_False and no insert. // if not return true. sal_uInt32 nDepth = 0; - BOOL bRet; + sal_Bool bRet; bRet = Insert( pTN, &nDepth ); if( bRet ){ @@ -412,14 +412,14 @@ void NameNode::SubOrderTree( NameNode * pOrderNode ){ |* *************************************************************************/ class OrderCtrl { - BOOL bOrder; + sal_Bool bOrder; NameNode * pName; DECL_LINK( CallBackFunc, NameNode * ); public: - OrderCtrl() { bOrder = FALSE; pName = NULL; } - BOOL IsOrder( const NameNode * pRoot ) + OrderCtrl() { bOrder = sal_False; pName = NULL; } + sal_Bool IsOrder( const NameNode * pRoot ) { - bOrder = TRUE; + bOrder = sal_True; pName = NULL; pRoot->EnumNodes( LINK( this, OrderCtrl, CallBackFunc ) ); return bOrder; @@ -428,13 +428,13 @@ public: IMPL_LINK_INLINE_START( OrderCtrl, CallBackFunc, NameNode *, pNext ) { if( pName && pName->Compare( pNext ) != LESS ) - bOrder = FALSE; + bOrder = sal_False; pName = pNext; return 0; } IMPL_LINK_INLINE_END( OrderCtrl, CallBackFunc, NameNode *, pNext ) -BOOL NameNode::IsOrderTree() const{ +sal_Bool NameNode::IsOrderTree() const{ OrderCtrl aOrder; return aOrder.IsOrder( this ); |