From 3d13da021afc5e0786dc95ea707fbea50616ded1 Mon Sep 17 00:00:00 2001 From: Takeshi Abe Date: Tue, 21 Aug 2018 16:50:01 +0900 Subject: [PATCH] sw: Prefer std::vector to undemanded std::list Change-Id: I2003538f3a7cff2163cbb85f948c0bab9187dfeb Reviewed-on: https://gerrit.libreoffice.org/59379 Tested-by: Jenkins Reviewed-by: Noel Grandin --- sw/source/core/edit/eddel.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sw/source/core/edit/eddel.cxx b/sw/source/core/edit/eddel.cxx index f60fcbc5be54..658a650c8048 100644 --- a/sw/source/core/edit/eddel.cxx +++ b/sw/source/core/edit/eddel.cxx @@ -33,7 +33,7 @@ #include #include -#include +#include void SwEditShell::DeleteSel( SwPaM& rPam, bool* pUndo ) { @@ -158,7 +158,7 @@ bool SwEditShell::Copy( SwEditShell* pDestShell ) SET_CURR_SHELL( pDestShell ); // List of insert positions for smart insert of block selections - std::list< std::shared_ptr > aInsertList; + std::vector< std::shared_ptr > aInsertList; // Fill list of insert positions { @@ -210,7 +210,7 @@ bool SwEditShell::Copy( SwEditShell* pDestShell ) SwNodeIndex aSttNdIdx( pDestShell->GetDoc()->GetNodes() ); sal_Int32 nSttCntIdx = 0; // For block selection this list is filled with the insert positions - std::list< std::shared_ptr >::iterator pNextInsert = aInsertList.begin(); + auto pNextInsert = aInsertList.begin(); pDestShell->GetDoc()->GetIDocumentUndoRedo().StartUndo( SwUndoId::START, nullptr ); for(SwPaM& rPaM : GetCursor()->GetRingContainer())