sw/source/core/table/swnewtable.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
New commits: commit fed411f4b66888afbc5056b4ec7d6b176b0340ad Author: Takeshi Abe <t...@fixedpoint.jp> AuthorDate: Tue Aug 7 18:45:46 2018 +0900 Commit: Noel Grandin <noel.gran...@collabora.co.uk> CommitDate: Tue Aug 7 16:07:20 2018 +0200 sw: Replace std::list with std::vector for simplicity Change-Id: I91c4c1d53f1cea0aebbdc2cc1548cad86d5226a4 Reviewed-on: https://gerrit.libreoffice.org/58675 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk> diff --git a/sw/source/core/table/swnewtable.cxx b/sw/source/core/table/swnewtable.cxx index 33fb40cd0319..e9398fd42414 100644 --- a/sw/source/core/table/swnewtable.cxx +++ b/sw/source/core/table/swnewtable.cxx @@ -1309,7 +1309,7 @@ static sal_uInt16 lcl_CalculateSplitLineHeights( SwSplitLines &rCurr, SwSplitLin { if( nCnt < 2 ) return 0; - std::list< SwLineOffset > aBoxes; + std::vector< SwLineOffset > aBoxes; SwLineOffset aLnOfs( USHRT_MAX, USHRT_MAX ); sal_uInt16 nFirst = USHRT_MAX; // becomes the index of the first line sal_uInt16 nLast = 0; // becomes the index of the last line of the splitting @@ -1325,7 +1325,7 @@ static sal_uInt16 lcl_CalculateSplitLineHeights( SwSplitLines &rCurr, SwSplitLin { aLnOfs.first = nStart; aLnOfs.second = nEnd; - aBoxes.insert( aBoxes.end(), aLnOfs ); + aBoxes.push_back( aLnOfs ); if( nStart < nFirst ) nFirst = nStart; if( nEnd > nLast ) @@ -1348,7 +1348,7 @@ static sal_uInt16 lcl_CalculateSplitLineHeights( SwSplitLines &rCurr, SwSplitLin rCurr.insert( rCurr.end(), nHeight ); pLines[ i - nFirst ] = nHeight; } - std::list< SwLineOffset >::iterator pSplit = aBoxes.begin(); + auto pSplit = aBoxes.begin(); while( pSplit != aBoxes.end() ) { SwTwips nBase = pSplit->first <= nFirst ? 0 : _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits