summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuboš Luňák <l.lunak@collabora.com>2022-02-04 21:59:05 +0100
committerLuboš Luňák <l.lunak@collabora.com>2022-02-08 16:21:41 +0100
commitcf8408bfcbaca2998d47a56df9f1dc6f3cb98b0e (patch)
tree080f01625c754ff8796b4b268b94300217459f2c
parent7ac06bdbf8a2b9fed512ae7817131f26f3744898 (diff)
make the large-sheet maxrow value pow2-based and not pow10-based
All the other limits are powers of 2, I see no good reason why this one should be 16000000 and not 16777216. Also at least ScBroadcastAreaSlotMachine actually requires the values to be powers of 2, otherwise the logarithmic algorithm in its ctor will miss some rows at the end. Change-Id: Iee30a271e9e67d092c34d2e4175cb672e6f737a4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/129588 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
-rw-r--r--sc/inc/address.hxx2
-rw-r--r--sc/qa/unit/jumbosheets-test.cxx2
2 files changed, 2 insertions, 2 deletions
diff --git a/sc/inc/address.hxx b/sc/inc/address.hxx
index 40ac5e8b590e..a5f25f2bd87c 100644
--- a/sc/inc/address.hxx
+++ b/sc/inc/address.hxx
@@ -69,7 +69,7 @@ const SCROW MAXROW = MAXROWCOUNT - 1;
const SCCOL MAXCOL = MAXCOLCOUNT - 1;
const SCTAB MAXTAB = MAXTABCOUNT - 1;
const SCCOLROW MAXCOLROW = MAXROW;
-const SCROW MAXROW_JUMBO = 16 * 1000 * 1000 - 1;
+const SCROW MAXROW_JUMBO = 16 * 1024 * 1024 - 1;
const SCCOL MAXCOL_JUMBO = 16384 - 1;
// Maximum tiled rendering values
const SCROW MAXTILEDROW = 500000;
diff --git a/sc/qa/unit/jumbosheets-test.cxx b/sc/qa/unit/jumbosheets-test.cxx
index 6f94332ab149..3f3f1320472e 100644
--- a/sc/qa/unit/jumbosheets-test.cxx
+++ b/sc/qa/unit/jumbosheets-test.cxx
@@ -110,7 +110,7 @@ void ScFiltersTest::testTdf133033()
ScViewData& rViewData = pViewShell->GetViewData();
CPPUNIT_ASSERT_EQUAL(sal_Int16(0), rViewData.GetCurX());
- CPPUNIT_ASSERT_EQUAL(sal_Int32(15999999), rViewData.GetCurY());
+ CPPUNIT_ASSERT_EQUAL(sal_Int32(16777215), rViewData.GetCurY());
}
ScFiltersTest::ScFiltersTest()