[PATCH libreoffice-4-0] CELL needs to be recalculated during import as well, fdo#606...

Eike Rathke (via Code Review) gerrit at gerrit.libreoffice.org
Fri Feb 15 05:21:31 PST 2013


Hi,

I have submitted a patch for review:

    https://gerrit.libreoffice.org/2168

To pull it, you can do:

    git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/68/2168/1

CELL needs to be recalculated during import as well, fdo#60645

(cherry picked from commit 9c55eab0309681991eae7382b682c26550786f56)

use AddRecalcMode(RECALCMODE_ONLOAD), fdo#60645 related

Instead of SetRecalcModeOnLoad() which sets the exclusive bit overriding
RECALCMODE_ALWAYS use AddRecalcMode() that handles these cases.

(cherry picked from commit ff319d052659974d1aa5d6ac8c468a7259a46cc4)

ocColumn and ocRow do not need recalc on load, fdo#60645 related

(cherry picked from commit 61c72ef4bebebdfa505176e7d5db82920ad3822e)

Change-Id: I86e2d2c8156e50c14e4e9ae269e8b97e4560c68f
---
M formula/source/core/api/FormulaCompiler.cxx
1 file changed, 6 insertions(+), 2 deletions(-)



diff --git a/formula/source/core/api/FormulaCompiler.cxx b/formula/source/core/api/FormulaCompiler.cxx
index 8323e15..468ecd3 100644
--- a/formula/source/core/api/FormulaCompiler.cxx
+++ b/formula/source/core/api/FormulaCompiler.cxx
@@ -1066,18 +1066,22 @@
                     // If the referred cell is moved the value changes.
                 case ocColumn :
                 case ocRow :
+                    pArr->SetRecalcModeOnRefMove();
+                break;
                     // ocCell needs recalc on move for some possible type values.
+                    // and recalc mode on load, fdo#60646
                 case ocCell :
                     pArr->SetRecalcModeOnRefMove();
+                    pArr->AddRecalcMode( RECALCMODE_ONLOAD );
                 break;
                 case ocHyperLink :
                     // cell with hyperlink needs to be calculated on load to
                     // get its matrix result generated.
-                    pArr->SetRecalcModeOnLoad();
+                    pArr->AddRecalcMode( RECALCMODE_ONLOAD );
                     pArr->SetHyperLink(true);
                 break;
                 case ocDde:
-                    pArr->SetRecalcModeOnLoad();
+                    pArr->AddRecalcMode( RECALCMODE_ONLOAD );
                 break;
                 default:
                     ;   // nothing

-- 
To view, visit https://gerrit.libreoffice.org/2168
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I86e2d2c8156e50c14e4e9ae269e8b97e4560c68f
Gerrit-PatchSet: 1
Gerrit-Project: core
Gerrit-Branch: libreoffice-4-0
Gerrit-Owner: Eike Rathke <erack at redhat.com>


More information about the LibreOffice mailing list