diff options
-rw-r--r-- | editeng/inc/editeng/outliner.hxx | 2 | ||||
-rw-r--r-- | editeng/source/outliner/outlvw.cxx | 7 |
2 files changed, 4 insertions, 5 deletions
diff --git a/editeng/inc/editeng/outliner.hxx b/editeng/inc/editeng/outliner.hxx index e6e3164cd2df..8cec3ae4d47f 100644 --- a/editeng/inc/editeng/outliner.hxx +++ b/editeng/inc/editeng/outliner.hxx @@ -281,7 +281,7 @@ public: Rectangle GetVisArea() const; - List* CreateSelectionList(); + void CreateSelectionList (std::vector<Paragraph*> &aSelList) ; // Retruns the number of selected paragraphs ULONG Select( Paragraph* pParagraph, diff --git a/editeng/source/outliner/outlvw.cxx b/editeng/source/outliner/outlvw.cxx index ff66af048c18..7d43f04d9141 100644 --- a/editeng/source/outliner/outlvw.cxx +++ b/editeng/source/outliner/outlvw.cxx @@ -1039,18 +1039,17 @@ void OutlinerView::PasteSpecial() } } -List* OutlinerView::CreateSelectionList() +void OutlinerView::CreateSelectionList (std::vector<Paragraph*> &aSelList) { DBG_CHKTHIS( OutlinerView, 0 ); ParaRange aParas = ImpGetSelectedParagraphs( TRUE ); - List* pSelList = new List; + for ( USHORT nPara = aParas.nStartPara; nPara <= aParas.nEndPara; nPara++ ) { Paragraph* pPara = pOwner->pParaList->GetParagraph( nPara ); - pSelList->Insert( pPara, LIST_APPEND ); + aSelList.push_back(pPara); } - return pSelList; } SfxStyleSheet* OutlinerView::GetStyleSheet() const |