[Libreoffice-commits] .: 9 commits - sc/source

Jan Holesovsky kendy at kemper.freedesktop.org
Fri Nov 12 06:53:11 PST 2010


 sc/source/ui/view/drawvie4.cxx |    2 +-
 sc/source/ui/view/drawview.cxx |    2 +-
 sc/source/ui/view/gridwin3.cxx |    2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 38111ed0318955759a2f58d50b241987da8435da
Merge: 7ea19b7... 4e90bb8...
Author: Jan Holesovsky <kendy at suse.cz>
Date:   Fri Nov 12 15:50:57 2010 +0100

    Merge branch 'master' of ssh://git.freedesktop.org/git/libreoffice/calc

commit 7ea19b73fc2ea93403a8a92cca6f90bae365074a
Merge: 7fd06a7... 8f416ac...
Author: Jan Holesovsky <kendy at suse.cz>
Date:   Fri Nov 12 14:27:26 2010 +0100

    Merge remote branch 'origin/libreoffice-3-3'

commit 8f416acd20a702f4dbb28f28b0e01b98d0e87925
Merge: 2e9051f... 2d9884e...
Author: Jan Holesovsky <kendy at suse.cz>
Date:   Thu Nov 11 18:10:07 2010 +0100

    Merge commit 'ooo/OOO330_m14' into libreoffice-3-3

commit 2e9051f0ecc9dd334d05936dd58dc17775301ca9
Author: Petr Mladek <pmladek at suse.cz>
Date:   Thu Nov 11 13:24:50 2010 +0100

    Version 3.2.99.3, tag LIBREOFFICE_3_2_99_3 (3.3-beta3)
commit ab1d9ed24f22a4b840f49ba8ba6cc3a55840d3f7
Author: Tor Lillqvist <tlillqvist at novell.com>
Date:   Fri Nov 5 11:10:11 2010 +0200

    Fix Windows build error
    
    Include <windows.h> explicitly, surrounded by the prewin.h and
    postwin.h headers. Also #undef ERROR to avoid a clash. Approved by
    caolan.

diff --git a/sc/qa/unit/ucalc.cxx b/sc/qa/unit/ucalc.cxx
index f024881..2e63f3b 100644
--- a/sc/qa/unit/ucalc.cxx
+++ b/sc/qa/unit/ucalc.cxx
@@ -16,6 +16,13 @@
 //                 the need for manually calling regcomp and knowing what
 //                 services we need, and in what .so they are implemented
 
+#ifdef WNT
+# include <tools/prewin.h>
+# include <windows.h>
+# include <tools/postwin.h>
+# undef ERROR
+#endif
+
 #include "sal/config.h"
 
 #include <cppuhelper/bootstrap.hxx>
commit 3a06b860b69fdbe25317b44c4b13581bd88e736c
Author: Kohei Yoshida <kyoshida at novell.com>
Date:   Mon Nov 8 16:27:37 2010 -0500

    Fixed a crash on importing named ranges on higher sheets.
    
    When importing xls document containing named ranges on sheets higher
    than 256 (max number of sheets Calc supports currently), Calc would
    crash.  We need to check for the upper boundary condition before
    accessing the array by index to prevent crash. (n#649941)

diff --git a/sc/source/filter/excel/frmbase.cxx b/sc/source/filter/excel/frmbase.cxx
index 1cfc295..868b927 100644
--- a/sc/source/filter/excel/frmbase.cxx
+++ b/sc/source/filter/excel/frmbase.cxx
@@ -104,7 +104,7 @@ void _ScRangeListTabs::Append( ScSingleRefData a, SCsTAB nTab, const BOOL b )
     if( nTab < 0)
         nTab = a.nTab;
 
-    if( nTab >= 0 )
+    if( nTab >= 0 && nTab <= MAXTAB)
     {
         _ScRangeList*   p = ppTabLists[ nTab ];
 
@@ -169,7 +169,7 @@ void _ScRangeListTabs::Append( ScComplexRefData a, SCsTAB nTab, const BOOL b )
     if( nTab < -1)
         nTab = a.Ref1.nTab;
 
-    if( nTab >= 0 )
+    if( nTab >= 0 && nTab <= MAXTAB)
     {
         _ScRangeList*   p = ppTabLists[ nTab ];
 
commit 2d9884e79d5885ee708e29dbd21b13ad0c3e6631
Merge: 2a75245... 1a647a5...
Author: Kurt Zenker <kz at openoffice.org>
Date:   Fri Nov 5 16:56:27 2010 +0100

    CWS-TOOLING: integrate CWS calc33stopper2

commit 55cd5ed89d0eb1f3be976d592438fa9f8fabc52d
Author: Kohei Yoshida <kyoshida at novell.com>
Date:   Wed Nov 3 14:41:59 2010 -0400

    Set correct default formula syntax value in case it's not explicitly set.
    
    When starting from a fresh config, Calc failed to assign default 'Calc A1'
    syntax unless the user specifically goes to the Options page and sets the
    formula syntax in the Calc - Formula options page.  This caused e.g.
    print range editing to fail miserably. (fdo#31041)

diff --git a/sc/source/core/tool/docoptio.cxx b/sc/source/core/tool/docoptio.cxx
index 50fb8cb..ccc5eae 100644
--- a/sc/source/core/tool/docoptio.cxx
+++ b/sc/source/core/tool/docoptio.cxx
@@ -452,7 +452,8 @@ ScDocCfg::ScDocCfg() :
             {
                 case SCFORMULAOPT_GRAMMAR:
                 {
-                    ::formula::FormulaGrammar::Grammar eGram = ::formula::FormulaGrammar::GRAM_DEFAULT;
+                    // Get default value in case this option is not set.
+                    ::formula::FormulaGrammar::Grammar eGram = GetFormulaSyntax();
 
                     do
                     {
@@ -471,6 +472,8 @@ ScDocCfg::ScDocCfg() :
                             case 2: // Excel R1C1
                                 eGram = ::formula::FormulaGrammar::GRAM_NATIVE_XL_R1C1;
                             break;
+                            default:
+                                ;
                         }
                     }
                     while (false);
commit 1a647a5e1b76e24cf250ef66dc9604e956e3112d
Author: Daniel Rentz [dr] <daniel.rentz at oracle.com>
Date:   Tue Nov 2 17:28:24 2010 +0100

    calc33stopper2: #i115313# revert calculation of scaling factor for drawing layer to behaviour of OOo 3.2

diff --git a/sc/source/ui/view/drawvie4.cxx b/sc/source/ui/view/drawvie4.cxx
index 0d0f0a0..3d47dca 100644
--- a/sc/source/ui/view/drawvie4.cxx
+++ b/sc/source/ui/view/drawvie4.cxx
@@ -282,7 +282,7 @@ void ScDrawView::CalcNormScale( Fraction& rFractX, Fraction& rFractY ) const
     pDoc->GetTableArea( nTab, nEndCol, nEndRow );
     if (nEndCol<20)
         nEndCol = 20;
-    if (nEndRow<1000)
+    if (nEndRow<20)
         nEndRow = 1000;
 
     Fraction aZoom(1,1);
diff --git a/sc/source/ui/view/drawview.cxx b/sc/source/ui/view/drawview.cxx
index 921f256..2564360 100644
--- a/sc/source/ui/view/drawview.cxx
+++ b/sc/source/ui/view/drawview.cxx
@@ -376,7 +376,7 @@ void ScDrawView::RecalcScale()
     pDoc->GetTableArea( nTab, nEndCol, nEndRow );
     if (nEndCol<20)
         nEndCol = 20;
-    if (nEndRow<1000)
+    if (nEndRow<20)
         nEndRow = 1000;
 
     ScDrawUtil::CalcScale( pDoc, nTab, 0,0, nEndCol,nEndRow, pDev,aZoomX,aZoomY,nPPTX,nPPTY,
diff --git a/sc/source/ui/view/gridwin3.cxx b/sc/source/ui/view/gridwin3.cxx
index 9ba9ee6..3be1427 100644
--- a/sc/source/ui/view/gridwin3.cxx
+++ b/sc/source/ui/view/gridwin3.cxx
@@ -265,7 +265,7 @@ MapMode ScGridWindow::GetDrawMapMode( BOOL bForce )
             SCROW nEndRow = 0;
             pDoc->GetTableArea( nTab, nEndCol, nEndRow );
             if (nEndCol<20) nEndCol = 20;
-            if (nEndRow<1000) nEndRow = 1000;
+            if (nEndRow<20) nEndRow = 1000;
             ScDrawUtil::CalcScale( pDoc, nTab, 0,0, nEndCol,nEndRow, this,
                                     pViewData->GetZoomX(),pViewData->GetZoomY(),
                                     pViewData->GetPPTX(),pViewData->GetPPTY(),


More information about the Libreoffice-commits mailing list