[Libreoffice-commits] .: sc/source
Pierre-André Jacquod
pjacquod at kemper.freedesktop.org
Sun Nov 27 09:20:05 PST 2011
sc/source/core/data/table1.cxx | 7 +++++--
sc/source/core/tool/dbdata.cxx | 2 +-
2 files changed, 6 insertions(+), 3 deletions(-)
New commits:
commit 88611e702a18d2a281c22b6d9c28e881be3df223
Author: Pierre-André Jacquod <pjacquod at alumni.ethz.ch>
Date: Sun Nov 27 18:17:32 2011 +0100
fdo#42286 call correctly GetDataArea to avoid unwanted shrinking
GetDataArea flags documented and call from ExtendedDataArea adapted.
diff --git a/sc/source/core/data/table1.cxx b/sc/source/core/data/table1.cxx
index b746ffc..3cf1ca1 100644
--- a/sc/source/core/data/table1.cxx
+++ b/sc/source/core/data/table1.cxx
@@ -741,9 +741,12 @@ bool ScTable::GetDataStart( SCCOL& rStartCol, SCROW& rStartRow ) const
void ScTable::GetDataArea( SCCOL& rStartCol, SCROW& rStartRow, SCCOL& rEndCol, SCROW& rEndRow,
bool bIncludeOld, bool bOnlyDown ) const
{
- bool bLeft = false;
+ // bIncludeOld = true ensure that the returned area contains at least the initial area,
+ // independently of the case if this area has empty rows / columns at its borders
+ // bOnlyDown = true means extend the inputed area only down, i.e increase only rEndRow
+ bool bLeft = false;
bool bRight = false;
- bool bTop = false;
+ bool bTop = false;
bool bBottom = false;
bool bChanged;
bool bFound;
diff --git a/sc/source/core/tool/dbdata.cxx b/sc/source/core/tool/dbdata.cxx
index e897630..7014601 100644
--- a/sc/source/core/tool/dbdata.cxx
+++ b/sc/source/core/tool/dbdata.cxx
@@ -548,7 +548,7 @@ void ScDBData::ExtendDataArea(ScDocument* pDoc)
// Extend the DB area to include data rows immediately below.
SCCOL nCol1a = nStartCol, nCol2a = nEndCol;
SCROW nRow1a = nStartRow, nRow2a = nEndRow;
- pDoc->GetDataArea(nTable, nCol1a, nRow1a, nCol2a, nRow2a, false, false);
+ pDoc->GetDataArea(nTable, nCol1a, nRow1a, nCol2a, nRow2a, true, true);
nEndRow = nRow2a;
}
More information about the Libreoffice-commits
mailing list