summaryrefslogtreecommitdiff
path: root/sc/source/ui/view/tabview2.cxx
diff options
context:
space:
mode:
authorobo <obo@openoffice.org>2010-06-23 13:38:34 +0200
committerobo <obo@openoffice.org>2010-06-23 13:38:34 +0200
commitb3579d71c6536ab1d03cc47249d582a574fd054a (patch)
tree5faa250b128f353ebfedd7481ad4ca7e8629433d /sc/source/ui/view/tabview2.cxx
parent67cd558ced4f52b7f431e138a1071e30e88ead53 (diff)
koheirowlimitperf: #i109369# #i109373# #i109384# #i109385# #i109386# #i109387# #i109388# #i109389# #i109391# #i109934# #i109935# #i110116# #i111531# #i111887# #i112190# #i30215# increased the row limit to 1 million, and integrated lots of speed optimization and bug fixes to ensure Calc remains usable after the row limit increase.
Diffstat (limited to 'sc/source/ui/view/tabview2.cxx')
-rw-r--r--sc/source/ui/view/tabview2.cxx15
1 files changed, 7 insertions, 8 deletions
diff --git a/sc/source/ui/view/tabview2.cxx b/sc/source/ui/view/tabview2.cxx
index b7a773ab2abd..674f6f8ae0ff 100644
--- a/sc/source/ui/view/tabview2.cxx
+++ b/sc/source/ui/view/tabview2.cxx
@@ -640,13 +640,13 @@ BOOL lcl_FitsInWindow( double fScaleX, double fScaleY, USHORT nZoom,
}
long nBlockY = 0;
- ScCoupledCompressedArrayIterator< SCROW, BYTE, USHORT> aIter(
- pDoc->GetRowFlagsArray( nTab), 0, nFixPosY-1, CR_HIDDEN, 0,
- pDoc->GetRowHeightArray( nTab));
- for ( ; aIter; ++aIter)
+ for (SCROW nRow = 0; nRow <= nFixPosY-1; ++nRow)
{
+ if (pDoc->RowHidden(nRow, nTab))
+ continue;
+
// for frozen panes, add both parts
- USHORT nRowTwips = *aIter;
+ USHORT nRowTwips = pDoc->GetRowHeight(nRow, nTab);
if (nRowTwips)
{
nBlockY += (long)(nRowTwips * fScaleY);
@@ -654,10 +654,9 @@ BOOL lcl_FitsInWindow( double fScaleX, double fScaleY, USHORT nZoom,
return FALSE;
}
}
- aIter.NewLimits( nStartRow, nEndRow);
- for ( ; aIter; ++aIter)
+ for (SCROW nRow = nStartRow; nRow <= nEndRow; ++nRow)
{
- USHORT nRowTwips = *aIter;
+ USHORT nRowTwips = pDoc->GetRowHeight(nRow, nTab);
if (nRowTwips)
{
nBlockY += (long)(nRowTwips * fScaleY);