diff options
author | Takeshi Abe <tabe@fixedpoint.jp> | 2018-08-07 18:45:46 +0900 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-08-07 16:07:20 +0200 |
commit | fed411f4b66888afbc5056b4ec7d6b176b0340ad (patch) | |
tree | 6e5a1434f4a9b96cb625d54320778f9dcf17fe0c /sw/source | |
parent | 92a4e4eac7520541a433e40836cafa4e29edf47f (diff) |
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.grandin@collabora.co.uk>
Diffstat (limited to 'sw/source')
-rw-r--r-- | sw/source/core/table/swnewtable.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
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 : |