From 22ffbb90a3c10f545069f8018deb6eb3ce67e3da Mon Sep 17 00:00:00 2001 From: Kohei Yoshida Date: Mon, 7 Mar 2011 16:40:08 -0500 Subject: [PATCH] BOOL to bool conversion. --- sc/inc/compiler.hxx | 2 +- sc/source/core/data/cell2.cxx | 6 +++--- sc/source/core/tool/compiler.cxx | 28 ++++++++++++++-------------- 3 files changed, 18 insertions(+), 18 deletions(-) diff --git a/sc/inc/compiler.hxx b/sc/inc/compiler.hxx index 8a25ede25c98..e3acd9d5d043 100644 --- a/sc/inc/compiler.hxx +++ b/sc/inc/compiler.hxx @@ -433,7 +433,7 @@ public: ScRangeData* UpdateReference( UpdateRefMode eUpdateRefMode, const ScAddress& rOldPos, const ScRange&, SCsCOL nDx, SCsROW nDy, SCsTAB nDz, - BOOL& rChanged, BOOL& rRefSizeChanged ); + bool& rChanged, bool& rRefSizeChanged ); /// Only once for converted shared formulas, /// token array has to be compiled afterwards. diff --git a/sc/source/core/data/cell2.cxx b/sc/source/core/data/cell2.cxx index 07523d649546..f29c5aae655e 100644 --- a/sc/source/core/data/cell2.cxx +++ b/sc/source/core/data/cell2.cxx @@ -912,10 +912,10 @@ void ScFormulaCell::UpdateReference(UpdateRefMode eUpdateRefMode, if( bHasRefs || bOnRefMove ) { ScTokenArray* pOld = pUndoDoc ? pCode->Clone() : NULL; - BOOL bValChanged; + bool bValChanged = false; ScRangeData* pRangeData; - BOOL bRangeModified; // any range, not only shared formula - BOOL bRefSizeChanged; + bool bRangeModified = false; // any range, not only shared formula + bool bRefSizeChanged = false; if ( bHasRefs ) { ScCompiler aComp(pDocument, aPos, *pCode); diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx index eda6b600b045..db37d0302939 100644 --- a/sc/source/core/tool/compiler.cxx +++ b/sc/source/core/tool/compiler.cxx @@ -4100,9 +4100,9 @@ void ScCompiler::MoveRelWrap( ScTokenArray& rArr, ScDocument* pDoc, const ScAddr ScRangeData* ScCompiler::UpdateReference(UpdateRefMode eUpdateRefMode, const ScAddress& rOldPos, const ScRange& r, SCsCOL nDx, SCsROW nDy, SCsTAB nDz, - BOOL& rChanged, BOOL& rRefSizeChanged ) + bool& rChanged, bool& rRefSizeChanged ) { - rChanged = rRefSizeChanged = FALSE; + rChanged = rRefSizeChanged = false; if ( eUpdateRefMode == URM_COPY ) { // Normally nothing has to be done here since RelRefs are used, also // SharedFormulas don't need any special handling, except if they @@ -4124,7 +4124,7 @@ ScRangeData* ScCompiler::UpdateReference(UpdateRefMode eUpdateRefMode, SingleDoubleRefModifier( rRef ).Ref() ) != UR_NOTHING ) - rChanged = TRUE; + rChanged = true; } } // Check for SharedFormulas. @@ -4164,7 +4164,7 @@ ScRangeData* ScCompiler::UpdateReference(UpdateRefMode eUpdateRefMode, if (!bValid) { pRangeData = pName; - rChanged = TRUE; + rChanged = true; } } } @@ -4193,7 +4193,7 @@ ScRangeData* ScCompiler::UpdateReference(UpdateRefMode eUpdateRefMode, { pRangeData = pName; // maybe need a replacement of shared with own code #if ! SC_PRESERVE_SHARED_FORMULAS_IF_POSSIBLE - rChanged = TRUE; + rChanged = true; #endif } } @@ -4218,7 +4218,7 @@ ScRangeData* ScCompiler::UpdateReference(UpdateRefMode eUpdateRefMode, SingleDoubleRefModifier( t->GetSingleRef()).Ref()) != UR_NOTHING) - rChanged = TRUE; + rChanged = true; } break; default: @@ -4231,11 +4231,11 @@ ScRangeData* ScCompiler::UpdateReference(UpdateRefMode eUpdateRefMode, aPos, r, nDx, nDy, nDz, t->GetDoubleRef()) != UR_NOTHING) { - rChanged = TRUE; + rChanged = true; if (rRef.Ref2.nCol - rRef.Ref1.nCol != nCols || rRef.Ref2.nRow - rRef.Ref1.nRow != nRows || rRef.Ref2.nTab - rRef.Ref1.nTab != nTabs) - rRefSizeChanged = TRUE; + rRefSizeChanged = true; } } } @@ -4269,7 +4269,7 @@ ScRangeData* ScCompiler::UpdateReference(UpdateRefMode eUpdateRefMode, if ( rRef.IsRelName() ) { ScRefUpdate::MoveRelWrap( pDoc, aPos, MAXCOL, MAXROW, aMod.Ref() ); - rChanged = TRUE; + rChanged = true; } else { @@ -4278,7 +4278,7 @@ ScRangeData* ScCompiler::UpdateReference(UpdateRefMode eUpdateRefMode, r, nDx, nDy, nDz, aMod.Ref() ) != UR_NOTHING ) - rChanged = TRUE; + rChanged = true; } #if SC_PRESERVE_SHARED_FORMULAS_IF_POSSIBLE if ( bEasyShared ) @@ -4299,7 +4299,7 @@ ScRangeData* ScCompiler::UpdateReference(UpdateRefMode eUpdateRefMode, if ( rRef.Ref1.IsRelName() || rRef.Ref2.IsRelName() ) { ScRefUpdate::MoveRelWrap( pDoc, aPos, MAXCOL, MAXROW, rRef ); - rChanged = TRUE; + rChanged = true; } else { @@ -4308,12 +4308,12 @@ ScRangeData* ScCompiler::UpdateReference(UpdateRefMode eUpdateRefMode, != UR_NOTHING ) { - rChanged = TRUE; + rChanged = true; if (rRef.Ref2.nCol - rRef.Ref1.nCol != nCols || rRef.Ref2.nRow - rRef.Ref1.nRow != nRows || rRef.Ref2.nTab - rRef.Ref1.nTab != nTabs) { - rRefSizeChanged = TRUE; + rRefSizeChanged = true; #if SC_PRESERVE_SHARED_FORMULAS_IF_POSSIBLE bEasyShared = FALSE; #endif @@ -4339,7 +4339,7 @@ ScRangeData* ScCompiler::UpdateReference(UpdateRefMode eUpdateRefMode, if ( bEasyShared ) pRangeData = 0; else - rChanged = TRUE; + rChanged = true; } #endif #undef SC_PRESERVE_SHARED_FORMULAS_IF_POSSIBLE