diff options
author | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2013-01-30 05:36:02 +0100 |
---|---|---|
committer | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2013-01-30 19:32:05 +0100 |
commit | cd13c045846bb2af4eefc46dc8f020f6073b6054 (patch) | |
tree | a0d9cafadacab1c202a62748bbb60402cbd43d66 /sc | |
parent | 41281d375300512011113c69ddda5995463a3c88 (diff) |
unfriend this class and the method
Change-Id: I43645409bee380ef6664109c4480ca37c5f3ecd2
Diffstat (limited to 'sc')
-rw-r--r-- | sc/inc/attarray.hxx | 3 | ||||
-rw-r--r-- | sc/source/core/data/dociter.cxx | 14 |
2 files changed, 10 insertions, 7 deletions
diff --git a/sc/inc/attarray.hxx b/sc/inc/attarray.hxx index c56207abd67c..66db88a2094b 100644 --- a/sc/inc/attarray.hxx +++ b/sc/inc/attarray.hxx @@ -87,9 +87,6 @@ friend class ScDocument; // for FillInfo friend class ScDocumentIterator; friend class ScAttrIterator; friend class ScHorizontalAttrIterator; -friend void ScAttrArray_IterGetNumberFormat( sal_uLong& nFormat, - const ScAttrArray*& rpArr, SCROW& nAttrEndRow, - const ScAttrArray* pNewArr, SCROW nRow, ScDocument* pDoc ); bool ApplyFrame( const SvxBoxItem* pLineOuter, const SvxBoxInfoItem* pLineInner, SCROW nStartRow, SCROW nEndRow, diff --git a/sc/source/core/data/dociter.cxx b/sc/source/core/data/dociter.cxx index cfcc52ac0059..9d6098d7f3a1 100644 --- a/sc/source/core/data/dociter.cxx +++ b/sc/source/core/data/dociter.cxx @@ -222,12 +222,18 @@ void ScAttrArray_IterGetNumberFormat( sal_uLong& nFormat, const ScAttrArray*& rp { if ( rpArr != pNewArr || nAttrEndRow < nRow ) { - SCSIZE nPos; - pNewArr->Search( nRow, nPos ); // nPos 0 gueltig wenn nicht gefunden - const ScPatternAttr* pPattern = pNewArr->pData[nPos].pPattern; + SCROW nRowStart = 0; + SCROW nRowEnd = MAXROW; + const ScPatternAttr* pPattern; + if( !(pPattern = pNewArr->GetPatternRange( nRowStart, nRowEnd, nRow ) ) ) + { + pPattern = pDoc->GetDefPattern(); + nRowEnd = MAXROW; + } + nFormat = pPattern->GetNumberFormat( pDoc->GetFormatTable() ); rpArr = pNewArr; - nAttrEndRow = pNewArr->pData[nPos].nRow; + nAttrEndRow = nRowEnd; } } |