diff options
-rw-r--r-- | formula/inc/formula/tokenarray.hxx | 10 | ||||
-rw-r--r-- | formula/source/core/api/FormulaCompiler.cxx | 9 | ||||
-rw-r--r-- | formula/source/core/api/token.cxx | 6 | ||||
-rw-r--r-- | sc/source/core/data/cell.cxx | 4 | ||||
-rw-r--r-- | sc/source/core/tool/interpr2.cxx | 2 | ||||
-rw-r--r-- | sc/source/core/tool/interpr4.cxx | 4 | ||||
-rw-r--r-- | sc/source/filter/excel/excform.cxx | 2 |
7 files changed, 19 insertions, 18 deletions
diff --git a/formula/inc/formula/tokenarray.hxx b/formula/inc/formula/tokenarray.hxx index e9041acb049a..32d871016e7b 100644 --- a/formula/inc/formula/tokenarray.hxx +++ b/formula/inc/formula/tokenarray.hxx @@ -84,7 +84,7 @@ protected: inline ScRecalcMode GetCombinedBitsRecalcMode() const { return nMode & ~RECALCMODE_EMASK; } /** Exclusive bits already set in nMode are - zero'ed, nVal may contain combined bits, but + zero'ed, nBits may contain combined bits, but only one exclusive bit may be set! */ inline void SetMaskedRecalcMode( ScRecalcMode nBits ) { nMode = GetCombinedBitsRecalcMode() | nBits; } @@ -142,13 +142,13 @@ public: void AddRecalcMode( ScRecalcMode nBits ); inline void ClearRecalcMode() { nMode = RECALCMODE_NORMAL; } - inline void SetRecalcModeNormal() + inline void SetExclusiveRecalcModeNormal() { SetMaskedRecalcMode( RECALCMODE_NORMAL ); } - inline void SetRecalcModeAlways() + inline void SetExclusiveRecalcModeAlways() { SetMaskedRecalcMode( RECALCMODE_ALWAYS ); } - inline void SetRecalcModeOnLoad() + inline void SetExclusiveRecalcModeOnLoad() { SetMaskedRecalcMode( RECALCMODE_ONLOAD ); } - inline void SetRecalcModeOnLoadOnce() + inline void SetExclusiveRecalcModeOnLoadOnce() { SetMaskedRecalcMode( RECALCMODE_ONLOAD_ONCE ); } inline void SetRecalcModeForced() { nMode |= RECALCMODE_FORCED; } diff --git a/formula/source/core/api/FormulaCompiler.cxx b/formula/source/core/api/FormulaCompiler.cxx index a8bfcbd0a0c3..21f8e975a7ee 100644 --- a/formula/source/core/api/FormulaCompiler.cxx +++ b/formula/source/core/api/FormulaCompiler.cxx @@ -1052,14 +1052,15 @@ void FormulaCompiler::Factor() nNumFmt = lcl_GetRetFormat( eOp ); if ( IsOpCodeVolatile(eOp) ) - pArr->SetRecalcModeAlways(); + pArr->SetExclusiveRecalcModeAlways(); else { switch( eOp ) { // Functions recalculated on every document load. - // Don't use SetRecalcModeOnLoad() which would override - // ModeAlways. + // Don't use SetExclusiveRecalcModeOnLoad() which would + // override ModeAlways, use + // AddRecalcMode(RECALCMODE_ONLOAD) instead. case ocConvert : pArr->AddRecalcMode( RECALCMODE_ONLOAD ); break; @@ -1599,7 +1600,7 @@ void FormulaCompiler::PopTokenArray() p->pArr->nRefs = sal::static_int_cast<short>( p->pArr->nRefs + pArr->nRefs ); // obtain special RecalcMode from SharedFormula if ( pArr->IsRecalcModeAlways() ) - p->pArr->SetRecalcModeAlways(); + p->pArr->SetExclusiveRecalcModeAlways(); else if ( !pArr->IsRecalcModeNormal() && p->pArr->IsRecalcModeNormal() ) p->pArr->SetMaskedRecalcMode( pArr->GetRecalcMode() ); p->pArr->SetCombinedBitsRecalcMode( pArr->GetRecalcMode() ); diff --git a/formula/source/core/api/token.cxx b/formula/source/core/api/token.cxx index f6110e7ce5b3..150be29a7a61 100644 --- a/formula/source/core/api/token.cxx +++ b/formula/source/core/api/token.cxx @@ -783,13 +783,13 @@ void FormulaTokenArray::AddRecalcMode( ScRecalcMode nBits ) { //! Reihenfolge ist wichtig if ( nBits & RECALCMODE_ALWAYS ) - SetRecalcModeAlways(); + SetExclusiveRecalcModeAlways(); else if ( !IsRecalcModeAlways() ) { if ( nBits & RECALCMODE_ONLOAD ) - SetRecalcModeOnLoad(); + SetExclusiveRecalcModeOnLoad(); else if ( nBits & RECALCMODE_ONLOAD_ONCE && !IsRecalcModeOnLoad() ) - SetRecalcModeOnLoadOnce(); + SetExclusiveRecalcModeOnLoadOnce(); } SetCombinedBitsRecalcMode( nBits ); } diff --git a/sc/source/core/data/cell.cxx b/sc/source/core/data/cell.cxx index 0967e811ab46..75d1ced0eddf 100644 --- a/sc/source/core/data/cell.cxx +++ b/sc/source/core/data/cell.cxx @@ -1698,7 +1698,7 @@ void ScFormulaCell::InterpretTail( ScInterpretTailParameter eTailParam ) break; case ScInterpreter::VOLATILE_MACRO: // The formula contains a volatile macro. - pCode->SetRecalcModeAlways(); + pCode->SetExclusiveRecalcModeAlways(); pDocument->PutInFormulaTree(this); StartListeningTo(pDocument); break; @@ -1707,7 +1707,7 @@ void ScFormulaCell::InterpretTail( ScInterpretTailParameter eTailParam ) { // The formula was previously volatile, but no more. EndListeningTo(pDocument); - pCode->SetRecalcModeNormal(); + pCode->SetExclusiveRecalcModeNormal(); } else { diff --git a/sc/source/core/tool/interpr2.cxx b/sc/source/core/tool/interpr2.cxx index dc37e0898ca6..7326497912ab 100644 --- a/sc/source/core/tool/interpr2.cxx +++ b/sc/source/core/tool/interpr2.cxx @@ -2272,7 +2272,7 @@ void ScInterpreter::ScDde() // Nach dem Laden muss neu interpretiert werden (Verknuepfungen aufbauen) if ( pMyFormulaCell->GetCode()->IsRecalcModeNormal() ) - pMyFormulaCell->GetCode()->SetRecalcModeOnLoad(); + pMyFormulaCell->GetCode()->SetExclusiveRecalcModeOnLoad(); // solange der Link nicht ausgewertet ist, Idle abklemmen // (um zirkulaere Referenzen zu vermeiden) diff --git a/sc/source/core/tool/interpr4.cxx b/sc/source/core/tool/interpr4.cxx index d6f59f7b1bce..04cd1b58ed92 100644 --- a/sc/source/core/tool/interpr4.cxx +++ b/sc/source/core/tool/interpr4.cxx @@ -2676,7 +2676,7 @@ void ScInterpreter::ScExternal() { // nach dem Laden Asyncs wieder anwerfen if ( pMyFormulaCell->GetCode()->IsRecalcModeNormal() ) - pMyFormulaCell->GetCode()->SetRecalcModeOnLoad(); + pMyFormulaCell->GetCode()->SetExclusiveRecalcModeOnLoad(); // garantiert identischer Handle bei identischem Aufruf?!? // sonst schei*e ... double nErg = 0.0; @@ -3047,7 +3047,7 @@ void ScInterpreter::ScExternal() { if ( pMyFormulaCell->GetCode()->IsRecalcModeNormal() ) { - pMyFormulaCell->GetCode()->SetRecalcModeOnLoad(); + pMyFormulaCell->GetCode()->SetExclusiveRecalcModeOnLoad(); } uno::Reference<sheet::XVolatileResult> xRes = aCall.GetVarRes(); ScAddInListener* pLis = ScAddInListener::Get( xRes ); diff --git a/sc/source/filter/excel/excform.cxx b/sc/source/filter/excel/excform.cxx index b819ab0e6fb0..07d22f81b42f 100644 --- a/sc/source/filter/excel/excform.cxx +++ b/sc/source/filter/excel/excform.cxx @@ -1684,7 +1684,7 @@ const ScTokenArray* ExcelToSc::GetBoolErr( XclBoolError eType ) if( nError ) ( ( ScTokenArray* ) pErgebnis )->SetCodeError( nError ); - ( ( ScTokenArray* ) pErgebnis )->SetRecalcModeNormal(); + ( ( ScTokenArray* ) pErgebnis )->SetExclusiveRecalcModeNormal(); return pErgebnis; } |