[Libreoffice-commits] core.git: Branch 'feature/formula-core-rework' - sc/source

Kohei Yoshida kohei.yoshida at gmail.com
Thu Apr 25 08:22:40 PDT 2013


 sc/source/core/data/formulacell.cxx |   17 ++++++++++++++++-
 1 file changed, 16 insertions(+), 1 deletion(-)

New commits:
commit 300b57c602e3a55d357ecedf3c663a4f0380648d
Author: Kohei Yoshida <kohei.yoshida at gmail.com>
Date:   Thu Apr 25 11:23:41 2013 -0400

    We can't support all cases until we have real range-based dep tracking.
    
    Note that an absolute reference may indirectly reference one of the cells
    in current formula group, and we aren't fully prepare for that use case
    yet.
    
    Change-Id: Ibd24a25b80963fe1235c2afb431ff7c7ceb27215

diff --git a/sc/source/core/data/formulacell.cxx b/sc/source/core/data/formulacell.cxx
index fe956f5..e73641d 100644
--- a/sc/source/core/data/formulacell.cxx
+++ b/sc/source/core/data/formulacell.cxx
@@ -2948,9 +2948,24 @@ bool ScFormulaCell::InterpretFormulaGroup()
     // import / insert / delete etc. and is integral to the data structures
     pDocument->RebuildFormulaGroups();
 
-    if( !xGroup.get() )
+    if (!xGroup || !pCode)
         return false;
 
+    switch (pCode->GetVectorState())
+    {
+        case FormulaVectorEnabled:
+            // Good.
+        break;
+        case FormulaVectorCheckReference:
+            // To support this we would need a real range-based dependency
+            // tracking. We can't support this right now.
+            return false;
+        case FormulaVectorDisabled:
+        case FormulaVectorUnknown:
+        default:
+            return false;
+    }
+
 //    fprintf( stderr, "Interpret cell %d, %d\n", (int)aPos.Col(), (int)aPos.Row() );
 
     if (xGroup->mbInvariant)


More information about the Libreoffice-commits mailing list