sw/inc/docary.hxx | 3 +++ sw/source/core/doc/CntntIdxStore.cxx | 6 +++--- 2 files changed, 6 insertions(+), 3 deletions(-)
New commits: commit e8193627922ee328d17250ec518ecd4ba342c97d Author: Bjoern Michaelsen <bjoern.michael...@canonical.com> Date: Fri Jul 25 10:21:16 2014 +0200 use the Redline iterator Change-Id: Ia15e5a376b2a7503f56f183a555e21d1122fe66f diff --git a/sw/source/core/doc/CntntIdxStore.cxx b/sw/source/core/doc/CntntIdxStore.cxx index 56c554d..ee22f86 100644 --- a/sw/source/core/doc/CntntIdxStore.cxx +++ b/sw/source/core/doc/CntntIdxStore.cxx @@ -264,10 +264,9 @@ void CntntIdxStoreImpl::RestoreBkmks(SwDoc* pDoc, updater_t& rUpdater) void CntntIdxStoreImpl::SaveRedlines(SwDoc* pDoc, sal_uLong nNode, sal_Int32 nCntnt) { - const SwRedlineTbl& rRedlTbl = pDoc->GetRedlineTbl(); - for( long int nIdx = 0 ; static_cast<unsigned long int>(nIdx) < rRedlTbl.size(); ++nIdx ) + long int nIdx = 0; + BOOST_FOREACH(const SwRangeRedline* pRdl, pDoc->GetRedlineTbl()) { - const SwRangeRedline* pRdl = rRedlTbl[ nIdx ]; int nPointPos = lcl_RelativePosition( *pRdl->GetPoint(), nNode, nCntnt ); int nMarkPos = pRdl->HasMark() ? lcl_RelativePosition( *pRdl->GetMark(), nNode, nCntnt ) : nPointPos; @@ -286,6 +285,7 @@ void CntntIdxStoreImpl::SaveRedlines(SwDoc* pDoc, sal_uLong nNode, sal_Int32 nCn const MarkEntry aEntry = { nIdx, true, pRdl->GetMark()->nContent.GetIndex() }; m_aRedlineEntries.push_back(aEntry); } + ++nIdx; } } commit 46c3eca442c31663ac0a907769e65679af090920 Author: Bjoern Michaelsen <bjoern.michael...@canonical.com> Date: Fri Jul 25 10:21:09 2014 +0200 a const_iterator for Redlines Change-Id: I22481191d5cbc905a9af7530e075acda21fcbeba diff --git a/sw/inc/docary.hxx b/sw/inc/docary.hxx index 94f8229..e9e3b6f 100644 --- a/sw/inc/docary.hxx +++ b/sw/inc/docary.hxx @@ -192,6 +192,9 @@ public: */ const SwRangeRedline* FindAtPosition( const SwPosition& startPosition, sal_uInt16& tableIndex, bool next = true ) const; + using _SwRedlineTbl::const_iterator; + using _SwRedlineTbl::begin; + using _SwRedlineTbl::end; using _SwRedlineTbl::size; using _SwRedlineTbl::operator[]; using _SwRedlineTbl::empty; _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits