summaryrefslogtreecommitdiff
path: root/sc/source
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source')
-rw-r--r--sc/source/core/data/attarray.cxx16
-rw-r--r--sc/source/core/data/clipcontext.cxx2
-rw-r--r--sc/source/core/data/column.cxx14
-rw-r--r--sc/source/core/data/column2.cxx6
-rw-r--r--sc/source/core/data/column3.cxx4
-rw-r--r--sc/source/core/data/column4.cxx2
-rw-r--r--sc/source/core/data/conditio.cxx6
-rw-r--r--sc/source/core/data/documen2.cxx2
-rw-r--r--sc/source/core/data/documen3.cxx4
-rw-r--r--sc/source/core/data/documen4.cxx2
-rw-r--r--sc/source/core/data/documen8.cxx8
-rw-r--r--sc/source/core/data/document.cxx10
-rw-r--r--sc/source/core/data/document10.cxx6
-rw-r--r--sc/source/core/data/documentimport.cxx6
-rw-r--r--sc/source/core/data/dpgroup.cxx2
-rw-r--r--sc/source/core/data/dpobject.cxx2
-rw-r--r--sc/source/core/data/dpsave.cxx72
-rw-r--r--sc/source/core/data/dptabres.cxx6
-rw-r--r--sc/source/core/data/dptabsrc.cxx70
-rw-r--r--sc/source/core/data/formulacell.cxx8
-rw-r--r--sc/source/core/data/funcdesc.cxx6
-rw-r--r--sc/source/core/data/listenercontext.cxx4
-rw-r--r--sc/source/core/data/table1.cxx60
-rw-r--r--sc/source/core/data/table2.cxx2
-rw-r--r--sc/source/core/data/table3.cxx15
-rw-r--r--sc/source/core/data/table4.cxx4
-rw-r--r--sc/source/core/data/validat.cxx6
-rw-r--r--sc/source/core/opencl/formulagroupcl.cxx15
-rw-r--r--sc/source/core/opencl/opbase.hxx6
-rw-r--r--sc/source/core/tool/chartlis.cxx16
-rw-r--r--sc/source/core/tool/chgtrack.cxx6
-rw-r--r--sc/source/core/tool/interpr1.cxx2
-rw-r--r--sc/source/core/tool/interpr7.cxx14
-rw-r--r--sc/source/core/tool/rangenam.cxx8
-rw-r--r--sc/source/core/tool/reftokenhelper.cxx4
-rw-r--r--sc/source/filter/dif/difimp.cxx4
-rw-r--r--sc/source/filter/excel/excel.cxx4
-rw-r--r--sc/source/filter/excel/read.cxx6
-rw-r--r--sc/source/filter/excel/xechart.cxx4
-rw-r--r--sc/source/filter/excel/xecontent.cxx6
-rw-r--r--sc/source/filter/excel/xeformula.cxx14
-rw-r--r--sc/source/filter/excel/xelink.cxx4
-rw-r--r--sc/source/filter/excel/xestyle.cxx2
-rw-r--r--sc/source/filter/excel/xichart.cxx2
-rw-r--r--sc/source/filter/excel/xiescher.cxx7
-rw-r--r--sc/source/filter/excel/xilink.cxx2
-rw-r--r--sc/source/filter/excel/xiname.cxx10
-rw-r--r--sc/source/filter/excel/xlpivot.cxx6
-rw-r--r--sc/source/filter/html/htmlpars.cxx33
-rw-r--r--sc/source/filter/inc/autofilterbuffer.hxx2
-rw-r--r--sc/source/filter/inc/biffcodec.hxx2
-rw-r--r--sc/source/filter/inc/excelhandlers.hxx4
-rw-r--r--sc/source/filter/inc/formulabase.hxx4
-rw-r--r--sc/source/filter/inc/ftools.hxx1
-rw-r--r--sc/source/filter/inc/htmlexp.hxx4
-rw-r--r--sc/source/filter/inc/imp_op.hxx6
-rw-r--r--sc/source/filter/inc/ooxformulaparser.hxx4
-rw-r--r--sc/source/filter/inc/workbookhelper.hxx4
-rw-r--r--sc/source/filter/inc/worksheethelper.hxx2
-rw-r--r--sc/source/filter/inc/xecontent.hxx12
-rw-r--r--sc/source/filter/inc/xeformula.hxx4
-rw-r--r--sc/source/filter/inc/xelink.hxx4
-rw-r--r--sc/source/filter/inc/xename.hxx4
-rw-r--r--sc/source/filter/inc/xestream.hxx2
-rw-r--r--sc/source/filter/inc/xestyle.hxx21
-rw-r--r--sc/source/filter/inc/xichart.hxx68
-rw-r--r--sc/source/filter/inc/xiescher.hxx49
-rw-r--r--sc/source/filter/inc/xiformula.hxx4
-rw-r--r--sc/source/filter/inc/xihelper.hxx4
-rw-r--r--sc/source/filter/inc/xiname.hxx4
-rw-r--r--sc/source/filter/inc/xiroot.hxx50
-rw-r--r--sc/source/filter/inc/xistream.hxx4
-rw-r--r--sc/source/filter/inc/xistyle.hxx4
-rw-r--r--sc/source/filter/inc/xlformula.hxx6
-rw-r--r--sc/source/filter/inc/xlpage.hxx3
-rw-r--r--sc/source/filter/inc/xlpivot.hxx4
-rw-r--r--sc/source/filter/inc/xlroot.hxx18
-rw-r--r--sc/source/filter/inc/xlview.hxx6
-rw-r--r--sc/source/filter/oox/formulabuffer.cxx6
-rw-r--r--sc/source/filter/oox/revisionfragment.cxx4
-rw-r--r--sc/source/filter/oox/stylesbuffer.cxx2
-rw-r--r--sc/source/filter/oox/workbookfragment.cxx6
-rw-r--r--sc/source/filter/oox/workbookhelper.cxx6
-rw-r--r--sc/source/filter/orcus/interface.cxx2
-rw-r--r--sc/source/filter/rtf/eeimpars.cxx2
-rw-r--r--sc/source/filter/xcl97/xcl97rec.cxx6
-rw-r--r--sc/source/filter/xml/XMLExportIterator.hxx4
-rw-r--r--sc/source/filter/xml/XMLStylesImportHelper.hxx20
-rw-r--r--sc/source/filter/xml/xmlbodyi.cxx4
-rw-r--r--sc/source/filter/xml/xmlcelli.cxx4
-rw-r--r--sc/source/filter/xml/xmlcelli.hxx4
-rw-r--r--sc/source/filter/xml/xmldpimp.hxx2
-rw-r--r--sc/source/filter/xml/xmldrani.hxx4
-rw-r--r--sc/source/filter/xml/xmlexprt.cxx6
-rw-r--r--sc/source/filter/xml/xmlexprt.hxx8
-rw-r--r--sc/source/filter/xml/xmlimprt.cxx2
-rw-r--r--sc/source/filter/xml/xmlimprt.hxx12
-rw-r--r--sc/source/filter/xml/xmlnexpi.hxx4
-rw-r--r--sc/source/filter/xml/xmlsubti.cxx6
-rw-r--r--sc/source/ui/StatisticsDialogs/AnalysisOfVarianceDialog.cxx2
-rw-r--r--sc/source/ui/StatisticsDialogs/ExponentialSmoothingDialog.cxx2
-rw-r--r--sc/source/ui/StatisticsDialogs/MovingAverageDialog.cxx2
-rw-r--r--sc/source/ui/StatisticsDialogs/TableFillingAndNavigationTools.cxx4
-rw-r--r--sc/source/ui/app/inputhdl.cxx2
-rw-r--r--sc/source/ui/app/uiitems.cxx20
-rw-r--r--sc/source/ui/cctrl/checklistmenu.cxx46
-rw-r--r--sc/source/ui/condformat/condformatdlgentry.cxx2
-rw-r--r--sc/source/ui/dbgui/PivotLayoutTreeList.cxx2
-rw-r--r--sc/source/ui/dbgui/PivotLayoutTreeListData.cxx2
-rw-r--r--sc/source/ui/dbgui/pvfundlg.cxx1
-rw-r--r--sc/source/ui/docshell/docfunc.cxx14
-rw-r--r--sc/source/ui/docshell/docfuncutil.cxx2
-rw-r--r--sc/source/ui/docshell/docsh.cxx4
-rw-r--r--sc/source/ui/docshell/docsh3.cxx4
-rw-r--r--sc/source/ui/docshell/docsh4.cxx10
-rw-r--r--sc/source/ui/docshell/documentlinkmgr.cxx8
-rw-r--r--sc/source/ui/docshell/externalrefmgr.cxx6
-rw-r--r--sc/source/ui/docshell/impex.cxx8
-rw-r--r--sc/source/ui/drawfunc/drawsh.cxx16
-rw-r--r--sc/source/ui/drawfunc/drawsh5.cxx6
-rw-r--r--sc/source/ui/drawfunc/drtxtob.cxx4
-rw-r--r--sc/source/ui/drawfunc/drtxtob1.cxx8
-rw-r--r--sc/source/ui/drawfunc/fuins2.cxx4
-rw-r--r--sc/source/ui/drawfunc/mediash.cxx4
-rw-r--r--sc/source/ui/formdlg/formula.cxx2
-rw-r--r--sc/source/ui/inc/checklistmenu.hxx16
-rw-r--r--sc/source/ui/inc/condformatdlgentry.hxx2
-rw-r--r--sc/source/ui/inc/datastream.hxx1
-rw-r--r--sc/source/ui/inc/docfuncutil.hxx4
-rw-r--r--sc/source/ui/inc/docsh.hxx4
-rw-r--r--sc/source/ui/inc/filtdlg.hxx1
-rw-r--r--sc/source/ui/inc/pvfundlg.hxx8
-rw-r--r--sc/source/ui/inc/retypepassdlg.hxx6
-rw-r--r--sc/source/ui/inc/tabview.hxx1
-rw-r--r--sc/source/ui/inc/uiitems.hxx4
-rw-r--r--sc/source/ui/inc/undoblk.hxx13
-rw-r--r--sc/source/ui/inc/undocell.hxx11
-rw-r--r--sc/source/ui/inc/undodat.hxx4
-rw-r--r--sc/source/ui/inc/undotab.hxx19
-rw-r--r--sc/source/ui/inc/viewdata.hxx4
-rw-r--r--sc/source/ui/inc/xmlsourcedlg.hxx4
-rw-r--r--sc/source/ui/miscdlgs/anyrefdg.cxx4
-rw-r--r--sc/source/ui/miscdlgs/scuiautofmt.cxx1
-rw-r--r--sc/source/ui/miscdlgs/tabbgcolordlg.cxx2
-rw-r--r--sc/source/ui/pagedlg/scuitphfedit.cxx12
-rw-r--r--sc/source/ui/pagedlg/tphf.cxx4
-rw-r--r--sc/source/ui/pagedlg/tphfedit.cxx4
-rw-r--r--sc/source/ui/sidebar/CellAppearancePropertyPanel.hxx8
-rw-r--r--sc/source/ui/sidebar/CellBorderStyleControl.cxx6
-rw-r--r--sc/source/ui/sidebar/NumberFormatPropertyPanel.hxx1
-rw-r--r--sc/source/ui/undo/undoblk.cxx4
-rw-r--r--sc/source/ui/undo/undoblk3.cxx2
-rw-r--r--sc/source/ui/undo/undocell.cxx2
-rw-r--r--sc/source/ui/undo/undotab.cxx8
-rw-r--r--sc/source/ui/unoobj/cellsuno.cxx21
-rw-r--r--sc/source/ui/unoobj/chart2uno.cxx58
-rw-r--r--sc/source/ui/unoobj/condformatuno.cxx4
-rw-r--r--sc/source/ui/unoobj/fielduno.cxx20
-rw-r--r--sc/source/ui/unoobj/filtuno.cxx10
-rw-r--r--sc/source/ui/vba/vbaname.cxx4
-rw-r--r--sc/source/ui/vba/vbanames.cxx4
-rw-r--r--sc/source/ui/vba/vbarange.cxx6
-rw-r--r--sc/source/ui/view/cellsh1.cxx98
-rw-r--r--sc/source/ui/view/cellsh2.cxx10
-rw-r--r--sc/source/ui/view/cellsh3.cxx20
-rw-r--r--sc/source/ui/view/dbfunc3.cxx10
-rw-r--r--sc/source/ui/view/editsh.cxx8
-rw-r--r--sc/source/ui/view/formatsh.cxx14
-rw-r--r--sc/source/ui/view/gridwin.cxx10
-rw-r--r--sc/source/ui/view/gridwin4.cxx2
-rw-r--r--sc/source/ui/view/output.cxx8
-rw-r--r--sc/source/ui/view/output2.cxx8
-rw-r--r--sc/source/ui/view/pivotsh.cxx4
-rw-r--r--sc/source/ui/view/preview.cxx4
-rw-r--r--sc/source/ui/view/prevwsh.cxx4
-rw-r--r--sc/source/ui/view/printfun.cxx8
-rw-r--r--sc/source/ui/view/scextopt.cxx6
-rw-r--r--sc/source/ui/view/spelleng.cxx6
-rw-r--r--sc/source/ui/view/tabvwsh3.cxx6
-rw-r--r--sc/source/ui/view/tabvwsha.cxx10
-rw-r--r--sc/source/ui/view/tabvwshf.cxx20
-rw-r--r--sc/source/ui/view/tabvwshh.cxx2
-rw-r--r--sc/source/ui/view/viewfun2.cxx11
-rw-r--r--sc/source/ui/view/viewfun3.cxx8
-rw-r--r--sc/source/ui/view/viewfun4.cxx18
-rw-r--r--sc/source/ui/view/viewfun5.cxx10
-rw-r--r--sc/source/ui/view/viewfunc.cxx6
-rw-r--r--sc/source/ui/view/viewutil.cxx4
188 files changed, 848 insertions, 877 deletions
diff --git a/sc/source/core/data/attarray.cxx b/sc/source/core/data/attarray.cxx
index 65c2331eb00b..4c120dfadcb1 100644
--- a/sc/source/core/data/attarray.cxx
+++ b/sc/source/core/data/attarray.cxx
@@ -45,7 +45,7 @@
#include "cellvalue.hxx"
#include "editutil.hxx"
#include <rtl/strbuf.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
// STATIC DATA -----------------------------------------------------------
@@ -243,7 +243,7 @@ void ScAttrArray::AddCondFormat( SCROW nStartRow, SCROW nEndRow, sal_uInt32 nInd
{
const ScPatternAttr* pPattern = GetPattern(nTempStartRow);
- boost::scoped_ptr<ScPatternAttr> pNewPattern;
+ std::unique_ptr<ScPatternAttr> pNewPattern;
if(pPattern)
{
pNewPattern.reset( new ScPatternAttr(*pPattern) );
@@ -581,7 +581,7 @@ void ScAttrArray::ApplyStyleArea( SCROW nStartRow, SCROW nEndRow, ScStyleSheet*
do
{
const ScPatternAttr* pOldPattern = pData[nPos].pPattern;
- boost::scoped_ptr<ScPatternAttr> pNewPattern(new ScPatternAttr(*pOldPattern));
+ std::unique_ptr<ScPatternAttr> pNewPattern(new ScPatternAttr(*pOldPattern));
pNewPattern->SetStyleSheet(pStyle);
SCROW nY1 = nStart;
SCROW nY2 = pData[nPos].nRow;
@@ -680,7 +680,7 @@ void ScAttrArray::ApplyLineStyleArea( SCROW nStartRow, SCROW nEndRow,
if ( (SfxItemState::SET == eState) || (SfxItemState::SET == eTLBRState) || (SfxItemState::SET == eBLTRState) )
{
- boost::scoped_ptr<ScPatternAttr> pNewPattern(new ScPatternAttr(*pOldPattern));
+ std::unique_ptr<ScPatternAttr> pNewPattern(new ScPatternAttr(*pOldPattern));
SfxItemSet& rNewSet = pNewPattern->GetItemSet();
SCROW nY1 = nStart;
SCROW nY2 = pData[nPos].nRow;
@@ -1449,7 +1449,7 @@ bool ScAttrArray::RemoveAreaMerge(SCROW nStartRow, SCROW nEndRow)
for (SCROW nThisRow = nThisStart; nThisRow <= nThisEnd; nThisRow++)
pDocument->ApplyAttr( nThisCol, nThisRow, nTab, *pAttr );
- boost::scoped_ptr<ScPatternAttr> pNewPattern(new ScPatternAttr( pDocument->GetPool() ));
+ std::unique_ptr<ScPatternAttr> pNewPattern(new ScPatternAttr( pDocument->GetPool() ));
SfxItemSet* pSet = &pNewPattern->GetItemSet();
pSet->Put( *pFlagAttr );
pDocument->ApplyPatternAreaTab( nThisCol, nThisStart, nMergeEndCol, nMergeEndRow,
@@ -1506,7 +1506,7 @@ void ScAttrArray::SetPatternAreaSafe( SCROW nStartRow, SCROW nEndRow,
// because it would have no cell style information.
// Instead, the document's GetDefPattern is copied. Since it is passed as
// pWantedPattern, no special treatment of default is needed here anymore.
- boost::scoped_ptr<ScPatternAttr> pNewPattern(new ScPatternAttr( *pWantedPattern ));
+ std::unique_ptr<ScPatternAttr> pNewPattern(new ScPatternAttr( *pWantedPattern ));
SfxItemSet* pSet = &pNewPattern->GetItemSet();
pSet->Put( *pItem );
SetPatternArea( nThisRow, nAttrRow, pNewPattern.get(), true );
@@ -1736,7 +1736,7 @@ void ScAttrArray::FindStyleSheet( const SfxStyleSheetBase* pStyleSheet, ScFlatBo
if (bReset)
{
- boost::scoped_ptr<ScPatternAttr> pNewPattern(new ScPatternAttr(*pData[nPos].pPattern));
+ std::unique_ptr<ScPatternAttr> pNewPattern(new ScPatternAttr(*pData[nPos].pPattern));
pDocument->GetPool()->Remove(*pData[nPos].pPattern);
pNewPattern->SetStyleSheet( static_cast<ScStyleSheet*>(
pDocument->GetStyleSheetPool()->
@@ -2233,7 +2233,7 @@ void ScAttrArray::CopyArea(
}
else if ( nStripFlags )
{
- boost::scoped_ptr<ScPatternAttr> pTmpPattern(new ScPatternAttr( *pOldPattern ));
+ std::unique_ptr<ScPatternAttr> pTmpPattern(new ScPatternAttr( *pOldPattern ));
sal_Int16 nNewFlags = 0;
if ( nStripFlags != SC_MF_ALL )
nNewFlags = static_cast<const ScMergeFlagAttr&>(pTmpPattern->GetItem(ATTR_MERGE_FLAG)).
diff --git a/sc/source/core/data/clipcontext.cxx b/sc/source/core/data/clipcontext.cxx
index ac78dbd6941b..4bdb0e766687 100644
--- a/sc/source/core/data/clipcontext.cxx
+++ b/sc/source/core/data/clipcontext.cxx
@@ -241,7 +241,7 @@ void CopyFromClipContext::setSingleCell( const ScAddress& rSrcPos, const ScColum
// make this process simpler.
ScFieldEditEngine& rEngine = mrDestDoc.GetEditEngine();
rEngine.SetText(rSrcCell.mpFormula->GetString().getString());
- boost::scoped_ptr<EditTextObject> pObj(rEngine.CreateTextObject());
+ std::unique_ptr<EditTextObject> pObj(rEngine.CreateTextObject());
pObj->NormalizeString(mrDestDoc.GetSharedStringPool());
rSrcCell.set(*pObj);
}
diff --git a/sc/source/core/data/column.cxx b/sc/source/core/data/column.cxx
index 7b1e410e17a8..04eedf75b24b 100644
--- a/sc/source/core/data/column.cxx
+++ b/sc/source/core/data/column.cxx
@@ -57,7 +57,7 @@
#include <map>
#include <cstdio>
#include <boost/checked_delete.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using ::editeng::SvxBorderLine;
using namespace formula;
@@ -549,7 +549,7 @@ void ScColumn::RemoveCondFormat( SCROW nStartRow, SCROW nEndRow, sal_uInt32 nInd
void ScColumn::ApplyStyle( SCROW nRow, const ScStyleSheet& rStyle )
{
const ScPatternAttr* pPattern = pAttrArray->GetPattern(nRow);
- boost::scoped_ptr<ScPatternAttr> pNewPattern(new ScPatternAttr(*pPattern));
+ std::unique_ptr<ScPatternAttr> pNewPattern(new ScPatternAttr(*pPattern));
if (pNewPattern)
{
pNewPattern->SetStyleSheet(const_cast<ScStyleSheet*>(&rStyle));
@@ -702,7 +702,7 @@ void ScColumn::ApplyAttr( SCROW nRow, const SfxPoolItem& rAttr )
ScDocumentPool* pDocPool = pDocument->GetPool();
const ScPatternAttr* pOldPattern = pAttrArray->GetPattern( nRow );
- boost::scoped_ptr<ScPatternAttr> pTemp(new ScPatternAttr(*pOldPattern));
+ std::unique_ptr<ScPatternAttr> pTemp(new ScPatternAttr(*pOldPattern));
pTemp->GetItemSet().Put(rAttr);
const ScPatternAttr* pNewPattern = static_cast<const ScPatternAttr*>( &pDocPool->Put( *pTemp ) );
@@ -1657,7 +1657,7 @@ void ScColumn::CopyToColumn(
const ScStyleSheet* pStyle =
rColumn.pAttrArray->GetPattern( nRow )->GetStyleSheet();
const ScPatternAttr* pPattern = pAttrArray->GetPattern( nRow );
- boost::scoped_ptr<ScPatternAttr> pNewPattern(new ScPatternAttr( *pPattern ));
+ std::unique_ptr<ScPatternAttr> pNewPattern(new ScPatternAttr( *pPattern ));
pNewPattern->SetStyleSheet( const_cast<ScStyleSheet*>(pStyle) );
rColumn.pAttrArray->SetPattern( nRow, pNewPattern.get(), true );
}
@@ -2058,7 +2058,7 @@ class UpdateRefOnNonCopy : std::unary_function<sc::FormulaGroupEntry, void>
ScFormulaCell** ppEnd = pp + rGroup.mnLength;
ScFormulaCell* pTop = *pp;
ScTokenArray* pCode = pTop->GetCode();
- boost::scoped_ptr<ScTokenArray> pOldCode(pCode->Clone());
+ std::unique_ptr<ScTokenArray> pOldCode(pCode->Clone());
ScAddress aOldPos = pTop->aPos;
// Run this before the position gets updated.
@@ -2128,7 +2128,7 @@ class UpdateRefOnNonCopy : std::unary_function<sc::FormulaGroupEntry, void>
ScFormulaCell** ppEnd = pp + rGroup.mnLength;
ScFormulaCell* pTop = *pp;
ScTokenArray* pCode = pTop->GetCode();
- boost::scoped_ptr<ScTokenArray> pOldCode(pCode->Clone());
+ std::unique_ptr<ScTokenArray> pOldCode(pCode->Clone());
ScAddress aPos = pTop->aPos;
ScAddress aOldPos = aPos;
@@ -2164,7 +2164,7 @@ class UpdateRefOnNonCopy : std::unary_function<sc::FormulaGroupEntry, void>
// Make sure that the start and end listening contexts share the
// same block position set, else an invalid iterator may ensue.
- boost::shared_ptr<sc::ColumnBlockPositionSet> pPosSet(
+ std::shared_ptr<sc::ColumnBlockPositionSet> pPosSet(
new sc::ColumnBlockPositionSet(mpCxt->mrDoc));
sc::StartListeningContext aStartCxt(mpCxt->mrDoc, pPosSet);
diff --git a/sc/source/core/data/column2.cxx b/sc/source/core/data/column2.cxx
index 534708289918..5118e568c712 100644
--- a/sc/source/core/data/column2.cxx
+++ b/sc/source/core/data/column2.cxx
@@ -67,8 +67,8 @@
#include <formula/errorcodes.hxx>
#include <formula/vectortoken.hxx>
-#include <boost/scoped_ptr.hpp>
#include <algorithm>
+#include <memory>
// factor from font size to optimal cell height (text width)
#define SC_ROT_BREAK_FACTOR 6
@@ -368,7 +368,7 @@ long ScColumn::GetNeededSize(
SfxItemSet* pSet = new SfxItemSet( pEngine->GetEmptyItemSet() );
if ( ScStyleSheet* pPreviewStyle = pDocument->GetPreviewCellStyle( nCol, nRow, nTab ) )
{
- boost::scoped_ptr<ScPatternAttr> pPreviewPattern(new ScPatternAttr( *pPattern ));
+ std::unique_ptr<ScPatternAttr> pPreviewPattern(new ScPatternAttr( *pPattern ));
pPreviewPattern->SetStyleSheet(pPreviewStyle);
pPreviewPattern->FillEditItemSet( pSet, pCondSet );
}
@@ -1054,7 +1054,7 @@ public:
class RemoveEditAttribsHandler : public StrEntries
{
- boost::scoped_ptr<ScFieldEditEngine> mpEngine;
+ std::unique_ptr<ScFieldEditEngine> mpEngine;
public:
RemoveEditAttribsHandler(sc::CellStoreType& rCells, ScDocument* pDoc) : StrEntries(rCells, pDoc) {}
diff --git a/sc/source/core/data/column3.cxx b/sc/source/core/data/column3.cxx
index c39c295eae06..138b0f52e879 100644
--- a/sc/source/core/data/column3.cxx
+++ b/sc/source/core/data/column3.cxx
@@ -50,7 +50,7 @@
#include <com/sun/star/i18n/LocaleDataItem.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include <mdds/flat_segment_tree.hpp>
@@ -423,7 +423,7 @@ void ScColumn::AttachNewFormulaCell(
{
case sc::ConvertToGroupListening:
{
- boost::shared_ptr<sc::ColumnBlockPositionSet> pPosSet(new sc::ColumnBlockPositionSet(*pDocument));
+ std::shared_ptr<sc::ColumnBlockPositionSet> pPosSet(new sc::ColumnBlockPositionSet(*pDocument));
sc::StartListeningContext aStartCxt(*pDocument, pPosSet);
sc::EndListeningContext aEndCxt(*pDocument, pPosSet);
SCROW nRow = aPos.first->position + aPos.second;
diff --git a/sc/source/core/data/column4.cxx b/sc/source/core/data/column4.cxx
index ac09eac472ce..bd7c60bf7d4d 100644
--- a/sc/source/core/data/column4.cxx
+++ b/sc/source/core/data/column4.cxx
@@ -34,8 +34,6 @@
#include <vector>
#include <cassert>
-#include <boost/shared_ptr.hpp>
-
bool ScColumn::IsMerged( SCROW nRow ) const
{
return pAttrArray->IsMerged(nRow);
diff --git a/sc/source/core/data/conditio.cxx b/sc/source/core/data/conditio.cxx
index 192611851b41..b72a5adf83e6 100644
--- a/sc/source/core/data/conditio.cxx
+++ b/sc/source/core/data/conditio.cxx
@@ -42,7 +42,7 @@
#include "refupdatecontext.hxx"
#include <svl/sharedstring.hxx>
#include <svl/sharedstringpool.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace formula;
@@ -653,7 +653,7 @@ void ScConditionEntry::Interpret( const ScAddress& rPos )
// Evaluate formulas
bool bDirty = false; // 1 and 2 separate?
- boost::scoped_ptr<ScFormulaCell> pTemp1;
+ std::unique_ptr<ScFormulaCell> pTemp1;
ScFormulaCell* pEff1 = pFCell1;
if ( bRelRef1 )
{
@@ -683,7 +683,7 @@ void ScConditionEntry::Interpret( const ScAddress& rPos )
}
pTemp1.reset();
- boost::scoped_ptr<ScFormulaCell> pTemp2;
+ std::unique_ptr<ScFormulaCell> pTemp2;
ScFormulaCell* pEff2 = pFCell2; //@ 1!=2
if ( bRelRef2 )
{
diff --git a/sc/source/core/data/documen2.cxx b/sc/source/core/data/documen2.cxx
index a38f7121bb86..3b96fb4e6b9f 100644
--- a/sc/source/core/data/documen2.cxx
+++ b/sc/source/core/data/documen2.cxx
@@ -131,7 +131,7 @@ private:
ScDocument::ScDocument( ScDocumentMode eMode, SfxObjectShell* pDocShell ) :
mpCellStringPool(new svl::SharedStringPool(ScGlobal::pCharClass)),
- mpFormulaGroupCxt(NULL),
+ mpFormulaGroupCxt(nullptr),
maCalcConfig( ScInterpreter::GetGlobalConfig()),
mpUndoManager( NULL ),
pEditEngine( NULL ),
diff --git a/sc/source/core/data/documen3.cxx b/sc/source/core/data/documen3.cxx
index 0e6998a07caf..15d407a9f324 100644
--- a/sc/source/core/data/documen3.cxx
+++ b/sc/source/core/data/documen3.cxx
@@ -73,8 +73,8 @@
#include "scopetools.hxx"
#include "globalnames.hxx"
-#include <boost/scoped_ptr.hpp>
#include <LibreOfficeKit/LibreOfficeKitEnums.h>
+#include <memory>
using namespace com::sun::star;
@@ -974,7 +974,7 @@ void ScDocument::UpdateReference(
if (!ValidRange(rCxt.maRange))
return;
- boost::scoped_ptr<sc::ExpandRefsSwitch> pExpandRefsSwitch;
+ std::unique_ptr<sc::ExpandRefsSwitch> pExpandRefsSwitch;
if (rCxt.isInserted())
pExpandRefsSwitch.reset(new sc::ExpandRefsSwitch(*this, SC_MOD()->GetInputOptions().GetExpandRefs()));
diff --git a/sc/source/core/data/documen4.cxx b/sc/source/core/data/documen4.cxx
index 4d93eca06538..48319bad94a8 100644
--- a/sc/source/core/data/documen4.cxx
+++ b/sc/source/core/data/documen4.cxx
@@ -339,7 +339,7 @@ void ScDocument::InsertMatrixFormula(SCCOL nCol1, SCROW nRow1,
// Reference in each cell must point to the origin cell relative to the current cell.
aRefData.SetAddress(aBasePos, aPos);
*t->GetSingleRef() = aRefData;
- boost::scoped_ptr<ScTokenArray> pTokArr(aArr.Clone());
+ std::unique_ptr<ScTokenArray> pTokArr(aArr.Clone());
pCell = new ScFormulaCell(this, aPos, *pTokArr, eGram, MM_REFERENCE);
pTab->SetFormulaCell(nCol, nRow, pCell);
}
diff --git a/sc/source/core/data/documen8.cxx b/sc/source/core/data/documen8.cxx
index c51ca60dab64..d9e9bd376ebd 100644
--- a/sc/source/core/data/documen8.cxx
+++ b/sc/source/core/data/documen8.cxx
@@ -89,7 +89,7 @@
#include <documentlinkmgr.hxx>
#include <scopetools.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace com::sun::star;
@@ -571,7 +571,7 @@ bool ScDocument::IdleCalcTextWidth() // true = try next again
// Start at specified cell position (nCol, nRow, nTab).
ScColumn* pCol = &pTab->aCol[aScope.Col()];
- boost::scoped_ptr<ScColumnTextWidthIterator> pColIter(new ScColumnTextWidthIterator(*pCol, aScope.Row(), MAXROW));
+ std::unique_ptr<ScColumnTextWidthIterator> pColIter(new ScColumnTextWidthIterator(*pCol, aScope.Row(), MAXROW));
OutputDevice* pDev = NULL;
sal_uInt16 nRestart = 0;
@@ -1205,7 +1205,7 @@ void ScDocument::TransliterateText( const ScMarkData& rMultiMark, sal_Int32 nTyp
bool bConsiderLanguage = aTransliterationWrapper.needLanguageForTheMode();
sal_uInt16 nLanguage = LANGUAGE_SYSTEM;
- boost::scoped_ptr<ScEditEngineDefaulter> pEngine; // not using pEditEngine member because of defaults
+ std::unique_ptr<ScEditEngineDefaulter> pEngine; // not using pEditEngine member because of defaults
SCTAB nCount = GetTableCount();
ScMarkData::const_iterator itr = rMultiMark.begin(), itrEnd = rMultiMark.end();
@@ -1240,7 +1240,7 @@ void ScDocument::TransliterateText( const ScMarkData& rMultiMark, sal_Int32 nTyp
SfxItemSet* pDefaults = new SfxItemSet( pEngine->GetEmptyItemSet() );
if ( ScStyleSheet* pPreviewStyle = GetPreviewCellStyle( nCol, nRow, nTab ) )
{
- boost::scoped_ptr<ScPatternAttr> pPreviewPattern(new ScPatternAttr( *pPattern ));
+ std::unique_ptr<ScPatternAttr> pPreviewPattern(new ScPatternAttr( *pPattern ));
pPreviewPattern->SetStyleSheet(pPreviewStyle);
pPreviewPattern->FillEditItemSet( pDefaults );
}
diff --git a/sc/source/core/data/document.cxx b/sc/source/core/data/document.cxx
index f4aacca7caaf..a362a24f82dc 100644
--- a/sc/source/core/data/document.cxx
+++ b/sc/source/core/data/document.cxx
@@ -100,10 +100,10 @@
#include <formula/vectortoken.hxx>
-#include <map>
#include <limits>
+#include <map>
+#include <memory>
#include <boost/checked_delete.hpp>
-#include <boost/scoped_ptr.hpp>
#include "mtvelements.hxx"
@@ -2468,7 +2468,7 @@ void ScDocument::StartListeningFromClip( SCCOL nCol1, SCROW nRow1,
{
if (nInsFlag & IDF_CONTENTS)
{
- boost::shared_ptr<sc::ColumnBlockPositionSet> pSet(
+ std::shared_ptr<sc::ColumnBlockPositionSet> pSet(
new sc::ColumnBlockPositionSet(*this));
sc::StartListeningContext aStartCxt(*this, pSet);
@@ -3118,7 +3118,7 @@ void ScDocument::FillTab( const ScRange& rSrcArea, const ScMarkData& rMark,
SCROW nStartRow = rSrcArea.aStart.Row();
SCCOL nEndCol = rSrcArea.aEnd.Col();
SCROW nEndRow = rSrcArea.aEnd.Row();
- boost::scoped_ptr<ScDocument> pMixDoc;
+ std::unique_ptr<ScDocument> pMixDoc;
bool bDoMix = ( bSkipEmpty || nFunction ) && ( nFlags & IDF_CONTENTS );
bool bOldAutoCalc = GetAutoCalc();
@@ -3175,7 +3175,7 @@ void ScDocument::FillTabMarked( SCTAB nSrcTab, const ScMarkData& rMark,
if (ValidTab(nSrcTab) && nSrcTab < static_cast<SCTAB>(maTabs.size()) && maTabs[nSrcTab])
{
- boost::scoped_ptr<ScDocument> pMixDoc;
+ std::unique_ptr<ScDocument> pMixDoc;
bool bDoMix = ( bSkipEmpty || nFunction ) && ( nFlags & IDF_CONTENTS );
bool bOldAutoCalc = GetAutoCalc();
diff --git a/sc/source/core/data/document10.cxx b/sc/source/core/data/document10.cxx
index 46825d25f5f9..dd3572ca1ef2 100644
--- a/sc/source/core/data/document10.cxx
+++ b/sc/source/core/data/document10.cxx
@@ -207,7 +207,7 @@ void ScDocument::SwapNonEmpty( sc::TableValues& rValues )
if (!rRange.IsValid())
return;
- boost::shared_ptr<sc::ColumnBlockPositionSet> pPosSet(new sc::ColumnBlockPositionSet(*this));
+ std::shared_ptr<sc::ColumnBlockPositionSet> pPosSet(new sc::ColumnBlockPositionSet(*this));
sc::StartListeningContext aStartCxt(*this, pPosSet);
sc::EndListeningContext aEndCxt(*this, pPosSet);
@@ -393,7 +393,7 @@ namespace {
class StartNeededListenersHandler : std::unary_function<ScTable*, void>
{
- boost::shared_ptr<sc::StartListeningContext> mpCxt;
+ std::shared_ptr<sc::StartListeningContext> mpCxt;
public:
StartNeededListenersHandler( ScDocument& rDoc ) : mpCxt(new sc::StartListeningContext(rDoc)) {}
@@ -413,7 +413,7 @@ void ScDocument::StartNeededListeners()
void ScDocument::StartAllListeners( const ScRange& rRange )
{
- boost::shared_ptr<sc::ColumnBlockPositionSet> pPosSet(new sc::ColumnBlockPositionSet(*this));
+ std::shared_ptr<sc::ColumnBlockPositionSet> pPosSet(new sc::ColumnBlockPositionSet(*this));
sc::StartListeningContext aStartCxt(*this, pPosSet);
sc::EndListeningContext aEndCxt(*this, pPosSet);
diff --git a/sc/source/core/data/documentimport.cxx b/sc/source/core/data/documentimport.cxx
index 642bbc2df3d4..543181cacbf1 100644
--- a/sc/source/core/data/documentimport.cxx
+++ b/sc/source/core/data/documentimport.cxx
@@ -330,7 +330,7 @@ void ScDocumentImport::setMatrixCells(
// Reference in each cell must point to the origin cell relative to the current cell.
aRefData.SetAddress(rBasePos, aPos);
*t->GetSingleRef() = aRefData;
- boost::scoped_ptr<ScTokenArray> pTokArr(aArr.Clone());
+ std::unique_ptr<ScTokenArray> pTokArr(aArr.Clone());
pCell = new ScFormulaCell(&mpImpl->mrDoc, aPos, *pTokArr, eGram, MM_REFERENCE);
pBlockPos->miCellPos =
rCells.set(pBlockPos->miCellPos, aPos.Row(), pCell);
@@ -350,7 +350,7 @@ void ScDocumentImport::setMatrixCells(
aPos.SetRow(nRow);
aRefData.SetAddress(rBasePos, aPos);
*t->GetSingleRef() = aRefData;
- boost::scoped_ptr<ScTokenArray> pTokArr(aArr.Clone());
+ std::unique_ptr<ScTokenArray> pTokArr(aArr.Clone());
pCell = new ScFormulaCell(&mpImpl->mrDoc, aPos, *pTokArr, eGram, MM_REFERENCE);
pBlockPos->miCellPos =
rColCells.set(pBlockPos->miCellPos, aPos.Row(), pCell);
@@ -503,7 +503,7 @@ public:
mpImpl(new Impl(MAXROWCOUNT, mrDocImpl.mnDefaultScriptNumeric))
{}
- boost::shared_ptr<Impl> mpImpl;
+ std::shared_ptr<Impl> mpImpl;
void operator() (const sc::CellStoreType::value_type& node)
{
diff --git a/sc/source/core/data/dpgroup.cxx b/sc/source/core/data/dpgroup.cxx
index b9c557233826..96b47b089f34 100644
--- a/sc/source/core/data/dpgroup.cxx
+++ b/sc/source/core/data/dpgroup.cxx
@@ -49,7 +49,7 @@ using ::com::sun::star::uno::UNO_QUERY;
using ::com::sun::star::uno::UNO_QUERY_THROW;
using ::std::vector;
-using ::boost::shared_ptr;
+using ::std::shared_ptr;
const sal_uInt16 SC_DP_LEAPYEAR = 1648; // arbitrary leap year for date calculations
diff --git a/sc/source/core/data/dpobject.cxx b/sc/source/core/data/dpobject.cxx
index db4ccd294fe2..757f274956ff 100644
--- a/sc/source/core/data/dpobject.cxx
+++ b/sc/source/core/data/dpobject.cxx
@@ -83,7 +83,7 @@
using namespace com::sun::star;
using ::std::vector;
using ::std::unary_function;
-using ::boost::shared_ptr;
+using ::std::shared_ptr;
using ::com::sun::star::uno::Sequence;
using ::com::sun::star::uno::Reference;
using ::com::sun::star::uno::UNO_QUERY;
diff --git a/sc/source/core/data/dpsave.cxx b/sc/source/core/data/dpsave.cxx
index fc8651536825..2e97565dc54f 100644
--- a/sc/source/core/data/dpsave.cxx
+++ b/sc/source/core/data/dpsave.cxx
@@ -68,7 +68,7 @@ static void lcl_SetBoolProperty( const uno::Reference<beans::XPropertySet>& xPro
ScDPSaveMember::ScDPSaveMember(const OUString& rName) :
aName( rName ),
- mpLayoutName(NULL),
+ mpLayoutName(nullptr),
nVisibleMode( SC_DPSAVEMODE_DONTKNOW ),
nShowDetailsMode( SC_DPSAVEMODE_DONTKNOW )
{
@@ -76,7 +76,7 @@ ScDPSaveMember::ScDPSaveMember(const OUString& rName) :
ScDPSaveMember::ScDPSaveMember(const ScDPSaveMember& r) :
aName( r.aName ),
- mpLayoutName(NULL),
+ mpLayoutName(nullptr),
nVisibleMode( r.nVisibleMode ),
nShowDetailsMode( r.nShowDetailsMode )
{
@@ -191,8 +191,8 @@ void ScDPSaveMember::Dump(int nIndent) const
ScDPSaveDimension::ScDPSaveDimension(const OUString& rName, bool bDataLayout) :
aName( rName ),
- mpLayoutName(NULL),
- mpSubtotalName(NULL),
+ mpLayoutName(nullptr),
+ mpSubtotalName(nullptr),
bIsDataLayout( bDataLayout ),
bDupFlag( false ),
nOrientation( sheet::DataPilotFieldOrientation_HIDDEN ),
@@ -202,18 +202,18 @@ ScDPSaveDimension::ScDPSaveDimension(const OUString& rName, bool bDataLayout) :
bRepeatItemLabels( false ),
bSubTotalDefault( true ),
nSubTotalCount( 0 ),
- pSubTotalFuncs( NULL ),
- pReferenceValue( NULL ),
- pSortInfo( NULL ),
- pAutoShowInfo( NULL ),
- pLayoutInfo( NULL )
+ pSubTotalFuncs( nullptr ),
+ pReferenceValue( nullptr ),
+ pSortInfo( nullptr ),
+ pAutoShowInfo( nullptr ),
+ pLayoutInfo( nullptr )
{
}
ScDPSaveDimension::ScDPSaveDimension(const ScDPSaveDimension& r) :
aName( r.aName ),
- mpLayoutName(NULL),
- mpSubtotalName(NULL),
+ mpLayoutName(nullptr),
+ mpSubtotalName(nullptr),
bIsDataLayout( r.bIsDataLayout ),
bDupFlag( r.bDupFlag ),
nOrientation( r.nOrientation ),
@@ -223,7 +223,7 @@ ScDPSaveDimension::ScDPSaveDimension(const ScDPSaveDimension& r) :
bRepeatItemLabels( r.bRepeatItemLabels ),
bSubTotalDefault( r.bSubTotalDefault ),
nSubTotalCount( r.nSubTotalCount ),
- pSubTotalFuncs( NULL )
+ pSubTotalFuncs( nullptr )
{
if ( nSubTotalCount && r.pSubTotalFuncs )
{
@@ -242,19 +242,19 @@ ScDPSaveDimension::ScDPSaveDimension(const ScDPSaveDimension& r) :
if (r.pReferenceValue)
pReferenceValue = new sheet::DataPilotFieldReference( *(r.pReferenceValue) );
else
- pReferenceValue = NULL;
+ pReferenceValue = nullptr;
if (r.pSortInfo)
pSortInfo = new sheet::DataPilotFieldSortInfo( *(r.pSortInfo) );
else
- pSortInfo = NULL;
+ pSortInfo = nullptr;
if (r.pAutoShowInfo)
pAutoShowInfo = new sheet::DataPilotFieldAutoShowInfo( *(r.pAutoShowInfo) );
else
- pAutoShowInfo = NULL;
+ pAutoShowInfo = nullptr;
if (r.pLayoutInfo)
pLayoutInfo = new sheet::DataPilotFieldLayoutInfo( *(r.pLayoutInfo) );
else
- pLayoutInfo = NULL;
+ pLayoutInfo = nullptr;
if (r.mpLayoutName)
mpLayoutName.reset(new OUString(*r.mpLayoutName));
if (r.mpSubtotalName)
@@ -383,7 +383,7 @@ void ScDPSaveDimension::SetSubTotals(long nCount, const sal_uInt16* pFuncs)
pSubTotalFuncs[i] = pFuncs[i];
}
else
- pSubTotalFuncs = NULL;
+ pSubTotalFuncs = nullptr;
bSubTotalDefault = false;
}
@@ -465,7 +465,7 @@ void ScDPSaveDimension::SetReferenceValue(const sheet::DataPilotFieldReference*
if (pNew)
pReferenceValue = new sheet::DataPilotFieldReference(*pNew);
else
- pReferenceValue = NULL;
+ pReferenceValue = nullptr;
}
void ScDPSaveDimension::SetSortInfo(const sheet::DataPilotFieldSortInfo* pNew)
@@ -474,7 +474,7 @@ void ScDPSaveDimension::SetSortInfo(const sheet::DataPilotFieldSortInfo* pNew)
if (pNew)
pSortInfo = new sheet::DataPilotFieldSortInfo(*pNew);
else
- pSortInfo = NULL;
+ pSortInfo = nullptr;
}
void ScDPSaveDimension::SetAutoShowInfo(const sheet::DataPilotFieldAutoShowInfo* pNew)
@@ -483,7 +483,7 @@ void ScDPSaveDimension::SetAutoShowInfo(const sheet::DataPilotFieldAutoShowInfo*
if (pNew)
pAutoShowInfo = new sheet::DataPilotFieldAutoShowInfo(*pNew);
else
- pAutoShowInfo = NULL;
+ pAutoShowInfo = nullptr;
}
void ScDPSaveDimension::SetLayoutInfo(const sheet::DataPilotFieldLayoutInfo* pNew)
@@ -492,14 +492,14 @@ void ScDPSaveDimension::SetLayoutInfo(const sheet::DataPilotFieldLayoutInfo* pNe
if (pNew)
pLayoutInfo = new sheet::DataPilotFieldLayoutInfo(*pNew);
else
- pLayoutInfo = NULL;
+ pLayoutInfo = nullptr;
}
void ScDPSaveDimension::SetCurrentPage( const OUString* pPage )
{
// We use member's visibility attribute to filter by page dimension.
- // pPage == NULL -> all members visible.
+ // pPage == nullptr -> all members visible.
MemberList::iterator it = maMemberList.begin(), itEnd = maMemberList.end();
for (; it != itEnd; ++it)
{
@@ -527,7 +527,7 @@ ScDPSaveMember* ScDPSaveDimension::GetExistingMemberByName(const OUString& rName
MemberHash::const_iterator res = maMemberHash.find (rName);
if (res != maMemberHash.end())
return res->second;
- return NULL;
+ return nullptr;
}
ScDPSaveMember* ScDPSaveDimension::GetMemberByName(const OUString& rName)
@@ -797,7 +797,7 @@ void ScDPSaveDimension::Dump(int nIndent) const
#endif
ScDPSaveData::ScDPSaveData() :
- pDimensionData( NULL ),
+ pDimensionData( nullptr ),
nColumnGrandMode( SC_DPSAVEMODE_DONTKNOW ),
nRowGrandMode( SC_DPSAVEMODE_DONTKNOW ),
nIgnoreEmptyMode( SC_DPSAVEMODE_DONTKNOW ),
@@ -805,7 +805,7 @@ ScDPSaveData::ScDPSaveData() :
bFilterButton( true ),
bDrillDown( true ),
mbDimensionMembersBuilt(false),
- mpGrandTotalName(NULL)
+ mpGrandTotalName(nullptr)
{
}
@@ -817,13 +817,13 @@ ScDPSaveData::ScDPSaveData(const ScDPSaveData& r) :
bFilterButton( r.bFilterButton ),
bDrillDown( r.bDrillDown ),
mbDimensionMembersBuilt(r.mbDimensionMembersBuilt),
- mpGrandTotalName(NULL),
- mpDimOrder(NULL)
+ mpGrandTotalName(nullptr),
+ mpDimOrder(nullptr)
{
if ( r.pDimensionData )
pDimensionData = new ScDPDimensionSaveData( *r.pDimensionData );
else
- pDimensionData = NULL;
+ pDimensionData = nullptr;
aDimList = r.aDimList.clone();
@@ -971,7 +971,7 @@ ScDPSaveDimension* ScDPSaveData::GetExistingDimensionByName(const OUString& rNam
if (iter->GetName() == rName && !iter->IsDataLayout() )
return const_cast<ScDPSaveDimension*>(&(*iter));
}
- return NULL; // don't create new
+ return nullptr; // don't create new
}
ScDPSaveDimension* ScDPSaveData::GetNewDimensionByName(const OUString& rName)
@@ -1003,7 +1003,7 @@ ScDPSaveDimension* ScDPSaveData::GetExistingDataLayoutDimension() const
if ( iter->IsDataLayout() )
return const_cast<ScDPSaveDimension*>(&(*iter));
}
- return NULL;
+ return nullptr;
}
ScDPSaveDimension* ScDPSaveData::DuplicateDimension(const OUString& rName)
@@ -1012,7 +1012,7 @@ ScDPSaveDimension* ScDPSaveData::DuplicateDimension(const OUString& rName)
ScDPSaveDimension* pOld = GetExistingDimensionByName(rName);
if (!pOld)
- return NULL;
+ return nullptr;
ScDPSaveDimension* pNew = new ScDPSaveDimension( *pOld );
AddDimension(pNew);
@@ -1053,7 +1053,7 @@ ScDPSaveDimension* ScDPSaveData::GetInnermostDimension(sal_uInt16 nOrientation)
return const_cast<ScDPSaveDimension*>(&(*iter));
}
- return NULL;
+ return nullptr;
}
ScDPSaveDimension* ScDPSaveData::GetFirstDimension(sheet::DataPilotFieldOrientation eOrientation)
@@ -1064,7 +1064,7 @@ ScDPSaveDimension* ScDPSaveData::GetFirstDimension(sheet::DataPilotFieldOrientat
if (iter->GetOrientation() == eOrientation && !iter->IsDataLayout())
return const_cast<ScDPSaveDimension*>(&(*iter));
}
- return NULL;
+ return nullptr;
}
long ScDPSaveData::GetDataDimensionCount() const
@@ -1326,7 +1326,7 @@ void ScDPSaveData::RemoveAllGroupDimensions( const OUString& rSrcDimName, std::v
{
// still get the same group dimension?
OSL_FAIL("couldn't remove group dimension");
- pExistingGroup = NULL; // avoid endless loop
+ pExistingGroup = nullptr; // avoid endless loop
}
}
}
@@ -1344,7 +1344,7 @@ void ScDPSaveData::SetDimensionData( const ScDPDimensionSaveData* pNew )
if ( pNew )
pDimensionData = new ScDPDimensionSaveData( *pNew );
else
- pDimensionData = NULL;
+ pDimensionData = nullptr;
}
void ScDPSaveData::BuildAllDimensionMembers(ScDPTableData* pData)
@@ -1495,7 +1495,7 @@ ScDPSaveDimension* ScDPSaveData::AppendNewDimension(const OUString& rName, bool
{
if (ScDPUtil::isDuplicateDimension(rName))
// This call is for original dimensions only.
- return NULL;
+ return nullptr;
ScDPSaveDimension* pNew = new ScDPSaveDimension(rName, bDataLayout);
aDimList.push_back(pNew);
diff --git a/sc/source/core/data/dptabres.cxx b/sc/source/core/data/dptabres.cxx
index 7ccaa7300021..28667b54d920 100644
--- a/sc/source/core/data/dptabres.cxx
+++ b/sc/source/core/data/dptabres.cxx
@@ -37,9 +37,9 @@
#include <math.h>
#include <float.h>
#include <algorithm>
+#include <memory>
#include <unordered_map>
#include <boost/checked_delete.hpp>
-#include <boost/scoped_ptr.hpp>
#include <com/sun/star/sheet/DataResultFlags.hpp>
#include <com/sun/star/sheet/MemberResultFlags.hpp>
@@ -1505,7 +1505,7 @@ void ScDPResultMember::FillDataResults(
ScDPResultFilterContext& rFilterCxt, uno::Sequence<uno::Sequence<sheet::DataResult> >& rSequence,
long nMeasure) const
{
- boost::scoped_ptr<FilterStack> pFilterStack;
+ std::unique_ptr<FilterStack> pFilterStack;
const ScDPMember* pDPMember = GetDPMember();
if (pDPMember)
{
@@ -2009,7 +2009,7 @@ void ScDPDataMember::FillDataRow(
uno::Sequence<sheet::DataResult>& rSequence, long nMeasure, bool bIsSubTotalRow,
const ScDPSubTotalState& rSubState) const
{
- boost::scoped_ptr<FilterStack> pFilterStack;
+ std::unique_ptr<FilterStack> pFilterStack;
if (pResultMember)
{
// Topmost data member (pResultMember=NULL) doesn't need to be handled
diff --git a/sc/source/core/data/dptabsrc.cxx b/sc/source/core/data/dptabsrc.cxx
index 5a14a6f23e53..bd9950bb6552 100644
--- a/sc/source/core/data/dptabsrc.cxx
+++ b/sc/source/core/data/dptabsrc.cxx
@@ -98,17 +98,17 @@ static void lcl_SetBoolInAny( uno::Any& rAny, bool bValue )
ScDPSource::ScDPSource( ScDPTableData* pD ) :
pData( pD ),
- pDimensions( NULL ),
+ pDimensions( nullptr ),
bColumnGrand( true ), // default is true
bRowGrand( true ),
bIgnoreEmptyRows( false ),
bRepeatIfEmpty( false ),
nDupCount( 0 ),
- pResData( NULL ),
- pColResRoot( NULL ),
- pRowResRoot( NULL ),
- pColResults( NULL ),
- pRowResults( NULL ),
+ pResData( nullptr ),
+ pColResRoot( nullptr ),
+ pRowResRoot( nullptr ),
+ pColResults( nullptr ),
+ pRowResults( nullptr ),
bResultOverflow( false ),
bPageFiltered( false )
{
@@ -160,7 +160,7 @@ long ScDPSource::GetDataDimensionCount()
ScDPDimension* ScDPSource::GetDataDimension(long nIndex)
{
if (nIndex < 0 || static_cast<size_t>(nIndex) >= maDataDims.size())
- return NULL;
+ return nullptr;
long nDimIndex = maDataDims[nIndex];
return GetDimensionsObject()->getByIndex(nDimIndex);
@@ -539,8 +539,8 @@ void ScDPSource::disposeData()
DELETEZ(pResData);
delete[] pColResults;
delete[] pRowResults;
- pColResults = NULL;
- pRowResults = NULL;
+ pColResults = nullptr;
+ pRowResults = nullptr;
aColLevelList.clear();
aRowLevelList.clear();
}
@@ -548,7 +548,7 @@ void ScDPSource::disposeData()
if ( pDimensions )
{
pDimensions->release(); // ref-counted
- pDimensions = NULL; // settings have to be applied (from SaveData) again!
+ pDimensions = nullptr; // settings have to be applied (from SaveData) again!
}
SetDupCount( 0 );
@@ -999,7 +999,7 @@ void ScDPSource::FillLevelList( sal_uInt16 nOrientation, std::vector<ScDPLevel*>
{
rList.clear();
- std::vector<long>* pDimIndex = NULL;
+ std::vector<long>* pDimIndex = nullptr;
switch (nOrientation)
{
case sheet::DataPilotFieldOrientation_COLUMN:
@@ -1070,7 +1070,7 @@ void ScDPSource::FillMemberResults()
long nPos = 0;
pColResRoot->FillMemberResults( pColResults, nPos, pResData->GetColStartMeasure(),
- true, NULL, NULL );
+ true, nullptr, nullptr );
}
FillLevelList( sheet::DataPilotFieldOrientation_ROW, aRowLevelList );
@@ -1084,7 +1084,7 @@ void ScDPSource::FillMemberResults()
long nPos = 0;
pRowResRoot->FillMemberResults( pRowResults, nPos, pResData->GetRowStartMeasure(),
- true, NULL, NULL );
+ true, nullptr, nullptr );
}
}
}
@@ -1108,7 +1108,7 @@ const uno::Sequence<sheet::MemberResult>* ScDPSource::GetMemberResults( ScDPLeve
if ( pRowLevel == pLevel )
return pRowResults+i;
}
- return NULL;
+ return nullptr;
}
// XPropertySet
@@ -1211,7 +1211,7 @@ SC_IMPL_DUMMY_PROPERTY_LISTENER( ScDPSource )
ScDPDimensions::ScDPDimensions( ScDPSource* pSrc ) :
pSource( pSrc ),
- ppDims( NULL )
+ ppDims( nullptr )
{
//TODO: hold pSource
@@ -1245,7 +1245,7 @@ void ScDPDimensions::CountChanged()
for (i=0; i<nCopy; i++) // copy existing dims
ppNew[i] = ppDims[i];
for (i=nCopy; i<nNewCount; i++) // clear additional pointers
- ppNew[i] = NULL;
+ ppNew[i] = nullptr;
for (i=nCopy; i<nDimCount; i++) // delete old dims if count is decreased
if ( ppDims[i] )
ppDims[i]->release(); // ref-counted
@@ -1322,7 +1322,7 @@ ScDPDimension* ScDPDimensions::getByIndex(long nIndex) const
{
const_cast<ScDPDimensions*>(this)->ppDims = new ScDPDimension*[nDimCount];
for (long i=0; i<nDimCount; i++)
- ppDims[i] = NULL;
+ ppDims[i] = nullptr;
}
if ( !ppDims[nIndex] )
{
@@ -1333,20 +1333,20 @@ ScDPDimension* ScDPDimensions::getByIndex(long nIndex) const
return ppDims[nIndex];
}
- return NULL; //TODO: exception?
+ return nullptr; //TODO: exception?
}
ScDPDimension::ScDPDimension( ScDPSource* pSrc, long nD ) :
pSource( pSrc ),
nDim( nD ),
- pHierarchies( NULL ),
+ pHierarchies( nullptr ),
nUsedHier( 0 ),
nFunction( SUBTOTAL_FUNC_SUM ), // sum is default
- mpLayoutName(NULL),
- mpSubtotalName(NULL),
+ mpLayoutName(nullptr),
+ mpSubtotalName(nullptr),
nSourceDim( -1 ),
bHasSelectedPage( false ),
- pSelectedData( NULL ),
+ pSelectedData( nullptr ),
mbHasHiddenMember(false)
{
//TODO: hold pSource
@@ -1690,7 +1690,7 @@ SC_IMPL_DUMMY_PROPERTY_LISTENER( ScDPDimension )
ScDPHierarchies::ScDPHierarchies( ScDPSource* pSrc, long nD ) :
pSource( pSrc ),
nDim( nD ),
- ppHiers( NULL )
+ ppHiers( nullptr )
{
//TODO: hold pSource
@@ -1779,7 +1779,7 @@ ScDPHierarchy* ScDPHierarchies::getByIndex(long nIndex) const
{
const_cast<ScDPHierarchies*>(this)->ppHiers = new ScDPHierarchy*[nHierCount];
for (long i=0; i<nHierCount; i++)
- ppHiers[i] = NULL;
+ ppHiers[i] = nullptr;
}
if ( !ppHiers[nIndex] )
{
@@ -1790,14 +1790,14 @@ ScDPHierarchy* ScDPHierarchies::getByIndex(long nIndex) const
return ppHiers[nIndex];
}
- return NULL; //TODO: exception?
+ return nullptr; //TODO: exception?
}
ScDPHierarchy::ScDPHierarchy( ScDPSource* pSrc, long nD, long nH ) :
pSource( pSrc ),
nDim( nD ),
nHier( nH ),
- pLevels( NULL )
+ pLevels( nullptr )
{
//TODO: hold pSource
}
@@ -1856,7 +1856,7 @@ ScDPLevels::ScDPLevels( ScDPSource* pSrc, long nD, long nH ) :
pSource( pSrc ),
nDim( nD ),
nHier( nH ),
- ppLevs( NULL )
+ ppLevs( nullptr )
{
//TODO: hold pSource
@@ -1955,7 +1955,7 @@ ScDPLevel* ScDPLevels::getByIndex(long nIndex) const
{
const_cast<ScDPLevels*>(this)->ppLevs = new ScDPLevel*[nLevCount];
for (long i=0; i<nLevCount; i++)
- ppLevs[i] = NULL;
+ ppLevs[i] = nullptr;
}
if ( !ppLevs[nIndex] )
{
@@ -1966,7 +1966,7 @@ ScDPLevel* ScDPLevels::getByIndex(long nIndex) const
return ppLevs[nIndex];
}
- return NULL; //TODO: exception?
+ return nullptr; //TODO: exception?
}
class ScDPGlobalMembersOrder
@@ -2003,7 +2003,7 @@ ScDPLevel::ScDPLevel( ScDPSource* pSrc, long nD, long nH, long nL ) :
nDim( nD ),
nHier( nH ),
nLev( nL ),
- pMembers( NULL ),
+ pMembers( nullptr ),
aSortInfo( EMPTY_OUSTRING, sal_True, sheet::DataPilotFieldSortMode::NAME ), // default: sort by name
nSortMeasure( 0 ),
nAutoMeasure( 0 ),
@@ -2291,7 +2291,7 @@ ScDPMembers::ScDPMembers( ScDPSource* pSrc, long nD, long nH, long nL ) :
{
case SC_DAPI_LEVEL_YEAR:
{
- const ScDPItemData* pLastNumData = NULL;
+ const ScDPItemData* pLastNumData = nullptr;
for ( SCROW n = 0 ;n <GetSrcItemsCount() ; n-- )
{
const ScDPItemData* pData = GetSrcItemDataByIndex( n );
@@ -2534,7 +2534,7 @@ ScDPMember* ScDPMembers::getByIndex(long nIndex) const
return maMembers[nIndex].get();
}
- return NULL; //TODO: exception?
+ return nullptr; //TODO: exception?
}
ScDPMember::ScDPMember(
@@ -2544,7 +2544,7 @@ ScDPMember::ScDPMember(
nHier( nH ),
nLev( nL ),
mnDataId( nIndex ),
- mpLayoutName(NULL),
+ mpLayoutName(nullptr),
nPosition( -1 ),
bVisible( true ),
bShowDet( true )
@@ -2701,7 +2701,7 @@ SC_IMPL_DUMMY_PROPERTY_LISTENER( ScDPMember )
const ScDPCache* ScDPSource::GetCache()
{
OSL_ENSURE( GetData() , "empty ScDPTableData pointer");
- return ( GetData()!=NULL ) ? &GetData()->GetCacheTable().getCache() : NULL ;
+ return ( GetData()!=nullptr ) ? &GetData()->GetCacheTable().getCache() : nullptr ;
}
const ScDPItemData* ScDPMember::GetItemData() const
@@ -2725,7 +2725,7 @@ const ScDPItemData* ScDPMembers::GetSrcItemDataByIndex(SCROW nIndex)
{
const std::vector< SCROW >& memberIds = pSource->GetData()->GetColumnEntries( nDim );
if ( nIndex >= (long )(memberIds.size()) || nIndex < 0 )
- return NULL;
+ return nullptr;
SCROW nId = memberIds[ nIndex ];
return pSource->GetItemDataById( nDim, nId );
}
diff --git a/sc/source/core/data/formulacell.cxx b/sc/source/core/data/formulacell.cxx
index 07d19a394387..cb3764b9577b 100644
--- a/sc/source/core/data/formulacell.cxx
+++ b/sc/source/core/data/formulacell.cxx
@@ -62,7 +62,7 @@
#include <grouparealistener.hxx>
#include <officecfg/Office/Common.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include <boost/ptr_container/ptr_map.hpp>
using namespace formula;
@@ -2985,7 +2985,7 @@ bool ScFormulaCell::UpdateReferenceOnShift(
// on reference update. Bail out.
return bCellStateChanged;
- boost::scoped_ptr<ScTokenArray> pOldCode;
+ std::unique_ptr<ScTokenArray> pOldCode;
if (pUndoDoc)
pOldCode.reset(pCode->Clone());
@@ -3107,7 +3107,7 @@ bool ScFormulaCell::UpdateReferenceOnMove(
return false;
bool bCellStateChanged = false;
- boost::scoped_ptr<ScTokenArray> pOldCode;
+ std::unique_ptr<ScTokenArray> pOldCode;
if (pUndoDoc)
pOldCode.reset(pCode->Clone());
@@ -3230,7 +3230,7 @@ bool ScFormulaCell::UpdateReferenceOnCopy(
// on reference update. Bail out.
return false;
- boost::scoped_ptr<ScTokenArray> pOldCode;
+ std::unique_ptr<ScTokenArray> pOldCode;
if (pUndoDoc)
pOldCode.reset(pCode->Clone());
diff --git a/sc/source/core/data/funcdesc.cxx b/sc/source/core/data/funcdesc.cxx
index 39d983c3e316..6a4ac4773533 100644
--- a/sc/source/core/data/funcdesc.cxx
+++ b/sc/source/core/data/funcdesc.cxx
@@ -34,8 +34,8 @@
#include <tools/resid.hxx>
#include <unotools/collatorwrapper.hxx>
+#include <memory>
#include <numeric>
-#include <boost/scoped_ptr.hpp>
class ScFuncRes : public Resource
{
@@ -395,7 +395,7 @@ ScFunctionList::ScFunctionList() :
for (sal_uInt16 k = 0; k < SAL_N_ELEMENTS(nDescBlock); ++k)
{
- boost::scoped_ptr<ScResourcePublisher> pBlock( new ScResourcePublisher( ScResId( nDescBlock[k] ) ) );
+ std::unique_ptr<ScResourcePublisher> pBlock( new ScResourcePublisher( ScResId( nDescBlock[k] ) ) );
// Browse for all possible OpCodes. This is not the fastest method, but
// otherwise the sub resources within the resource blocks and the
// resource blocks themselves would had to be ordered according to
@@ -767,7 +767,7 @@ OUString ScFunctionMgr::GetCategoryName(sal_uInt32 _nCategoryNumber )
return OUString();
}
- boost::scoped_ptr<ScResourcePublisher> pCategories( new ScResourcePublisher( ScResId( RID_FUNCTION_CATEGORIES ) ) );
+ std::unique_ptr<ScResourcePublisher> pCategories( new ScResourcePublisher( ScResId( RID_FUNCTION_CATEGORIES ) ) );
return SC_RESSTR(static_cast<sal_uInt16>(_nCategoryNumber));
}
diff --git a/sc/source/core/data/listenercontext.cxx b/sc/source/core/data/listenercontext.cxx
index 2745749e18c4..75010007d506 100644
--- a/sc/source/core/data/listenercontext.cxx
+++ b/sc/source/core/data/listenercontext.cxx
@@ -17,7 +17,7 @@ StartListeningContext::StartListeningContext(ScDocument& rDoc) :
mrDoc(rDoc), mpSet(new ColumnBlockPositionSet(rDoc)) {}
StartListeningContext::StartListeningContext(
- ScDocument& rDoc, const boost::shared_ptr<ColumnBlockPositionSet>& pSet) :
+ ScDocument& rDoc, const std::shared_ptr<ColumnBlockPositionSet>& pSet) :
mrDoc(rDoc), mpSet(pSet) {}
ColumnBlockPosition* StartListeningContext::getBlockPosition(SCTAB nTab, SCCOL nCol)
@@ -30,7 +30,7 @@ EndListeningContext::EndListeningContext(ScDocument& rDoc, ScTokenArray* pOldCod
mpOldCode(pOldCode), maPosDelta(0,0,0) {}
EndListeningContext::EndListeningContext(
- ScDocument& rDoc, const boost::shared_ptr<ColumnBlockPositionSet>& pSet, ScTokenArray* pOldCode) :
+ ScDocument& rDoc, const std::shared_ptr<ColumnBlockPositionSet>& pSet, ScTokenArray* pOldCode) :
mrDoc(rDoc), maSet(false), mpPosSet(pSet),
mpOldCode(pOldCode), maPosDelta(0,0,0) {}
diff --git a/sc/source/core/data/table1.cxx b/sc/source/core/data/table1.cxx
index 8c0916563c22..9ddf3b598b57 100644
--- a/sc/source/core/data/table1.cxx
+++ b/sc/source/core/data/table1.cxx
@@ -67,7 +67,7 @@ ScProgress* GetProgressBar(
// if the total number of rows is less than 1000, don't even bother
// with the progress bar because drawing progress bar can be very
// expensive especially in GTK.
- return NULL;
+ return nullptr;
}
if (pOuterProgress)
@@ -77,7 +77,7 @@ ScProgress* GetProgressBar(
return new ScProgress(
pDoc->GetDocumentShell(), ScGlobal::GetRscString(STR_PROGRESS_HEIGHTING), nTotalCount);
- return NULL;
+ return nullptr;
}
void GetOptimalHeightsInColumn(
@@ -236,32 +236,32 @@ ScTable::ScTable( ScDocument* pDoc, SCTAB nNewTab, const OUString& rNewName,
nRepeatEndX( SCCOL_REPEAT_NONE ),
nRepeatStartY( SCROW_REPEAT_NONE ),
nRepeatEndY( SCROW_REPEAT_NONE ),
- pTabProtection( NULL ),
- pColWidth( NULL ),
- mpRowHeights( static_cast<ScFlatUInt16RowSegments*>(NULL) ),
- pColFlags( NULL ),
- pRowFlags( NULL ),
+ pTabProtection( nullptr ),
+ pColWidth( nullptr ),
+ mpRowHeights( static_cast<ScFlatUInt16RowSegments*>(nullptr) ),
+ pColFlags( nullptr ),
+ pRowFlags( nullptr ),
mpHiddenCols(new ScFlatBoolColSegments),
mpHiddenRows(new ScFlatBoolRowSegments),
mpFilteredCols(new ScFlatBoolColSegments),
mpFilteredRows(new ScFlatBoolRowSegments),
- pOutlineTable( NULL ),
- pSheetEvents( NULL ),
+ pOutlineTable( nullptr ),
+ pSheetEvents( nullptr ),
nTableAreaX( 0 ),
nTableAreaY( 0 ),
nTab( nNewTab ),
pDocument( pDoc ),
- pSearchText ( NULL ),
- pSortCollator( NULL ),
- pRepeatColRange( NULL ),
- pRepeatRowRange( NULL ),
+ pSearchText ( nullptr ),
+ pSortCollator( nullptr ),
+ pRepeatColRange( nullptr ),
+ pRepeatRowRange( nullptr ),
nLockCount( 0 ),
- pScenarioRanges( NULL ),
+ pScenarioRanges( nullptr ),
aScenarioColor( COL_LIGHTGRAY ),
aTabBgColor( COL_AUTO ),
nScenarioFlags( 0 ),
- pDBDataNoName(NULL),
- mpRangeName(NULL),
+ pDBDataNoName(nullptr),
+ mpRangeName(nullptr),
mpCondFormatList( new ScConditionalFormatList() ),
bScenario(false),
bLayoutRTL(false),
@@ -455,7 +455,7 @@ long ScTable::GetNeededSize( SCCOL nCol, SCROW nRow,
aOptions.bTotalSize = bTotalSize;
return aCol[nCol].GetNeededSize
- ( nRow, pDev, nPPTX, nPPTY, rZoomX, rZoomY, bWidth, aOptions, NULL );
+ ( nRow, pDev, nPPTX, nPPTY, rZoomX, rZoomY, bWidth, aOptions, nullptr );
}
bool ScTable::SetOptimalHeight(
@@ -1071,7 +1071,7 @@ SCCOL ScTable::FindNextVisibleCol( SCCOL nCol, bool bRight ) const
{
nCol++;
SCCOL nEnd = 0;
- bool bHidden = pDocument->ColHidden(nCol, nTab, NULL, &nEnd);
+ bool bHidden = pDocument->ColHidden(nCol, nTab, nullptr, &nEnd);
if(bHidden)
nCol = nEnd +1;
@@ -1081,7 +1081,7 @@ SCCOL ScTable::FindNextVisibleCol( SCCOL nCol, bool bRight ) const
{
nCol--;
SCCOL nStart = MAXCOL;
- bool bHidden = pDocument->ColHidden(nCol, nTab, &nStart, NULL);
+ bool bHidden = pDocument->ColHidden(nCol, nTab, &nStart, nullptr);
if(bHidden)
nCol = nStart - 1;
@@ -1100,7 +1100,7 @@ SCCOL ScTable::FindNextVisibleColWithContent( SCCOL nCol, bool bRight, SCROW nRo
{
nCol++;
SCCOL nEndCol = 0;
- bool bHidden = pDocument->ColHidden( nCol, nTab, NULL, &nEndCol );
+ bool bHidden = pDocument->ColHidden( nCol, nTab, nullptr, &nEndCol );
if(bHidden)
{
nCol = nEndCol +1;
@@ -1124,7 +1124,7 @@ SCCOL ScTable::FindNextVisibleColWithContent( SCCOL nCol, bool bRight, SCROW nRo
{
nCol--;
SCCOL nStartCol = MAXCOL;
- bool bHidden = pDocument->ColHidden( nCol, nTab, &nStartCol, NULL );
+ bool bHidden = pDocument->ColHidden( nCol, nTab, &nStartCol, nullptr );
if(bHidden)
{
nCol = nStartCol -1;
@@ -1571,7 +1571,7 @@ void ScTable::UpdateReference(
// updating print ranges is not necessary with multiple print ranges
if ( bRecalcPages && GetPrintRangeCount() <= 1 )
{
- UpdatePageBreaks(NULL);
+ UpdatePageBreaks(nullptr);
pDocument->RepaintRange( ScRange(0,0,nTab,MAXCOL,MAXROW,nTab) );
}
@@ -1730,7 +1730,7 @@ void ScTable::ExtendPrintArea( OutputDevice* pDev,
for (SCCOL i = 0; i <= MAXCOL; ++i)
{
SCCOL nLastCol = i;
- if (ColHidden(i, NULL, &nLastCol))
+ if (ColHidden(i, nullptr, &nLastCol))
{
// Columns are hidden in this range.
aSkipCols.setTrue(i, nLastCol);
@@ -1813,7 +1813,7 @@ void ScTable::MaybeAddExtraColumn(SCCOL& rCol, SCROW nRow, OutputDevice* pDev, d
Fraction aZoom(1,1);
nPixel = aCol[rCol].GetNeededSize(
- nRow, pDev, nPPTX, nPPTY, aZoom, aZoom, true, aOptions, NULL );
+ nRow, pDev, nPPTX, nPPTY, aZoom, aZoom, true, aOptions, nullptr );
aCol[rCol].SetTextWidth(nRow, static_cast<sal_uInt16>(nPixel));
}
@@ -1898,7 +1898,7 @@ void ScTable::CopyPrintRange(const ScTable& rTable)
bPrintEntireSheet = rTable.bPrintEntireSheet;
delete pRepeatColRange;
- pRepeatColRange = NULL;
+ pRepeatColRange = nullptr;
if (rTable.pRepeatColRange)
{
pRepeatColRange = new ScRange(*rTable.pRepeatColRange);
@@ -1907,7 +1907,7 @@ void ScTable::CopyPrintRange(const ScTable& rTable)
}
delete pRepeatRowRange;
- pRepeatRowRange = NULL;
+ pRepeatRowRange = nullptr;
if (rTable.pRepeatRowRange)
{
pRepeatRowRange = new ScRange(*rTable.pRepeatRowRange);
@@ -1970,7 +1970,7 @@ void ScTable::SetPrintEntireSheet()
const ScRange* ScTable::GetPrintRange(sal_uInt16 nPos) const
{
- return (nPos < GetPrintRangeCount()) ? &aPrintRanges[ nPos ] : NULL;
+ return (nPos < GetPrintRangeCount()) ? &aPrintRanges[ nPos ] : nullptr;
}
void ScTable::FillPrintSaver( ScPrintSaverTab& rSaveTab ) const
@@ -1987,7 +1987,7 @@ void ScTable::RestorePrintRanges( const ScPrintSaverTab& rSaveTab )
SetRepeatRowRange( rSaveTab.GetRepeatRow() );
InvalidatePageBreaks(); // #i117952# forget page breaks for an old print range
- UpdatePageBreaks(NULL);
+ UpdatePageBreaks(nullptr);
}
SCROW ScTable::VisibleDataCellIterator::ROW_NOT_FOUND = -1;
@@ -2203,7 +2203,7 @@ ScRefCellValue ScTable::GetRefCellValue( SCCOL nCol, SCROW nRow )
SvtBroadcaster* ScTable::GetBroadcaster( SCCOL nCol, SCROW nRow )
{
if (!ValidColRow(nCol, nRow))
- return NULL;
+ return nullptr;
return aCol[nCol].GetBroadcaster(nRow);
}
@@ -2268,7 +2268,7 @@ void ScTable::DumpFormulaGroups( SCCOL nCol ) const
const SvtBroadcaster* ScTable::GetBroadcaster( SCCOL nCol, SCROW nRow ) const
{
if (!ValidColRow(nCol, nRow))
- return NULL;
+ return nullptr;
return aCol[nCol].GetBroadcaster(nRow);
}
diff --git a/sc/source/core/data/table2.cxx b/sc/source/core/data/table2.cxx
index f28be30d1d6d..3b9c02a71d54 100644
--- a/sc/source/core/data/table2.cxx
+++ b/sc/source/core/data/table2.cxx
@@ -863,7 +863,7 @@ void ScTable::TransposeClip( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
SCROW nAttrRow1;
SCROW nAttrRow2;
const ScPatternAttr* pPattern;
- boost::scoped_ptr<ScAttrIterator> pAttrIter(aCol[nCol].CreateAttrIterator( nRow1, nRow2 ));
+ std::unique_ptr<ScAttrIterator> pAttrIter(aCol[nCol].CreateAttrIterator( nRow1, nRow2 ));
while ( (pPattern = pAttrIter->Next( nAttrRow1, nAttrRow2 )) != 0 )
{
if ( !IsDefaultItem( pPattern ) )
diff --git a/sc/source/core/data/table3.cxx b/sc/source/core/data/table3.cxx
index 9775e14ab9f7..706e0e593ab5 100644
--- a/sc/source/core/data/table3.cxx
+++ b/sc/source/core/data/table3.cxx
@@ -67,11 +67,10 @@
#include <svl/sharedstringpool.hxx>
+#include <memory>
#include <unordered_set>
#include <vector>
#include <boost/checked_delete.hpp>
-#include <boost/scoped_ptr.hpp>
-#include <memory>
#include <boost/noncopyable.hpp>
#include <mdds/flat_segment_tree.hpp>
@@ -252,7 +251,7 @@ public:
typedef std::vector<Row*> RowsType;
private:
- boost::scoped_ptr<RowsType> mpRows; /// row-wise data table for sort by row operation.
+ std::unique_ptr<RowsType> mpRows; /// row-wise data table for sort by row operation.
ScSortInfo*** pppInfo;
SCSIZE nCount;
@@ -869,7 +868,7 @@ class ListenerStartAction : public sc::ColumnSpanSet::ColumnAction
{
ScColumn* mpCol;
- boost::shared_ptr<sc::ColumnBlockPositionSet> mpPosSet;
+ std::shared_ptr<sc::ColumnBlockPositionSet> mpPosSet;
sc::StartListeningContext maStartCxt;
sc::EndListeningContext maEndCxt;
@@ -1708,7 +1707,7 @@ void ScTable::Sort(
if(pProgress)
pProgress->SetState( 0, nLastRow-nRow1 );
- boost::scoped_ptr<ScSortInfoArray> pArray(CreateSortInfoArray(aSortParam, nRow1, nLastRow, bKeepQuery, bUpdateRefs));
+ std::unique_ptr<ScSortInfoArray> pArray(CreateSortInfoArray(aSortParam, nRow1, nLastRow, bKeepQuery, bUpdateRefs));
if ( nLastRow - nRow1 > 255 )
DecoladeRow(pArray.get(), nRow1, nLastRow);
@@ -1735,7 +1734,7 @@ void ScTable::Sort(
if(pProgress)
pProgress->SetState( 0, nLastCol-nCol1 );
- boost::scoped_ptr<ScSortInfoArray> pArray(CreateSortInfoArray(aSortParam, nCol1, nLastCol, bKeepQuery, bUpdateRefs));
+ std::unique_ptr<ScSortInfoArray> pArray(CreateSortInfoArray(aSortParam, nCol1, nLastCol, bKeepQuery, bUpdateRefs));
QuickSort(pArray.get(), nCol1, nLastCol);
SortReorderByColumn(pArray.get(), aSortParam.nRow1, aSortParam.nRow2, aSortParam.bIncludePattern, pProgress);
@@ -1755,7 +1754,7 @@ void ScTable::Reorder( const sc::ReorderParam& rParam, ScProgress* pProgress )
if (rParam.maOrderIndices.empty())
return;
- boost::scoped_ptr<ScSortInfoArray> pArray(CreateSortInfoArray(rParam));
+ std::unique_ptr<ScSortInfoArray> pArray(CreateSortInfoArray(rParam));
if (!pArray)
return;
@@ -2737,7 +2736,7 @@ void ScTable::TopTenQuery( ScQueryParam& rParam )
bSortCollatorInitialized = true;
InitSortCollator( aLocalSortParam );
}
- boost::scoped_ptr<ScSortInfoArray> pArray(CreateSortInfoArray(aSortParam, nRow1, rParam.nRow2, bGlobalKeepQuery, false));
+ std::unique_ptr<ScSortInfoArray> pArray(CreateSortInfoArray(aSortParam, nRow1, rParam.nRow2, bGlobalKeepQuery, false));
DecoladeRow( pArray.get(), nRow1, rParam.nRow2 );
QuickSort( pArray.get(), nRow1, rParam.nRow2 );
ScSortInfo** ppInfo = pArray->GetFirstArray();
diff --git a/sc/source/core/data/table4.cxx b/sc/source/core/data/table4.cxx
index 5b6479cb95be..ee1a29a99f72 100644
--- a/sc/source/core/data/table4.cxx
+++ b/sc/source/core/data/table4.cxx
@@ -64,7 +64,7 @@
#include <listenercontext.hxx>
#include <math.h>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
// STATIC DATA -----------------------------------------------------------
@@ -1178,7 +1178,7 @@ void ScTable::FillFormulaVertical(
aCol[nCol].DeleteRanges(aSpans, IDF_VALUE | IDF_DATETIME | IDF_STRING | IDF_FORMULA | IDF_OUTLINE, false);
aCol[nCol].CloneFormulaCell(rSrcCell, sc::CellTextAttr(), aSpans, NULL);
- boost::shared_ptr<sc::ColumnBlockPositionSet> pSet(new sc::ColumnBlockPositionSet(*pDocument));
+ std::shared_ptr<sc::ColumnBlockPositionSet> pSet(new sc::ColumnBlockPositionSet(*pDocument));
sc::StartListeningContext aStartCxt(*pDocument, pSet);
sc::EndListeningContext aEndCxt(*pDocument, pSet);
diff --git a/sc/source/core/data/validat.cxx b/sc/source/core/data/validat.cxx
index 42d06a623edf..e168ec6110f1 100644
--- a/sc/source/core/data/validat.cxx
+++ b/sc/source/core/data/validat.cxx
@@ -51,7 +51,7 @@
#include "scmatrix.hxx"
#include <math.h>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace formula;
@@ -812,7 +812,7 @@ bool ScValidationData::FillSelectionList(std::vector<ScTypedStrData>& rStrColl,
if( HasSelectionList() )
{
- boost::scoped_ptr<ScTokenArray> pTokArr( CreateTokenArry(0) );
+ std::unique_ptr<ScTokenArray> pTokArr( CreateTokenArry(0) );
// *** try if formula is a string list ***
@@ -865,7 +865,7 @@ bool ScValidationData::IsListValid( ScRefCellValue& rCell, const ScAddress& rPos
5) A formula resulting in a cell/range reference or matrix/array.
*/
- boost::scoped_ptr< ScTokenArray > pTokArr( CreateTokenArry( 0 ) );
+ std::unique_ptr< ScTokenArray > pTokArr( CreateTokenArry( 0 ) );
// *** try if formula is a string list ***
diff --git a/sc/source/core/opencl/formulagroupcl.cxx b/sc/source/core/opencl/formulagroupcl.cxx
index b72c3177d0ec..8fab03dbbf47 100644
--- a/sc/source/core/opencl/formulagroupcl.cxx
+++ b/sc/source/core/opencl/formulagroupcl.cxx
@@ -89,7 +89,6 @@ const unsigned long __nan[2] = {0xffffffff, 0x7fffffff};
#include <rtl/digest.h>
-#include <boost/scoped_ptr.hpp>
#include <memory>
using namespace formula;
@@ -950,7 +949,7 @@ class DynamicKernelSlidingArgument : public Base
{
public:
DynamicKernelSlidingArgument( const ScCalcConfig& config, const std::string& s,
- FormulaTreeNodeRef ft, boost::shared_ptr<SlidingFunctionBase>& CodeGen,
+ FormulaTreeNodeRef ft, std::shared_ptr<SlidingFunctionBase>& CodeGen,
int index = 0 ) :
Base(config, s, ft, index), mpCodeGen(CodeGen), mpClmem2(NULL)
{
@@ -1126,7 +1125,7 @@ protected:
bool bIsStartFixed, bIsEndFixed;
const formula::DoubleVectorRefToken* mpDVR;
// from parent nodes
- boost::shared_ptr<SlidingFunctionBase> mpCodeGen;
+ std::shared_ptr<SlidingFunctionBase> mpCodeGen;
// controls whether to invoke the reduction kernel during marshaling or not
cl_mem mpClmem2;
};
@@ -1136,7 +1135,7 @@ class DynamicKernelMixedSlidingArgument : public VectorRef
{
public:
DynamicKernelMixedSlidingArgument( const ScCalcConfig& config, const std::string& s,
- FormulaTreeNodeRef ft, boost::shared_ptr<SlidingFunctionBase>& CodeGen,
+ FormulaTreeNodeRef ft, std::shared_ptr<SlidingFunctionBase>& CodeGen,
int index = 0 ) :
VectorRef(config, s, ft),
mDoubleArgument(mCalcConfig, s, ft, CodeGen, index),
@@ -1250,7 +1249,7 @@ class ParallelReductionVectorRef : public Base
{
public:
ParallelReductionVectorRef( const ScCalcConfig& config, const std::string& s,
- FormulaTreeNodeRef ft, boost::shared_ptr<SlidingFunctionBase>& CodeGen,
+ FormulaTreeNodeRef ft, std::shared_ptr<SlidingFunctionBase>& CodeGen,
int index = 0 ) :
Base(config, s, ft, index), mpCodeGen(CodeGen), mpClmem2(NULL)
{
@@ -1663,7 +1662,7 @@ protected:
bool bIsStartFixed, bIsEndFixed;
const formula::DoubleVectorRefToken* mpDVR;
// from parent nodes
- boost::shared_ptr<SlidingFunctionBase> mpCodeGen;
+ std::shared_ptr<SlidingFunctionBase> mpCodeGen;
// controls whether to invoke the reduction kernel during marshaling or not
cl_mem mpClmem2;
};
@@ -2540,7 +2539,7 @@ public:
private:
SubArgumentsType mvSubArguments;
- boost::shared_ptr<SlidingFunctionBase> mpCodeGen;
+ std::shared_ptr<SlidingFunctionBase> mpCodeGen;
cl_mem mpClmem2;
};
@@ -2554,7 +2553,7 @@ DynamicKernelArgumentRef SoPHelper( const ScCalcConfig& config,
template<class Base>
DynamicKernelArgument* VectorRefFactory( const ScCalcConfig& config, const std::string& s,
const FormulaTreeNodeRef& ft,
- boost::shared_ptr<SlidingFunctionBase>& pCodeGen,
+ std::shared_ptr<SlidingFunctionBase>& pCodeGen,
int index )
{
//Black lists ineligible classes here ..
diff --git a/sc/source/core/opencl/opbase.hxx b/sc/source/core/opencl/opbase.hxx
index ba087149262a..9a49703f7532 100644
--- a/sc/source/core/opencl/opbase.hxx
+++ b/sc/source/core/opencl/opbase.hxx
@@ -16,8 +16,8 @@
#include <formula/token.hxx>
#include <formula/vectortoken.hxx>
-#include <boost/shared_ptr.hpp>
#include <boost/noncopyable.hpp>
+#include <memory>
#include <set>
#include "calcconfig.hxx"
@@ -62,7 +62,7 @@ public:
int mLineNumber;
};
-typedef boost::shared_ptr<FormulaTreeNode> FormulaTreeNodeRef;
+typedef std::shared_ptr<FormulaTreeNode> FormulaTreeNodeRef;
class FormulaTreeNode
{
@@ -129,7 +129,7 @@ protected:
FormulaTreeNodeRef mFormulaTree;
};
-typedef boost::shared_ptr<DynamicKernelArgument> DynamicKernelArgumentRef;
+typedef std::shared_ptr<DynamicKernelArgument> DynamicKernelArgumentRef;
/// Holds an input (read-only) argument reference to a SingleVectorRef.
/// or a DoubleVectorRef for non-sliding-window argument of complex functions
diff --git a/sc/source/core/tool/chartlis.cxx b/sc/source/core/tool/chartlis.cxx
index a7ddf3a58e72..398fd78ffb61 100644
--- a/sc/source/core/tool/chartlis.cxx
+++ b/sc/source/core/tool/chartlis.cxx
@@ -96,10 +96,10 @@ void ScChartListener::ExternalRefListener::removeFileId(sal_uInt16 nFileId)
ScChartListener::ScChartListener( const OUString& rName, ScDocument* pDocP,
const ScRangeListRef& rRangeList ) :
SvtListener(),
- mpExtRefListener(NULL),
+ mpExtRefListener(nullptr),
mpTokens(new vector<ScTokenRef>),
maName(rName),
- pUnoData( NULL ),
+ pUnoData( nullptr ),
mpDoc( pDocP ),
bUsed( false ),
bDirty( false ),
@@ -110,10 +110,10 @@ ScChartListener::ScChartListener( const OUString& rName, ScDocument* pDocP,
ScChartListener::ScChartListener( const OUString& rName, ScDocument* pDocP, vector<ScTokenRef>* pTokens ) :
SvtListener(),
- mpExtRefListener(NULL),
+ mpExtRefListener(nullptr),
mpTokens(pTokens),
maName(rName),
- pUnoData( NULL ),
+ pUnoData( nullptr ),
mpDoc( pDocP ),
bUsed( false ),
bDirty( false ),
@@ -123,10 +123,10 @@ ScChartListener::ScChartListener( const OUString& rName, ScDocument* pDocP, vect
ScChartListener::ScChartListener( const ScChartListener& r ) :
SvtListener(),
- mpExtRefListener(NULL),
+ mpExtRefListener(nullptr),
mpTokens(new vector<ScTokenRef>(*r.mpTokens)),
maName(r.maName),
- pUnoData( NULL ),
+ pUnoData( nullptr ),
mpDoc( r.mpDoc ),
bUsed( false ),
bDirty( r.bDirty ),
@@ -451,13 +451,13 @@ void ScChartListenerCollection::removeByName(const OUString& rName)
ScChartListener* ScChartListenerCollection::findByName(const OUString& rName)
{
ListenersType::iterator it = maListeners.find(rName);
- return it == maListeners.end() ? NULL : it->second;
+ return it == maListeners.end() ? nullptr : it->second;
}
const ScChartListener* ScChartListenerCollection::findByName(const OUString& rName) const
{
ListenersType::const_iterator it = maListeners.find(rName);
- return it == maListeners.end() ? NULL : it->second;
+ return it == maListeners.end() ? nullptr : it->second;
}
bool ScChartListenerCollection::hasListeners() const
diff --git a/sc/source/core/tool/chgtrack.cxx b/sc/source/core/tool/chgtrack.cxx
index 3517f26f6cef..c5a4b0895d39 100644
--- a/sc/source/core/tool/chgtrack.cxx
+++ b/sc/source/core/tool/chgtrack.cxx
@@ -43,7 +43,7 @@
#include <sfx2/app.hxx>
#include <unotools/useroptions.hxx>
#include <sfx2/sfxsids.hrc>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
IMPL_FIXEDMEMPOOL_NEWDEL( ScChangeActionCellListEntry )
IMPL_FIXEDMEMPOOL_NEWDEL( ScChangeActionLinkEntry )
@@ -1803,7 +1803,7 @@ void ScChangeActionContent::GetFormulaString(
else
{
OSL_FAIL( "ScChangeActionContent::GetFormulaString: aPos != pCell->aPos" );
- boost::scoped_ptr<ScFormulaCell> pNew(new ScFormulaCell( *pCell, *pCell->GetDocument(), aPos ));
+ std::unique_ptr<ScFormulaCell> pNew(new ScFormulaCell( *pCell, *pCell->GetDocument(), aPos ));
pNew->GetFormula( rStr );
}
}
@@ -4209,7 +4209,7 @@ bool ScChangeTrack::Reject( ScChangeAction* pAct, bool bShared )
if ( !pAct->IsRejectable() )
return false;
- boost::scoped_ptr<ScChangeActionMap> pMap;
+ std::unique_ptr<ScChangeActionMap> pMap;
if ( pAct->HasDependent() )
{
pMap.reset(new ScChangeActionMap);
diff --git a/sc/source/core/tool/interpr1.cxx b/sc/source/core/tool/interpr1.cxx
index a9f877253bdd..8dfd0db84852 100644
--- a/sc/source/core/tool/interpr1.cxx
+++ b/sc/source/core/tool/interpr1.cxx
@@ -7204,7 +7204,7 @@ void ScInterpreter::ScIndirect()
ScCompiler aComp( pDok, aPos);
aComp.SetGrammar( pDok->GetGrammar());
aComp.SetRefConvention( eConv); // must be after grammar
- boost::scoped_ptr<ScTokenArray> pArr( aComp.CompileString( sRefStr));
+ std::unique_ptr<ScTokenArray> pArr( aComp.CompileString( sRefStr));
// Whatever.. use only the specific case.
if (!pArr->HasOpCode( ocTableRef))
diff --git a/sc/source/core/tool/interpr7.cxx b/sc/source/core/tool/interpr7.cxx
index 822e9e2d3d50..027c40391583 100644
--- a/sc/source/core/tool/interpr7.cxx
+++ b/sc/source/core/tool/interpr7.cxx
@@ -21,8 +21,8 @@
#include <dpobject.hxx>
#include <document.hxx>
-#include <boost/shared_ptr.hpp>
#include <cstring>
+#include <memory>
using namespace com::sun::star;
@@ -46,10 +46,10 @@ void ScInterpreter::ScFilterXML()
OString aOString = OUStringToOString( aString, RTL_TEXTENCODING_UTF8 );
const char* pXML = aOString.getStr();
- boost::shared_ptr<xmlParserCtxt> pContext(
+ std::shared_ptr<xmlParserCtxt> pContext(
xmlNewParserCtxt(), xmlFreeParserCtxt );
- boost::shared_ptr<xmlDoc> pDoc( xmlParseMemory( pXML, aOString.getLength() ),
+ std::shared_ptr<xmlDoc> pDoc( xmlParseMemory( pXML, aOString.getLength() ),
xmlFreeDoc );
if(!pDoc)
@@ -58,10 +58,10 @@ void ScInterpreter::ScFilterXML()
return;
}
- boost::shared_ptr<xmlXPathContext> pXPathCtx( xmlXPathNewContext(pDoc.get()),
+ std::shared_ptr<xmlXPathContext> pXPathCtx( xmlXPathNewContext(pDoc.get()),
xmlXPathFreeContext );
- boost::shared_ptr<xmlXPathObject> pXPathObj( xmlXPathEvalExpression(BAD_CAST(pXPathExpr), pXPathCtx.get()),
+ std::shared_ptr<xmlXPathObject> pXPathObj( xmlXPathEvalExpression(BAD_CAST(pXPathExpr), pXPathCtx.get()),
xmlXPathFreeObject );
if(!pXPathObj)
@@ -92,13 +92,13 @@ void ScInterpreter::ScFilterXML()
{
xmlNsPtr ns = reinterpret_cast<xmlNsPtr>(pNodeSet->nodeTab[0]);
xmlNodePtr cur = reinterpret_cast<xmlNodePtr>(ns->next);
- boost::shared_ptr<xmlChar> pChar2(xmlNodeGetContent(cur), xmlFree);
+ std::shared_ptr<xmlChar> pChar2(xmlNodeGetContent(cur), xmlFree);
aResult = OStringToOUString(OString(reinterpret_cast<char*>(pChar2.get())), RTL_TEXTENCODING_UTF8);
}
else
{
xmlNodePtr cur = pNodeSet->nodeTab[0];
- boost::shared_ptr<xmlChar> pChar2(xmlNodeGetContent(cur), xmlFree);
+ std::shared_ptr<xmlChar> pChar2(xmlNodeGetContent(cur), xmlFree);
aResult = OStringToOUString(OString(reinterpret_cast<char*>(pChar2.get())), RTL_TEXTENCODING_UTF8);
}
}
diff --git a/sc/source/core/tool/rangenam.cxx b/sc/source/core/tool/rangenam.cxx
index ebad87338d13..f861fb5b5345 100644
--- a/sc/source/core/tool/rangenam.cxx
+++ b/sc/source/core/tool/rangenam.cxx
@@ -18,7 +18,7 @@
*/
#include <string.h>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include <unotools/collatorwrapper.hxx>
#include <unotools/transliterationwrapper.hxx>
#include <com/sun/star/sheet/NamedRangeFlag.hpp>
@@ -161,7 +161,7 @@ void ScRangeData::CompileRangeData( const OUString& rSymbol, bool bSetError )
if (bSetError)
aComp.SetExtendedErrorDetection( ScCompiler::EXTENDED_ERROR_DETECTION_NAME_NO_BREAK);
ScTokenArray* pNewCode = aComp.CompileString( rSymbol );
- boost::scoped_ptr<ScTokenArray> pOldCode( pCode); // old pCode will be deleted
+ std::unique_ptr<ScTokenArray> pOldCode( pCode); // old pCode will be deleted
pCode = pNewCode;
pCode->SetFromRangeName(true);
if( !pCode->GetCodeError() )
@@ -270,7 +270,7 @@ void ScRangeData::GetSymbol( OUString& rSymbol, const ScAddress& rPos, const For
void ScRangeData::UpdateSymbol( OUStringBuffer& rBuffer, const ScAddress& rPos,
const FormulaGrammar::Grammar eGrammar )
{
- boost::scoped_ptr<ScTokenArray> pTemp( pCode->Clone() );
+ std::unique_ptr<ScTokenArray> pTemp( pCode->Clone() );
ScCompiler aComp( pDoc, rPos, *pTemp.get());
aComp.SetGrammar(eGrammar);
aComp.MoveRelWrap(GetMaxCol(), GetMaxRow());
@@ -622,7 +622,7 @@ void ScRangeData::ValidateTabRefs()
void ScRangeData::SetCode( ScTokenArray& rArr )
{
- boost::scoped_ptr<ScTokenArray> pOldCode( pCode); // old pCode will be deleted
+ std::unique_ptr<ScTokenArray> pOldCode( pCode); // old pCode will be deleted
pCode = new ScTokenArray( rArr );
pCode->SetFromRangeName(true);
InitCode();
diff --git a/sc/source/core/tool/reftokenhelper.cxx b/sc/source/core/tool/reftokenhelper.cxx
index 4c7371a35343..70b2faa0e3a1 100644
--- a/sc/source/core/tool/reftokenhelper.cxx
+++ b/sc/source/core/tool/reftokenhelper.cxx
@@ -27,7 +27,7 @@
#include <formula/grammar.hxx>
#include <formula/token.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace formula;
@@ -53,7 +53,7 @@ void ScRefTokenHelper::compileRangeRepresentation(
ScCompiler aCompiler(pDoc, ScAddress(0,0,0));
aCompiler.SetGrammar(eGrammar);
- boost::scoped_ptr<ScTokenArray> pArray(aCompiler.CompileString(aToken));
+ std::unique_ptr<ScTokenArray> pArray(aCompiler.CompileString(aToken));
// There MUST be exactly one reference per range token and nothing
// else, and it MUST be a valid reference, not some #REF!
diff --git a/sc/source/filter/dif/difimp.cxx b/sc/source/filter/dif/difimp.cxx
index f46d25c8d324..4bf44983add4 100644
--- a/sc/source/filter/dif/difimp.cxx
+++ b/sc/source/filter/dif/difimp.cxx
@@ -32,7 +32,7 @@
#include "scerrors.hxx"
#include "scitems.hxx"
#include "stringutil.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
const sal_Unicode pKeyTABLE[] = { 'T', 'A', 'B', 'L', 'E', 0 };
const sal_Unicode pKeyVECTORS[] = { 'V', 'E', 'C', 'T', 'O', 'R', 'S', 0 };
@@ -938,7 +938,7 @@ void DifAttrCache::Apply( ScDocument& rDoc, SCTAB nTab )
{
if( bPlain )
{
- boost::scoped_ptr<ScPatternAttr> pPatt;
+ std::unique_ptr<ScPatternAttr> pPatt;
for( SCCOL nCol = 0 ; nCol <= MAXCOL ; nCol++ )
{
diff --git a/sc/source/filter/excel/excel.cxx b/sc/source/filter/excel/excel.cxx
index 6230384ce5c9..d193bb5a5154 100644
--- a/sc/source/filter/excel/excel.cxx
+++ b/sc/source/filter/excel/excel.cxx
@@ -41,7 +41,7 @@
#include "excimp8.hxx"
#include "exp_op.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
FltError ScFormatFilterPluginImpl::ScImportExcel( SfxMedium& rMedium, ScDocument* pDocument, const EXCIMPFORMAT eFormat )
{
@@ -120,7 +120,7 @@ FltError ScFormatFilterPluginImpl::ScImportExcel( SfxMedium& rMedium, ScDocument
pBookStrm->SetBufferSize( 0x8000 ); // still needed?
XclImpRootData aImpData( eBiff, rMedium, xRootStrg, *pDocument, RTL_TEXTENCODING_MS_1252 );
- boost::scoped_ptr< ImportExcel > xFilter;
+ std::unique_ptr< ImportExcel > xFilter;
switch( eBiff )
{
case EXC_BIFF2:
diff --git a/sc/source/filter/excel/read.cxx b/sc/source/filter/excel/read.cxx
index ac2bf887ca8a..fae3ffd45184 100644
--- a/sc/source/filter/excel/read.cxx
+++ b/sc/source/filter/excel/read.cxx
@@ -39,7 +39,7 @@
#include "imp_op.hxx"
#include "excimp8.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
FltError ImportExcel::Read()
{
@@ -81,7 +81,7 @@ FltError ImportExcel::Read()
OSL_ENSURE( &aIn != NULL, "-ImportExcel::Read(): No Stream - what happened?!" );
- boost::scoped_ptr< ScfSimpleProgressBar > pProgress( new ScfSimpleProgressBar(
+ std::unique_ptr< ScfSimpleProgressBar > pProgress( new ScfSimpleProgressBar(
aIn.GetSvStreamSize(), GetDocShell(), STR_LOAD_DOC ) );
/* #i104057# Need to track a base position for progress bar calculation,
@@ -811,7 +811,7 @@ FltError ImportExcel8::Read()
FltError eLastErr = eERR_OK;
- boost::scoped_ptr< ScfSimpleProgressBar > pProgress( new ScfSimpleProgressBar(
+ std::unique_ptr< ScfSimpleProgressBar > pProgress( new ScfSimpleProgressBar(
aIn.GetSvStreamSize(), GetDocShell(), STR_LOAD_DOC ) );
/* #i104057# Need to track a base position for progress bar calculation,
diff --git a/sc/source/filter/excel/xechart.cxx b/sc/source/filter/excel/xechart.cxx
index c981c3d2a716..1cc23139673e 100644
--- a/sc/source/filter/excel/xechart.cxx
+++ b/sc/source/filter/excel/xechart.cxx
@@ -69,7 +69,7 @@
#include "xepage.hxx"
#include "xestyle.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using ::com::sun::star::uno::Any;
using ::com::sun::star::uno::Reference;
@@ -898,7 +898,7 @@ sal_uInt16 XclExpChSourceLink::ConvertDataSequence( Reference< XDataSequence > x
OUString aRangeRepr = xDataSeq->getSourceRangeRepresentation();
ScCompiler aComp( &GetDocRef(), ScAddress() );
aComp.SetGrammar( GetDocRef().GetGrammar() );
- boost::scoped_ptr<ScTokenArray> pArray(aComp.CompileString(aRangeRepr));
+ std::unique_ptr<ScTokenArray> pArray(aComp.CompileString(aRangeRepr));
if( !pArray )
return nDefCount;
diff --git a/sc/source/filter/excel/xecontent.cxx b/sc/source/filter/excel/xecontent.cxx
index e5860a87984b..0c7fb513aab0 100644
--- a/sc/source/filter/excel/xecontent.cxx
+++ b/sc/source/filter/excel/xecontent.cxx
@@ -674,7 +674,7 @@ XclExpCFImpl::XclExpCFImpl( const XclExpRoot& rRoot, const ScCondFormatEntry& rF
XclExpFormulaCompiler& rFmlaComp = GetFormulaCompiler();
- boost::scoped_ptr< ScTokenArray > xScTokArr( mrFormatEntry.CreateTokenArry( 0 ) );
+ std::unique_ptr< ScTokenArray > xScTokArr( mrFormatEntry.CreateTokenArry( 0 ) );
mxTokArr1 = rFmlaComp.CreateFormula( EXC_FMLATYPE_CONDFMT, *xScTokArr );
if( bFmla2 )
@@ -920,7 +920,7 @@ void XclExpCFImpl::SaveXml( XclExpXmlStream& rStrm )
// we need to write the text without quotes
// we have to actually get the string from
// the token array for that
- boost::scoped_ptr<ScTokenArray> pTokenArray(mrFormatEntry.CreateTokenArry(0));
+ std::unique_ptr<ScTokenArray> pTokenArray(mrFormatEntry.CreateTokenArry(0));
if(pTokenArray->GetLen())
aText = XclXmlUtils::ToOString(pTokenArray->First()->GetString().getString());
}
@@ -1592,7 +1592,7 @@ XclExpDV::XclExpDV( const XclExpRoot& rRoot, sal_uLong nScHandle ) :
// formulas
XclExpFormulaCompiler& rFmlaComp = GetFormulaCompiler();
- boost::scoped_ptr< ScTokenArray > xScTokArr;
+ std::unique_ptr< ScTokenArray > xScTokArr;
// first formula
xScTokArr.reset( pValData->CreateTokenArry( 0 ) );
diff --git a/sc/source/filter/excel/xeformula.cxx b/sc/source/filter/excel/xeformula.cxx
index 511c6435e3a2..90c1a1452bfd 100644
--- a/sc/source/filter/excel/xeformula.cxx
+++ b/sc/source/filter/excel/xeformula.cxx
@@ -81,7 +81,7 @@ struct XclExpTokenConvInfo
/** Vector of token position and conversion for all operands of an operator,
or for all parameters of a function. */
-struct XclExpOperandList : public ::std::vector< XclExpTokenConvInfo >
+struct XclExpOperandList : public std::vector< XclExpTokenConvInfo >
{
inline explicit XclExpOperandList() { reserve( 2 ); }
void AppendOperand( sal_uInt16 nTokPos, XclFuncParamConv eConv, bool bValType );
@@ -96,8 +96,8 @@ void XclExpOperandList::AppendOperand( sal_uInt16 nTokPos, XclFuncParamConv eCon
rConvInfo.mbValType = bValType;
}
-typedef boost::shared_ptr< XclExpOperandList > XclExpOperandListRef;
-typedef ::std::vector< XclExpOperandListRef > XclExpOperandListVector;
+typedef std::shared_ptr< XclExpOperandList > XclExpOperandListRef;
+typedef std::vector< XclExpOperandListRef > XclExpOperandListVector;
/** Encapsulates all data needed for a call to an external function (macro, add-in). */
struct XclExpExtFuncData
@@ -256,7 +256,7 @@ static const XclExpCompConfig spConfigTable[] =
/** Working data of the formula compiler. Used to push onto a stack for recursive calls. */
struct XclExpCompData
{
- typedef boost::shared_ptr< ScTokenArray > ScTokenArrayRef;
+ typedef std::shared_ptr< ScTokenArray > ScTokenArrayRef;
const XclExpCompConfig& mrCfg; /// Configuration for current formula type.
ScTokenArrayRef mxOwnScTokArr; /// Own clone of a Calc token array.
@@ -449,9 +449,9 @@ private:
void AppendExt( const OUString& rString );
private:
- typedef ::std::map< XclFormulaType, XclExpCompConfig > XclExpCompConfigMap;
- typedef boost::shared_ptr< XclExpCompData > XclExpCompDataRef;
- typedef ::std::vector< XclExpCompDataRef > XclExpCompDataVector;
+ typedef std::map< XclFormulaType, XclExpCompConfig > XclExpCompConfigMap;
+ typedef std::shared_ptr< XclExpCompData > XclExpCompDataRef;
+ typedef std::vector< XclExpCompDataRef > XclExpCompDataVector;
XclExpCompConfigMap maCfgMap; /// Compiler configuration map for all formula types.
XclFunctionProvider maFuncProv; /// Excel function data provider.
diff --git a/sc/source/filter/excel/xelink.cxx b/sc/source/filter/excel/xelink.cxx
index a936f457c61d..e52a185ff979 100644
--- a/sc/source/filter/excel/xelink.cxx
+++ b/sc/source/filter/excel/xelink.cxx
@@ -91,7 +91,7 @@ private:
virtual void WriteAddData( XclExpStream& rStrm ) SAL_OVERRIDE;
private:
- typedef boost::shared_ptr< XclExpCachedMatrix > XclExpCachedMatRef;
+ typedef std::shared_ptr< XclExpCachedMatrix > XclExpCachedMatRef;
XclExpCachedMatRef mxMatrix; /// Cached results of the DDE link.
};
@@ -245,7 +245,7 @@ protected:
void WriteExtNameBufferXml( XclExpXmlStream& rStrm );
protected:
- typedef boost::shared_ptr< XclExpExtNameBuffer > XclExpExtNameBfrRef;
+ typedef std::shared_ptr< XclExpExtNameBuffer > XclExpExtNameBfrRef;
XclExpExtNameBfrRef mxExtNameBfr; /// List of EXTERNNAME records.
};
diff --git a/sc/source/filter/excel/xestyle.cxx b/sc/source/filter/excel/xestyle.cxx
index 3f3e372e6f47..5a5c1305ce66 100644
--- a/sc/source/filter/excel/xestyle.cxx
+++ b/sc/source/filter/excel/xestyle.cxx
@@ -300,7 +300,7 @@ private:
private:
typedef boost::ptr_vector< XclListColor > XclListColorList;
- typedef boost::shared_ptr< XclListColorList > XclListColorListRef;
+ typedef std::shared_ptr< XclListColorList > XclListColorListRef;
typedef ::std::vector< XclColorIdData > XclColorIdDataVec;
typedef ::std::vector< XclPaletteColor > XclPaletteColorVec;
diff --git a/sc/source/filter/excel/xichart.cxx b/sc/source/filter/excel/xichart.cxx
index 9be0c5592098..6283f8022139 100644
--- a/sc/source/filter/excel/xichart.cxx
+++ b/sc/source/filter/excel/xichart.cxx
@@ -122,7 +122,7 @@ using ::com::sun::star::chart2::data::LabeledDataSequence;
using ::formula::FormulaToken;
using ::formula::StackVar;
-using ::boost::shared_ptr;
+using ::std::shared_ptr;
using ::std::pair;
using ::std::unique_ptr;
diff --git a/sc/source/filter/excel/xiescher.cxx b/sc/source/filter/excel/xiescher.cxx
index 148e7b71b1c3..2bab340dcf6f 100644
--- a/sc/source/filter/excel/xiescher.cxx
+++ b/sc/source/filter/excel/xiescher.cxx
@@ -106,9 +106,8 @@
#include "scextopt.hxx"
#include "namebuff.hxx"
-#include <boost/scoped_ptr.hpp>
-#include <boost/shared_ptr.hpp>
#include <sfx2/docfile.hxx>
+#include <memory>
using namespace com::sun::star;
using ::com::sun::star::uno::makeAny;
@@ -1461,7 +1460,7 @@ void XclImpTextObj::DoPreProcessSdrObj( XclImpDffConverter& rDffConv, SdrObject&
if( maTextData.mxString->IsRich() )
{
// rich text
- boost::scoped_ptr< EditTextObject > xEditObj(
+ std::unique_ptr< EditTextObject > xEditObj(
XclImpStringHelper::CreateTextObject( GetRoot(), *maTextData.mxString ) );
OutlinerParaObject* pOutlineObj = new OutlinerParaObject( *xEditObj );
pOutlineObj->SetOutlinerMode( OUTLINERMODE_TEXTOBJECT );
@@ -4115,7 +4114,7 @@ void XclImpSheetDrawing::ReadNote( XclImpStream& rStrm )
void XclImpSheetDrawing::ReadTabChart( XclImpStream& rStrm )
{
OSL_ENSURE_BIFF( GetBiff() >= EXC_BIFF5 );
- boost::shared_ptr< XclImpChartObj > xChartObj( new XclImpChartObj( GetRoot(), true ) );
+ std::shared_ptr< XclImpChartObj > xChartObj( new XclImpChartObj( GetRoot(), true ) );
xChartObj->ReadChartSubStream( rStrm );
// insert the chart as raw object without connected DFF data
AppendRawObject( xChartObj );
diff --git a/sc/source/filter/excel/xilink.cxx b/sc/source/filter/excel/xilink.cxx
index 1232b97de518..0f84a562da39 100644
--- a/sc/source/filter/excel/xilink.cxx
+++ b/sc/source/filter/excel/xilink.cxx
@@ -75,7 +75,7 @@ public:
void LoadCachedValues(ScExternalRefCache::TableTypeRef pCacheTable);
private:
- typedef boost::shared_ptr< XclImpCrn > XclImpCrnRef;
+ typedef std::shared_ptr< XclImpCrn > XclImpCrnRef;
typedef std::vector< XclImpCrnRef > XclImpCrnList;
XclImpCrnList maCrnList; /// List of CRN records (cached cell values).
diff --git a/sc/source/filter/excel/xiname.cxx b/sc/source/filter/excel/xiname.cxx
index bb93e8865904..c5340bc8092f 100644
--- a/sc/source/filter/excel/xiname.cxx
+++ b/sc/source/filter/excel/xiname.cxx
@@ -40,7 +40,7 @@ XclImpName::XclImpName( XclImpStream& rStrm, sal_uInt16 nXclNameIdx ) :
mnNameIndex( nXclNameIdx ),
mbVBName( false ),
mbMacro( false ),
- mpTokensData( NULL )
+ mpTokensData( nullptr )
{
ExcelToSc& rFmlaConv = GetOldFmlaConverter();
@@ -218,7 +218,7 @@ void XclImpName::ConvertTokens()
ExcelToSc& rFmlaConv = GetOldFmlaConverter();
rFmlaConv.Reset();
- const ScTokenArray* pArray = NULL;
+ const ScTokenArray* pArray = nullptr;
XclImpStreamPos aOldPos;
XclImpStream& rStrm = mpTokensData->mrStrm;
@@ -242,7 +242,7 @@ void XclImpName::InsertName(const ScTokenArray* pArray)
if (mnXclTab == EXC_NAME_GLOBAL)
{
if (!GetDoc().GetRangeName()->insert(pData))
- pData = NULL;
+ pData = nullptr;
}
else
{
@@ -250,7 +250,7 @@ void XclImpName::InsertName(const ScTokenArray* pArray)
if (pLocalNames)
{
if (!pLocalNames->insert(pData))
- pData = NULL;
+ pData = nullptr;
}
if (GetBiff() == EXC_BIFF8 && pData)
@@ -299,7 +299,7 @@ const XclImpName* XclImpNameManager::FindName( const OUString& rXclName, SCTAB n
const XclImpName* XclImpNameManager::GetName( sal_uInt16 nXclNameIdx ) const
{
OSL_ENSURE( nXclNameIdx > 0, "XclImpNameManager::GetName - index must be >0" );
- return ( nXclNameIdx <= 0 || nXclNameIdx > maNameList.size() ) ? NULL : &(maNameList.at( nXclNameIdx - 1 ));
+ return ( nXclNameIdx <= 0 || nXclNameIdx > maNameList.size() ) ? nullptr : &(maNameList.at( nXclNameIdx - 1 ));
}
void XclImpNameManager::ConvertAllTokens()
diff --git a/sc/source/filter/excel/xlpivot.cxx b/sc/source/filter/excel/xlpivot.cxx
index 432ff5d3f7d3..cb2116af615e 100644
--- a/sc/source/filter/excel/xlpivot.cxx
+++ b/sc/source/filter/excel/xlpivot.cxx
@@ -89,7 +89,7 @@ void XclPCItem::SetError( sal_uInt16 nError )
mnError = nError;
switch( nError )
{
- case 0x00: maText = "#NULL!"; break;
+ case 0x00: maText = "#nullptr!"; break;
case 0x07: maText = "#DIV/0!"; break;
case 0x0F: maText = "#VALUE!"; break;
case 0x17: maText = "#REF!"; break;
@@ -132,7 +132,7 @@ bool XclPCItem::IsEmpty() const
const OUString* XclPCItem::GetText() const
{
- return (meType == EXC_PCITEM_TEXT || meType == EXC_PCITEM_ERROR) ? &maText : NULL;
+ return (meType == EXC_PCITEM_TEXT || meType == EXC_PCITEM_ERROR) ? &maText : nullptr;
}
const double* XclPCItem::GetDouble() const
@@ -567,7 +567,7 @@ XclPTFieldExtInfo::XclPTFieldExtInfo() :
mnSortField( EXC_SXVDEX_SORT_OWN ),
mnShowField( EXC_SXVDEX_SHOW_NONE ),
mnNumFmt(0),
- mpFieldTotalName(NULL)
+ mpFieldTotalName(nullptr)
{
}
diff --git a/sc/source/filter/html/htmlpars.cxx b/sc/source/filter/html/htmlpars.cxx
index 53067062f9d0..e5dfeae8ae79 100644
--- a/sc/source/filter/html/htmlpars.cxx
+++ b/sc/source/filter/html/htmlpars.cxx
@@ -19,9 +19,6 @@
#include <sal/config.h>
-#include <utility>
-
-#include <boost/shared_ptr.hpp>
#include <comphelper/string.hxx>
#include <o3tl/ptr_container.hxx>
@@ -68,7 +65,7 @@
#include <com/sun/star/document/XDocumentProperties.hpp>
#include <com/sun/star/document/XDocumentPropertiesSupplier.hpp>
-#include <memory>
+#include <utility>
using ::editeng::SvxBorderLine;
using namespace ::com::sun::star;
@@ -491,7 +488,7 @@ void ScHTMLLayoutParser::Adjust()
{
xLockedList->RemoveAll();
- ::std::stack< ScHTMLAdjustStackEntry* > aStack;
+ std::stack< ScHTMLAdjustStackEntry* > aStack;
ScHTMLAdjustStackEntry* pS = NULL;
sal_uInt16 nTab = 0;
SCCOL nLastCol = SCCOL_MAX;
@@ -642,7 +639,7 @@ sal_uInt16 ScHTMLLayoutParser::GetWidth( ScEEParseEntry* pE )
{
if ( pE->nWidth )
return pE->nWidth;
- sal_Int32 nTmp = ::std::min( static_cast<sal_Int32>( pE->nCol -
+ sal_Int32 nTmp = std::min( static_cast<sal_Int32>( pE->nCol -
nColCntStart + pE->nColOverlap),
static_cast<sal_Int32>( pLocalColOffset->size() - 1));
SCCOL nPos = (nTmp < 0 ? 0 : static_cast<SCCOL>(nTmp));
@@ -1718,7 +1715,7 @@ void ScHTMLLayoutParser::ProcToken( ImportInfo* pInfo )
template< typename Type >
inline Type getLimitedValue( const Type& rValue, const Type& rMin, const Type& rMax )
-{ return ::std::max( ::std::min( rValue, rMax ), rMin ); }
+{ return std::max( std::min( rValue, rMax ), rMin ); }
ScHTMLEntry::ScHTMLEntry( const SfxItemSet& rItemSet, ScHTMLTableId nTableId ) :
ScEEParseEntry( rItemSet ),
@@ -1782,8 +1779,8 @@ void ScHTMLEntry::Strip( const EditEngine& rEditEngine )
class ScHTMLTableMap
{
private:
- typedef ::boost::shared_ptr< ScHTMLTable > ScHTMLTablePtr;
- typedef ::std::map< ScHTMLTableId, ScHTMLTablePtr > ScHTMLTableStdMap;
+ typedef std::shared_ptr< ScHTMLTable > ScHTMLTablePtr;
+ typedef std::map< ScHTMLTableId, ScHTMLTablePtr > ScHTMLTableStdMap;
public:
typedef ScHTMLTableStdMap::iterator iterator;
@@ -1940,7 +1937,7 @@ ScHTMLTable::ScHTMLTable( ScHTMLTable& rParentTable, const ImportInfo& rInfo, bo
ScHTMLTable::ScHTMLTable(
SfxItemPool& rPool,
EditEngine& rEditEngine,
- ::std::vector< ScEEParseEntry* >& rEEParseList,
+ std::vector< ScEEParseEntry* >& rEEParseList,
ScHTMLTableId& rnUnusedId, ScHTMLParser* pParser
) :
mpParentTable( 0 ),
@@ -2140,7 +2137,7 @@ void ScHTMLTable::DataOn( const ImportInfo& rInfo )
{
// read needed options from the <td> tag
ScHTMLSize aSpanSize( 1, 1 );
- ::std::unique_ptr<OUString> pValStr, pNumStr;
+ std::unique_ptr<OUString> pValStr, pNumStr;
const HTMLOptions& rOptions = static_cast<HTMLParser*>(rInfo.pParser)->GetOptions();
HTMLOptions::const_iterator itr = rOptions.begin(), itrEnd = rOptions.end();
sal_uInt32 nNumberFormat = NUMBERFORMAT_ENTRY_NOT_FOUND;
@@ -2263,8 +2260,8 @@ SCCOLROW ScHTMLTable::GetDocSize( ScHTMLOrient eOrient, SCCOLROW nCellPos ) cons
SCCOLROW ScHTMLTable::GetDocSize( ScHTMLOrient eOrient, SCCOLROW nCellBegin, SCCOLROW nCellEnd ) const
{
const ScSizeVec& rSizes = maCumSizes[ eOrient ];
- size_t nBeginIdx = static_cast< size_t >( ::std::max< SCCOLROW >( nCellBegin, 0 ) );
- size_t nEndIdx = static_cast< size_t >( ::std::min< SCCOLROW >( nCellEnd, static_cast< SCCOLROW >( rSizes.size() ) ) );
+ size_t nBeginIdx = static_cast< size_t >( std::max< SCCOLROW >( nCellBegin, 0 ) );
+ size_t nEndIdx = static_cast< size_t >( std::min< SCCOLROW >( nCellEnd, static_cast< SCCOLROW >( rSizes.size() ) ) );
if (nBeginIdx >= nEndIdx ) return 0;
return rSizes[ nEndIdx - 1 ] - ((nBeginIdx == 0) ? 0 : rSizes[ nBeginIdx - 1 ]);
}
@@ -2499,8 +2496,8 @@ void ScHTMLTable::InsertNewCell( const ScHTMLSize& rSpanSize )
}
// adjust table size
- maSize.mnCols = ::std::max< SCCOL >( maSize.mnCols, aNewRange.aEnd.Col() + 1 );
- maSize.mnRows = ::std::max< SCROW >( maSize.mnRows, aNewRange.aEnd.Row() + 1 );
+ maSize.mnCols = std::max< SCCOL >( maSize.mnCols, aNewRange.aEnd.Col() + 1 );
+ maSize.mnRows = std::max< SCROW >( maSize.mnRows, aNewRange.aEnd.Row() + 1 );
}
void ScHTMLTable::ImplRowOn()
@@ -2632,7 +2629,7 @@ void ScHTMLTable::CalcNeededDocSize(
++nCellPos;
}
// set remaining needed size to last column/row
- nRealDocSize -= ::std::min< SCCOLROW >( nRealDocSize - 1, nDiffSize );
+ nRealDocSize -= std::min< SCCOLROW >( nRealDocSize - 1, nDiffSize );
SetDocSize( eOrient, nCellPos, nRealDocSize );
}
@@ -2710,7 +2707,7 @@ void ScHTMLTable::RecalcDocSize()
ScHTMLTable* pTable = GetExistingTable( (*aListIter)->GetTableId() );
// find entry with maximum width
if( bProcessColWidth && pTable )
- aDocSize.mnCols = ::std::max( aDocSize.mnCols, static_cast< SCCOL >( pTable->GetDocSize( tdCol ) ) );
+ aDocSize.mnCols = std::max( aDocSize.mnCols, static_cast< SCCOL >( pTable->GetDocSize( tdCol ) ) );
// add up height of each entry
if( bProcessRowHeight )
aDocSize.mnRows += pTable ? pTable->GetDocSize( tdRow ) : 1;
@@ -2811,7 +2808,7 @@ void ScHTMLTable::RecalcDocPos( const ScHTMLPos& rBasePos )
ScHTMLGlobalTable::ScHTMLGlobalTable(
SfxItemPool& rPool,
EditEngine& rEditEngine,
- ::std::vector< ScEEParseEntry* >& rEEParseList,
+ std::vector< ScEEParseEntry* >& rEEParseList,
ScHTMLTableId& rnUnusedId,
ScHTMLParser* pParser
) :
diff --git a/sc/source/filter/inc/autofilterbuffer.hxx b/sc/source/filter/inc/autofilterbuffer.hxx
index 1a3450feb9e7..a23cbda61789 100644
--- a/sc/source/filter/inc/autofilterbuffer.hxx
+++ b/sc/source/filter/inc/autofilterbuffer.hxx
@@ -176,7 +176,7 @@ public:
ApiFilterSettings finalizeImport( sal_Int32 nMaxCount );
private:
- ::boost::shared_ptr< FilterSettingsBase >
+ std::shared_ptr< FilterSettingsBase >
mxSettings;
sal_Int32 mnColId;
bool mbHiddenButton;
diff --git a/sc/source/filter/inc/biffcodec.hxx b/sc/source/filter/inc/biffcodec.hxx
index 475e2eaf48ce..f541ef9d7b8a 100644
--- a/sc/source/filter/inc/biffcodec.hxx
+++ b/sc/source/filter/inc/biffcodec.hxx
@@ -74,7 +74,7 @@ private:
bool mbValid; /// True = decoder is correctly initialized.
};
-typedef ::boost::shared_ptr< BiffDecoderBase > BiffDecoderRef;
+typedef std::shared_ptr< BiffDecoderBase > BiffDecoderRef;
/** Decodes BIFF stream contents that are encoded using the old XOR algorithm. */
class BiffDecoder_XOR : public BiffDecoderBase
diff --git a/sc/source/filter/inc/excelhandlers.hxx b/sc/source/filter/inc/excelhandlers.hxx
index 094dca7905ef..97980b500b52 100644
--- a/sc/source/filter/inc/excelhandlers.hxx
+++ b/sc/source/filter/inc/excelhandlers.hxx
@@ -142,8 +142,8 @@ protected:
bool skipFragment();
private:
- typedef ::boost::shared_ptr< BinaryXInputStream > XInputStreamRef;
- typedef ::boost::shared_ptr< BiffInputStream > BiffInputStreamRef;
+ typedef std::shared_ptr< BinaryXInputStream > XInputStreamRef;
+ typedef std::shared_ptr< BiffInputStream > BiffInputStreamRef;
XInputStreamRef mxXInStrm;
BiffInputStreamRef mxBiffStrm;
diff --git a/sc/source/filter/inc/formulabase.hxx b/sc/source/filter/inc/formulabase.hxx
index ec96e5898b47..39a051e93341 100644
--- a/sc/source/filter/inc/formulabase.hxx
+++ b/sc/source/filter/inc/formulabase.hxx
@@ -584,7 +584,7 @@ protected:
const FunctionInfoVector& getFuncs() const;
private:
- typedef ::boost::shared_ptr< FunctionProviderImpl > FunctionProviderImplRef;
+ typedef std::shared_ptr< FunctionProviderImpl > FunctionProviderImplRef;
FunctionProviderImplRef mxFuncImpl; /// Shared implementation between all copies of the provider.
};
@@ -616,7 +616,7 @@ public:
getOoxParserMap() const;
private:
- typedef ::boost::shared_ptr< OpCodeProviderImpl > OpCodeProviderImplRef;
+ typedef std::shared_ptr< OpCodeProviderImpl > OpCodeProviderImplRef;
OpCodeProviderImplRef mxOpCodeImpl; /// Shared implementation between all copies of the provider.
};
diff --git a/sc/source/filter/inc/ftools.hxx b/sc/source/filter/inc/ftools.hxx
index 09d7efe37e16..2a0194a75fa1 100644
--- a/sc/source/filter/inc/ftools.hxx
+++ b/sc/source/filter/inc/ftools.hxx
@@ -26,7 +26,6 @@
#include <sal/macros.h>
#include <sot/storage.hxx>
#include <boost/noncopyable.hpp>
-#include <boost/shared_ptr.hpp>
#include <oox/helper/helper.hxx>
#include "filter.hxx"
#include "scdllapi.h"
diff --git a/sc/source/filter/inc/htmlexp.hxx b/sc/source/filter/inc/htmlexp.hxx
index 65a4cec69103..ea56fb5d39d7 100644
--- a/sc/source/filter/inc/htmlexp.hxx
+++ b/sc/source/filter/inc/htmlexp.hxx
@@ -25,7 +25,7 @@
#include <tools/gen.hxx>
#include <tools/color.hxx>
#include <boost/ptr_container/ptr_vector.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include "expbase.hxx"
@@ -101,7 +101,7 @@ class ScHTMLExport : public ScExportBase
static const sal_uInt16 nCellSpacing;
static const sal_Char sIndentSource[];
- typedef boost::scoped_ptr<std::map<OUString, OUString> > FileNameMapPtr;
+ typedef std::unique_ptr<std::map<OUString, OUString> > FileNameMapPtr;
typedef boost::ptr_vector<ScHTMLGraphEntry> GraphEntryList;
GraphEntryList aGraphList;
diff --git a/sc/source/filter/inc/imp_op.hxx b/sc/source/filter/inc/imp_op.hxx
index 87fd1446ecf6..090189df385a 100644
--- a/sc/source/filter/inc/imp_op.hxx
+++ b/sc/source/filter/inc/imp_op.hxx
@@ -32,8 +32,8 @@
#include "excdefs.hxx"
#include <rtl/ref.hxx>
-#include <boost/shared_ptr.hpp>
#include <boost/ptr_container/ptr_vector.hpp>
+#include <memory>
#include <unordered_map>
class SvStream;
@@ -68,8 +68,8 @@ public:
void Convert();
private:
- typedef boost::shared_ptr< XclImpOutlineBuffer > XclImpOutlineBfrRef;
- typedef boost::shared_ptr< XclImpColRowSettings > XclImpColRowSettRef;
+ typedef std::shared_ptr< XclImpOutlineBuffer > XclImpOutlineBfrRef;
+ typedef std::shared_ptr< XclImpColRowSettings > XclImpColRowSettRef;
XclImpOutlineBfrRef mxColOutlineBuff;
XclImpOutlineBfrRef mxRowOutlineBuff;
diff --git a/sc/source/filter/inc/ooxformulaparser.hxx b/sc/source/filter/inc/ooxformulaparser.hxx
index 0432abd2c166..c70e277a22cf 100644
--- a/sc/source/filter/inc/ooxformulaparser.hxx
+++ b/sc/source/filter/inc/ooxformulaparser.hxx
@@ -20,7 +20,7 @@
#ifndef INCLUDED_SC_SOURCE_FILTER_INC_OOXFORMULAPARSER_HXX
#define INCLUDED_SC_SOURCE_FILTER_INC_OOXFORMULAPARSER_HXX
-#include <boost/shared_ptr.hpp>
+#include <memory>
#include <com/sun/star/lang/XComponent.hpp>
#include <com/sun/star/uno/XComponentContext.hpp>
#include <com/sun/star/lang/XInitialization.hpp>
@@ -84,7 +84,7 @@ public:
throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
private:
- typedef ::boost::shared_ptr< OOXMLFormulaParserImpl > ParserImplRef;
+ typedef std::shared_ptr< OOXMLFormulaParserImpl > ParserImplRef;
::com::sun::star::uno::Reference< ::com::sun::star::lang::XComponent >
mxComponent;
diff --git a/sc/source/filter/inc/workbookhelper.hxx b/sc/source/filter/inc/workbookhelper.hxx
index f4a82eaf818d..9609b2428608 100644
--- a/sc/source/filter/inc/workbookhelper.hxx
+++ b/sc/source/filter/inc/workbookhelper.hxx
@@ -20,7 +20,7 @@
#ifndef INCLUDED_SC_SOURCE_FILTER_INC_WORKBOOKHELPER_HXX
#define INCLUDED_SC_SOURCE_FILTER_INC_WORKBOOKHELPER_HXX
-#include <boost/shared_ptr.hpp>
+#include <memory>
#include <rtl/ref.hxx>
#include <oox/helper/storagebase.hxx>
#include <oox/drawingml/chart/chartconverter.hxx>
@@ -103,7 +103,7 @@ class WorksheetBuffer;
class FormulaBuffer;
class WorkbookGlobals;
-typedef ::boost::shared_ptr< WorkbookGlobals > WorkbookGlobalsRef;
+typedef std::shared_ptr< WorkbookGlobals > WorkbookGlobalsRef;
/** Helper class to provice access to global workbook data.
diff --git a/sc/source/filter/inc/worksheethelper.hxx b/sc/source/filter/inc/worksheethelper.hxx
index 0d614377aaa1..41d86dedd3bc 100644
--- a/sc/source/filter/inc/worksheethelper.hxx
+++ b/sc/source/filter/inc/worksheethelper.hxx
@@ -164,7 +164,7 @@ struct ValidationModel
};
class WorksheetGlobals;
-typedef ::boost::shared_ptr< WorksheetGlobals > WorksheetGlobalsRef;
+typedef std::shared_ptr< WorksheetGlobals > WorksheetGlobalsRef;
class IWorksheetProgress {
public:
diff --git a/sc/source/filter/inc/xecontent.hxx b/sc/source/filter/inc/xecontent.hxx
index 3fdf8dd839a1..5567dc1119ff 100644
--- a/sc/source/filter/inc/xecontent.hxx
+++ b/sc/source/filter/inc/xecontent.hxx
@@ -64,7 +64,7 @@ public:
virtual void SaveXml( XclExpXmlStream& rStrm ) SAL_OVERRIDE;
private:
- typedef boost::scoped_ptr< XclExpSstImpl > XclExpSstImplPtr;
+ typedef std::unique_ptr< XclExpSstImpl > XclExpSstImplPtr;
XclExpSstImplPtr mxImpl;
};
@@ -123,7 +123,7 @@ private:
virtual void WriteBody( XclExpStream& rStrm ) SAL_OVERRIDE;
private:
- typedef boost::scoped_ptr< SvStream > SvStreamPtr;
+ typedef std::unique_ptr< SvStream > SvStreamPtr;
ScAddress maScPos; /// Position of the hyperlink.
OUString m_Repr; /// Cell representation text.
@@ -180,7 +180,7 @@ private:
virtual void WriteBody( XclExpStream& rStrm ) SAL_OVERRIDE;
private:
- typedef boost::scoped_ptr< XclExpCFImpl > XclExpCFImplPtr;
+ typedef std::unique_ptr< XclExpCFImpl > XclExpCFImplPtr;
XclExpCFImplPtr mxImpl;
};
@@ -272,9 +272,9 @@ public:
virtual void SaveXml( XclExpXmlStream& rStrm ) SAL_OVERRIDE;
private:
- boost::scoped_ptr<XclExpCfvo> mpCfvoLowerLimit;
- boost::scoped_ptr<XclExpCfvo> mpCfvoUpperLimit;
- boost::scoped_ptr<XclExpColScaleCol> mpCol;
+ std::unique_ptr<XclExpCfvo> mpCfvoLowerLimit;
+ std::unique_ptr<XclExpCfvo> mpCfvoUpperLimit;
+ std::unique_ptr<XclExpColScaleCol> mpCol;
const ScDataBarFormat& mrFormat;
sal_Int32 mnPriority;
diff --git a/sc/source/filter/inc/xeformula.hxx b/sc/source/filter/inc/xeformula.hxx
index e04f2dfaa5b4..f42d2b4c6397 100644
--- a/sc/source/filter/inc/xeformula.hxx
+++ b/sc/source/filter/inc/xeformula.hxx
@@ -22,7 +22,7 @@
#include "xlformula.hxx"
#include "xeroot.hxx"
-#include <boost/shared_ptr.hpp>
+#include <memory>
// External reference log =====================================================
@@ -83,7 +83,7 @@ public:
bool IsRef2D( const ScComplexRefData& rRefData ) const;
private:
- typedef boost::shared_ptr< XclExpFmlaCompImpl > XclExpFmlaCompImplRef;
+ typedef std::shared_ptr< XclExpFmlaCompImpl > XclExpFmlaCompImplRef;
XclExpFmlaCompImplRef mxImpl;
};
diff --git a/sc/source/filter/inc/xelink.hxx b/sc/source/filter/inc/xelink.hxx
index 9209b7e9a977..fd3a8374d2d7 100644
--- a/sc/source/filter/inc/xelink.hxx
+++ b/sc/source/filter/inc/xelink.hxx
@@ -26,7 +26,7 @@
#include "xehelper.hxx"
#include "xeformula.hxx"
#include "externalrefmgr.hxx"
-#include <boost/shared_ptr.hpp>
+#include <memory>
struct ScSingleRefData;
struct ScComplexRefData;
@@ -204,7 +204,7 @@ public:
virtual void SaveXml( XclExpXmlStream& rStrm ) SAL_OVERRIDE;
private:
- typedef boost::shared_ptr< XclExpLinkManagerImpl > XclExpLinkMgrImplPtr;
+ typedef std::shared_ptr< XclExpLinkManagerImpl > XclExpLinkMgrImplPtr;
XclExpLinkMgrImplPtr mxImpl;
};
diff --git a/sc/source/filter/inc/xename.hxx b/sc/source/filter/inc/xename.hxx
index 9d2844ae1c04..48188dbfc6e7 100644
--- a/sc/source/filter/inc/xename.hxx
+++ b/sc/source/filter/inc/xename.hxx
@@ -24,7 +24,7 @@
#include "xlname.hxx"
#include "xlformula.hxx"
#include "xeroot.hxx"
-#include <boost/shared_ptr.hpp>
+#include <memory>
class ScRangeList;
class XclExpNameManagerImpl;
@@ -68,7 +68,7 @@ public:
virtual void SaveXml( XclExpXmlStream& rStrm ) SAL_OVERRIDE;
private:
- typedef boost::shared_ptr< XclExpNameManagerImpl > XclExpNameMgrImplRef;
+ typedef std::shared_ptr< XclExpNameManagerImpl > XclExpNameMgrImplRef;
XclExpNameMgrImplRef mxImpl;
};
diff --git a/sc/source/filter/inc/xestream.hxx b/sc/source/filter/inc/xestream.hxx
index 56dc6ec4808b..a4177dc70df1 100644
--- a/sc/source/filter/inc/xestream.hxx
+++ b/sc/source/filter/inc/xestream.hxx
@@ -45,7 +45,7 @@ Output stream class for Excel export
class XclExpRoot;
class XclExpBiff8Encrypter;
-typedef boost::shared_ptr< XclExpBiff8Encrypter > XclExpEncrypterRef;
+typedef std::shared_ptr< XclExpBiff8Encrypter > XclExpEncrypterRef;
/** This class is used to export Excel record streams.
@descr An instance is constructed with an SvStream and the maximum size of Excel
diff --git a/sc/source/filter/inc/xestyle.hxx b/sc/source/filter/inc/xestyle.hxx
index 9e2c2151faec..f08b71c61e61 100644
--- a/sc/source/filter/inc/xestyle.hxx
+++ b/sc/source/filter/inc/xestyle.hxx
@@ -30,8 +30,7 @@
#include "xeroot.hxx"
#include "conditio.hxx"
#include "fonthelper.hxx"
-#include <boost/shared_ptr.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include <boost/ptr_container/ptr_vector.hpp>
/* ============================================================================
@@ -119,7 +118,7 @@ private:
virtual void WriteBody( XclExpStream& rStrm ) SAL_OVERRIDE;
private:
- typedef boost::shared_ptr< XclExpPaletteImpl > XclExpPaletteImplRef;
+ typedef std::shared_ptr< XclExpPaletteImpl > XclExpPaletteImplRef;
XclExpPaletteImplRef mxImpl;
};
@@ -314,7 +313,7 @@ private:
SvNumberFormatterPtr mxFormatter; /// Special number formatter for conversion.
XclExpNumFmtVec maFormatMap; /// Maps core formats to Excel indexes.
- boost::scoped_ptr<NfKeywordTable> mpKeywordTable; /// Replacement table.
+ std::unique_ptr<NfKeywordTable> mpKeywordTable; /// Replacement table.
sal_uLong mnStdFmt; /// Key for standard number format.
sal_uInt16 mnXclOffset; /// Offset to first user defined format.
};
@@ -718,12 +717,12 @@ public:
virtual void SaveXml( XclExpXmlStream& rStrm ) SAL_OVERRIDE;
private:
- boost::scoped_ptr<XclExpCellAlign> mpAlign;
- boost::scoped_ptr<XclExpCellBorder> mpBorder;
- boost::scoped_ptr<XclExpDxfFont> mpFont;
- boost::scoped_ptr<XclExpNumFmt> mpNumberFmt;
- boost::scoped_ptr<XclExpCellProt> mpProt;
- boost::scoped_ptr<XclExpColor> mpColor;
+ std::unique_ptr<XclExpCellAlign> mpAlign;
+ std::unique_ptr<XclExpCellBorder> mpBorder;
+ std::unique_ptr<XclExpDxfFont> mpFont;
+ std::unique_ptr<XclExpNumFmt> mpNumberFmt;
+ std::unique_ptr<XclExpCellProt> mpProt;
+ std::unique_ptr<XclExpColor> mpColor;
};
class XclExpDxfs : public XclExpRecordBase, protected XclExpRoot
@@ -740,7 +739,7 @@ private:
std::map<OUString, sal_Int32> maStyleNameToDxfId;
DxfContainer maDxf;
SvNumberFormatterPtr mxFormatter; /// Special number formatter for conversion.
- boost::scoped_ptr<NfKeywordTable> mpKeywordTable; /// Replacement table.
+ std::unique_ptr<NfKeywordTable> mpKeywordTable; /// Replacement table.
};
class XclExpXmlStyleSheet : public XclExpRecordBase, protected XclExpRoot
diff --git a/sc/source/filter/inc/xichart.hxx b/sc/source/filter/inc/xichart.hxx
index cc1522fb939d..9d1dfff38453 100644
--- a/sc/source/filter/inc/xichart.hxx
+++ b/sc/source/filter/inc/xichart.hxx
@@ -20,10 +20,11 @@
#ifndef INCLUDED_SC_SOURCE_FILTER_INC_XICHART_HXX
#define INCLUDED_SC_SOURCE_FILTER_INC_XICHART_HXX
-#include <vector>
-#include <map>
#include <set>
#include <list>
+#include <map>
+#include <memory>
+#include <vector>
#include <svl/itemset.hxx>
@@ -33,7 +34,6 @@
#include "xlstyle.hxx"
#include "xiescher.hxx"
#include "xistring.hxx"
-#include <boost/shared_ptr.hpp>
#include <boost/ptr_container/ptr_map.hpp>
namespace com { namespace sun { namespace star {
@@ -166,7 +166,7 @@ public:
sal_uInt16 nAngle );
private:
- typedef boost::shared_ptr< XclImpChRootData > XclImpChRootDataRef;
+ typedef std::shared_ptr< XclImpChRootData > XclImpChRootDataRef;
XclImpChRootDataRef mxChData; /// Reference to the root data object.
};
@@ -211,7 +211,7 @@ private:
XclChFramePos maData; /// Position of the frame.
};
-typedef boost::shared_ptr< XclImpChFramePos > XclImpChFramePosRef;
+typedef std::shared_ptr< XclImpChFramePos > XclImpChFramePosRef;
/** The CHLINEFORMAT record containing line formatting data. */
class XclImpChLineFormat
@@ -243,7 +243,7 @@ private:
XclChLineFormat maData; /// Contents of the CHLINEFORMAT record.
};
-typedef boost::shared_ptr< XclImpChLineFormat > XclImpChLineFormatRef;
+typedef std::shared_ptr< XclImpChLineFormat > XclImpChLineFormatRef;
/** The CHAREAFORMAT record containing simple area formatting data (solid or patterns). */
class XclImpChAreaFormat
@@ -271,7 +271,7 @@ private:
XclChAreaFormat maData; /// Contents of the CHAREAFORMAT record.
};
-typedef boost::shared_ptr< XclImpChAreaFormat > XclImpChAreaFormatRef;
+typedef std::shared_ptr< XclImpChAreaFormat > XclImpChAreaFormatRef;
/** The CHESCHERFORMAT record containing complex area formatting data (bitmaps, hatches). */
class XclImpChEscherFormat : public XclImpChGroupBase
@@ -294,7 +294,7 @@ private:
sal_uInt32 mnDffFillType; /// Fill type imported from the DFF property set.
};
-typedef boost::shared_ptr< XclImpChEscherFormat > XclImpChEscherFormatRef;
+typedef std::shared_ptr< XclImpChEscherFormat > XclImpChEscherFormatRef;
/** Base class for record groups containing frame formatting.
@@ -370,7 +370,7 @@ private:
XclChObjectType meObjType; /// Type of the represented object.
};
-typedef boost::shared_ptr< XclImpChFrame > XclImpChFrameRef;
+typedef std::shared_ptr< XclImpChFrame > XclImpChFrameRef;
// Source links ===============================================================
@@ -415,10 +415,10 @@ public:
private:
XclChSourceLink maData; /// Contents of the CHSOURCELINK record.
XclImpStringRef mxString; /// Text data (CHSTRING record).
- boost::shared_ptr< ScTokenArray> mxTokenArray; /// Token array representing the data ranges.
+ std::shared_ptr< ScTokenArray> mxTokenArray; /// Token array representing the data ranges.
};
-typedef boost::shared_ptr< XclImpChSourceLink > XclImpChSourceLinkRef;
+typedef std::shared_ptr< XclImpChSourceLink > XclImpChSourceLinkRef;
// Text =======================================================================
@@ -456,7 +456,7 @@ private:
sal_uInt16 mnFontIdx; /// Index into font buffer.
};
-typedef boost::shared_ptr< XclImpChFont > XclImpChFontRef;
+typedef std::shared_ptr< XclImpChFont > XclImpChFontRef;
/** Represents the CHTEXT record group containing text object properties.
@@ -519,7 +519,7 @@ private:
void ReadChFrLabelProps( XclImpStream& rStrm );
private:
- typedef boost::shared_ptr< XclChFrLabelProps > XclChFrLabelPropsRef;
+ typedef std::shared_ptr< XclChFrLabelProps > XclChFrLabelPropsRef;
XclChText maData; /// Contents of the CHTEXT record.
XclChObjectLink maObjLink; /// Link target for this text object.
@@ -531,7 +531,7 @@ private:
XclChFrLabelPropsRef mxLabelProps; /// Extended data label properties (CHFRLABELPROPS record).
};
-typedef boost::shared_ptr< XclImpChText > XclImpChTextRef;
+typedef std::shared_ptr< XclImpChText > XclImpChTextRef;
// Data series ================================================================
@@ -556,7 +556,7 @@ private:
XclChMarkerFormat maData; /// Contents of the CHMARKERFORMAT record.
};
-typedef boost::shared_ptr< XclImpChMarkerFormat > XclImpChMarkerFormatRef;
+typedef std::shared_ptr< XclImpChMarkerFormat > XclImpChMarkerFormatRef;
/** The CHPIEFORMAT record containing data point formatting data for pie segments. */
class XclImpChPieFormat
@@ -572,7 +572,7 @@ private:
sal_uInt16 mnPieDist; /// Pie distance to diagram center.
};
-typedef boost::shared_ptr< XclImpChPieFormat > XclImpChPieFormatRef;
+typedef std::shared_ptr< XclImpChPieFormat > XclImpChPieFormatRef;
/** The CHSERIESFORMAT record containing additional settings for a data series. */
class XclImpChSeriesFormat
@@ -588,7 +588,7 @@ private:
sal_uInt16 mnFlags; /// Additional flags.
};
-typedef boost::shared_ptr< XclImpChSeriesFormat > XclImpChSeriesFormatRef;
+typedef std::shared_ptr< XclImpChSeriesFormat > XclImpChSeriesFormatRef;
/** The CH3DDATAFORMAT record containing the bar type in 3D bar charts. */
class XclImpCh3dDataFormat
@@ -603,7 +603,7 @@ private:
XclCh3dDataFormat maData; /// Contents of the CH3DDATAFORMAT record.
};
-typedef boost::shared_ptr< XclImpCh3dDataFormat > XclImpCh3dDataFormatRef;
+typedef std::shared_ptr< XclImpCh3dDataFormat > XclImpCh3dDataFormatRef;
/** The CHATTACHEDLABEL record that contains the type of a data point label. */
class XclImpChAttachedLabel : protected XclImpChRoot
@@ -619,7 +619,7 @@ private:
sal_uInt16 mnFlags; /// Additional flags.
};
-typedef boost::shared_ptr< XclImpChAttachedLabel > XclImpChAttLabelRef;
+typedef std::shared_ptr< XclImpChAttachedLabel > XclImpChAttLabelRef;
/** Represents the CHDATAFORMAT record group containing data point properties.
@@ -685,7 +685,7 @@ private:
XclImpChTextRef mxLabel; /// Data point label formatting (CHTEXT group).
};
-typedef boost::shared_ptr< XclImpChDataFormat > XclImpChDataFormatRef;
+typedef std::shared_ptr< XclImpChDataFormat > XclImpChDataFormatRef;
/** Represents the CHSERTRENDLINE record containing settings for a trend line. */
class XclImpChSerTrendLine : protected XclImpChRoot
@@ -710,7 +710,7 @@ private:
XclImpChDataFormatRef mxDataFmt; /// Formatting settings of the trend line.
};
-typedef boost::shared_ptr< XclImpChSerTrendLine > XclImpChSerTrendLineRef;
+typedef std::shared_ptr< XclImpChSerTrendLine > XclImpChSerTrendLineRef;
/** Represents the CHSERERRORBAR record containing settings for error bars. */
class XclImpChSerErrorBar : protected XclImpChRoot
@@ -743,7 +743,7 @@ private:
XclImpChDataFormatRef mxDataFmt; /// Formatting settings of the error bars.
};
-typedef boost::shared_ptr< XclImpChSerErrorBar > XclImpChSerErrorBarRef;
+typedef std::shared_ptr< XclImpChSerErrorBar > XclImpChSerErrorBarRef;
/** Represents the CHSERIES record group describing a data series in a chart.
@@ -838,7 +838,7 @@ private:
sal_uInt16 mnParentIdx; /// 0-based index of parent series (trend lines and error bars).
};
-typedef boost::shared_ptr< XclImpChSeries > XclImpChSeriesRef;
+typedef std::shared_ptr< XclImpChSeries > XclImpChSeriesRef;
// Chart type groups ==========================================================
@@ -891,7 +891,7 @@ private:
XclChChart3d maData; /// Contents of the CHCHART3D record.
};
-typedef boost::shared_ptr< XclImpChChart3d > XclImpChChart3dRef;
+typedef std::shared_ptr< XclImpChChart3d > XclImpChChart3dRef;
/** Represents the CHLEGEND record group describing the chart legend.
@@ -921,7 +921,7 @@ private:
XclImpChFrameRef mxFrame; /// Legend frame format (CHFRAME group).
};
-typedef boost::shared_ptr< XclImpChLegend > XclImpChLegendRef;
+typedef std::shared_ptr< XclImpChLegend > XclImpChLegendRef;
/** Represents the CHDROPBAR record group describing pos/neg bars in line charts.
@@ -944,7 +944,7 @@ private:
sal_uInt16 mnBarDist; /// Distance between bars (CHDROPBAR record).
};
-typedef boost::shared_ptr< XclImpChDropBar > XclImpChDropBarRef;
+typedef std::shared_ptr< XclImpChDropBar > XclImpChDropBarRef;
/** Represents the CHTYPEGROUP record group describing a group of series.
@@ -1056,7 +1056,7 @@ private:
UInt16Set maUnusedFormats; /// Contains unused format indexes for automatic colors.
};
-typedef boost::shared_ptr< XclImpChTypeGroup > XclImpChTypeGroupRef;
+typedef std::shared_ptr< XclImpChTypeGroup > XclImpChTypeGroupRef;
// Axes =======================================================================
@@ -1078,7 +1078,7 @@ private:
XclChDateRange maDateData; /// Contents of the CHDATERANGE record.
};
-typedef boost::shared_ptr< XclImpChLabelRange > XclImpChLabelRangeRef;
+typedef std::shared_ptr< XclImpChLabelRange > XclImpChLabelRangeRef;
class XclImpChValueRange : protected XclImpChRoot
{
@@ -1095,7 +1095,7 @@ private:
XclChValueRange maData; /// Contents of the CHVALUERANGE record.
};
-typedef boost::shared_ptr< XclImpChValueRange > XclImpChValueRangeRef;
+typedef std::shared_ptr< XclImpChValueRange > XclImpChValueRangeRef;
class XclImpChTick : protected XclImpChRoot
{
@@ -1118,7 +1118,7 @@ private:
XclChTick maData; /// Contents of the CHTICK record.
};
-typedef boost::shared_ptr< XclImpChTick > XclImpChTickRef;
+typedef std::shared_ptr< XclImpChTick > XclImpChTickRef;
/** Represents the CHAXIS record group describing an entire chart axis.
@@ -1185,7 +1185,7 @@ private:
sal_uInt16 mnNumFmtIdx; /// Index into number format buffer (CHFORMAT record).
};
-typedef boost::shared_ptr< XclImpChAxis > XclImpChAxisRef;
+typedef std::shared_ptr< XclImpChAxis > XclImpChAxisRef;
/** Represents the CHAXESSET record group describing an axes set (X/Y/Z axes).
@@ -1266,7 +1266,7 @@ private:
XclImpChTypeGroupMap maTypeGroups; /// Chart type groups (CHTYPEGROUP group).
};
-typedef boost::shared_ptr< XclImpChAxesSet > XclImpChAxesSetRef;
+typedef std::shared_ptr< XclImpChAxesSet > XclImpChAxesSetRef;
// The chart object ===========================================================
@@ -1351,7 +1351,7 @@ private:
XclImpChLegendRef mxLegend; /// Chart legend (CHLEGEND group).
};
-typedef boost::shared_ptr< XclImpChChart > XclImpChChartRef;
+typedef std::shared_ptr< XclImpChChart > XclImpChChartRef;
/** Drawing container of a chart. */
class XclImpChartDrawing : public XclImpDrawing
@@ -1409,7 +1409,7 @@ private:
void ReadChChart( XclImpStream& rStrm );
private:
- typedef boost::shared_ptr< XclImpChartDrawing > XclImpChartDrawingRef;
+ typedef std::shared_ptr< XclImpChartDrawing > XclImpChartDrawingRef;
XclImpChChartRef mxChartData; /// The chart data (CHCHART group).
XclImpChartDrawingRef mxChartDrawing; /// Drawing container for embedded shapes.
diff --git a/sc/source/filter/inc/xiescher.hxx b/sc/source/filter/inc/xiescher.hxx
index e123a14031c2..df48ba8e4dac 100644
--- a/sc/source/filter/inc/xiescher.hxx
+++ b/sc/source/filter/inc/xiescher.hxx
@@ -20,17 +20,16 @@
#ifndef INCLUDED_SC_SOURCE_FILTER_INC_XIESCHER_HXX
#define INCLUDED_SC_SOURCE_FILTER_INC_XIESCHER_HXX
-#include <vector>
-#include <map>
#include <filter/msfilter/msdffimp.hxx>
#include <vcl/graph.hxx>
#include "xlescher.hxx"
#include "xiroot.hxx"
#include "xistring.hxx"
-#include <boost/shared_ptr.hpp>
-#include <boost/scoped_ptr.hpp>
#include <oox/ole/olehelper.hxx>
#include <rtl/ustring.hxx>
+#include <map>
+#include <memory>
+#include <vector>
namespace com { namespace sun { namespace star {
namespace drawing { class XShape; }
@@ -48,7 +47,7 @@ class XclImpDrawing;
// Drawing objects ============================================================
class XclImpDrawObjBase;
-typedef boost::shared_ptr< XclImpDrawObjBase > XclImpDrawObjRef;
+typedef std::shared_ptr< XclImpDrawObjBase > XclImpDrawObjRef;
/** Base class for drawing objects (OBJ records). */
class XclImpDrawObjBase : protected XclImpRoot
@@ -206,13 +205,13 @@ private:
class XclImpDrawObjVector
{
private:
- ::std::vector< XclImpDrawObjRef > mObjs;
+ std::vector< XclImpDrawObjRef > mObjs;
public:
inline explicit XclImpDrawObjVector() : mObjs() {}
- ::std::vector< XclImpDrawObjRef >::const_iterator begin() const { return mObjs.begin(); }
- ::std::vector< XclImpDrawObjRef >::const_iterator end() const { return mObjs.end(); }
+ std::vector< XclImpDrawObjRef >::const_iterator begin() const { return mObjs.begin(); }
+ std::vector< XclImpDrawObjRef >::const_iterator end() const { return mObjs.end(); }
void push_back(const XclImpDrawObjRef& rObj) { mObjs.push_back(rObj); }
/** Tries to insert the passed object into the last group or appends it. */
@@ -356,7 +355,7 @@ protected:
virtual SdrObject* DoCreateSdrObj( XclImpDffConverter& rDffConv, const Rectangle& rAnchorRect ) const SAL_OVERRIDE;
protected:
- typedef ::std::vector< Point > PointVector;
+ typedef std::vector< Point > PointVector;
PointVector maCoords; /// Coordinates relative to bounding rectangle.
sal_uInt16 mnPolyFlags; /// Additional flags.
sal_uInt16 mnPointCount; /// Polygon point count.
@@ -429,7 +428,7 @@ private:
void FinalizeTabChart();
private:
- typedef boost::shared_ptr< XclImpChart > XclImpChartRef;
+ typedef std::shared_ptr< XclImpChart > XclImpChartRef;
XclImpChartRef mxChart; /// The chart itself (BOF/EOF substream data).
bool mbOwnTab; /// true = own sheet; false = embedded object.
@@ -483,7 +482,7 @@ protected:
void ApplySheetLinkProps() const;
mutable ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape >
mxShape; /// The UNO wrapper of the control shape.
- boost::shared_ptr< ScAddress > mxCellLink; /// Linked cell in the Calc document.
+ std::shared_ptr< ScAddress > mxCellLink; /// Linked cell in the Calc document.
private:
/** Reads a list of cell ranges from a formula at the current stream position. */
void ReadRangeList( ScRangeList& rScRanges, XclImpStream& rStrm );
@@ -492,7 +491,7 @@ private:
private:
const XclImpRoot& mrRoot; /// Not derived from XclImpRoot to allow multiple inheritance.
- boost::shared_ptr< ScRange > mxSrcRange; /// Source data range in the Calc document.
+ std::shared_ptr< ScRange > mxSrcRange; /// Source data range in the Calc document.
XclCtrlBindMode meBindMode; /// Value binding mode.
};
@@ -898,8 +897,8 @@ private:
inline void Set( SdrObject* pSdrObj, sal_uInt32 nDffFlags )
{ mpSdrObj = pSdrObj; mnDffFlags = nDffFlags; }
};
- typedef ::std::map< sal_uInt32, XclImpSdrInfo > XclImpSdrInfoMap;
- typedef ::std::map< SdrObject*, sal_uInt32 > XclImpSdrObjMap;
+ typedef std::map< sal_uInt32, XclImpSdrInfo > XclImpSdrInfoMap;
+ typedef std::map< SdrObject*, sal_uInt32 > XclImpSdrObjMap;
XclImpSdrInfoMap maSdrInfoMap; /// Maps shape IDs to SdrObjects and flags.
XclImpSdrObjMap maSdrObjMap; /// Maps SdrObjects to shape IDs.
@@ -1026,9 +1025,9 @@ private:
void InitControlForm();
private:
- typedef boost::shared_ptr< ScfProgressBar > ScfProgressBarRef;
- typedef boost::shared_ptr< XclImpDffConvData > XclImpDffConvDataRef;
- typedef ::std::vector< XclImpDffConvDataRef > XclImpDffConvDataStack;
+ typedef std::shared_ptr< ScfProgressBar > ScfProgressBarRef;
+ typedef std::shared_ptr< XclImpDffConvData > XclImpDffConvDataRef;
+ typedef std::vector< XclImpDffConvDataRef > XclImpDffConvDataStack;
const OUString maStdFormName; /// Standard name of control forms.
tools::SvRef<SotStorageStream> mxCtlsStrm; /// The 'Ctls' stream for OCX form controls.
@@ -1095,10 +1094,10 @@ private:
void ReadTxo( XclImpStream& rStrm );
private:
- typedef ::std::map< sal_Size, XclImpDrawObjRef > XclImpObjMap;
- typedef ::std::map< sal_uInt16, XclImpDrawObjRef > XclImpObjMapById;
- typedef boost::shared_ptr< XclImpObjTextData > XclImpObjTextRef;
- typedef ::std::map< sal_Size, XclImpObjTextRef > XclImpObjTextMap;
+ typedef std::map< sal_Size, XclImpDrawObjRef > XclImpObjMap;
+ typedef std::map< sal_uInt16, XclImpDrawObjRef > XclImpObjMapById;
+ typedef std::shared_ptr< XclImpObjTextData > XclImpObjTextRef;
+ typedef std::map< sal_Size, XclImpObjTextRef > XclImpObjTextMap;
XclImpDrawObjVector maRawObjs; /// BIFF5 objects without DFF data.
SvMemoryStream maDffStrm; /// Copy of the DFF page stream in memory.
@@ -1170,9 +1169,9 @@ public:
OUString GetOleNameOverride( SCTAB nTab, sal_uInt16 nObjId );
private:
- typedef ::std::map< sal_uInt16, OUString > DefObjNameMap;
- typedef boost::shared_ptr< XclImpSheetDrawing > XclImpSheetDrawingRef;
- typedef ::std::map< SCTAB, XclImpSheetDrawingRef > XclImpSheetDrawingMap;
+ typedef std::map< sal_uInt16, OUString > DefObjNameMap;
+ typedef std::shared_ptr< XclImpSheetDrawing > XclImpSheetDrawingRef;
+ typedef std::map< SCTAB, XclImpSheetDrawingRef > XclImpSheetDrawingMap;
com::sun::star::uno::Reference< com::sun::star::container::XNameContainer > mxOleCtrlNameOverride;
DefObjNameMap maDefObjNames; /// Default base names for all object types.
@@ -1203,7 +1202,7 @@ public:
void FillToItemSet( SfxItemSet& rItemSet ) const;
private:
- typedef ::boost::scoped_ptr<SvMemoryStream> SvMemoryStreamPtr;
+ typedef std::unique_ptr<SvMemoryStream> SvMemoryStreamPtr;
SvMemoryStream maDummyStrm; /// Dummy DGG stream for DFF manager.
XclImpSimpleDffConverter maDffConv; /// DFF converter used to resolve palette colors.
diff --git a/sc/source/filter/inc/xiformula.hxx b/sc/source/filter/inc/xiformula.hxx
index 4c8b70e2b3d1..56729e88336a 100644
--- a/sc/source/filter/inc/xiformula.hxx
+++ b/sc/source/filter/inc/xiformula.hxx
@@ -22,7 +22,7 @@
#include "xlformula.hxx"
#include "xiroot.hxx"
-#include <boost/shared_ptr.hpp>
+#include <memory>
// Formula compiler ===========================================================
@@ -51,7 +51,7 @@ public:
const ScTokenArray* CreateFormula( XclFormulaType eType, const XclTokenArray& rXclTokArr );
private:
- typedef boost::shared_ptr< XclImpFmlaCompImpl > XclImpFmlaCompImplRef;
+ typedef std::shared_ptr< XclImpFmlaCompImpl > XclImpFmlaCompImplRef;
XclImpFmlaCompImplRef mxImpl;
};
diff --git a/sc/source/filter/inc/xihelper.hxx b/sc/source/filter/inc/xihelper.hxx
index 3e54efe7dc0f..b8f12e8c2395 100644
--- a/sc/source/filter/inc/xihelper.hxx
+++ b/sc/source/filter/inc/xihelper.hxx
@@ -22,12 +22,12 @@
#include <editeng/editdata.hxx>
#include <boost/noncopyable.hpp>
-#include <boost/shared_ptr.hpp>
#include <boost/ptr_container/ptr_vector.hpp>
#include "types.hxx"
#include "xladdress.hxx"
#include "xiroot.hxx"
#include "xistring.hxx"
+#include <memory>
class ScRangeList;
@@ -185,7 +185,7 @@ private: // types
/** Contains all information about a header/footer portion. */
struct XclImpHFPortionInfo
{
- typedef boost::shared_ptr< EditTextObject > EditTextObjectRef;
+ typedef std::shared_ptr< EditTextObject > EditTextObjectRef;
EditTextObjectRef mxObj; /// Edit engine text object.
ESelection maSel; /// Edit engine selection.
sal_Int32 mnHeight; /// Height of previous lines in twips.
diff --git a/sc/source/filter/inc/xiname.hxx b/sc/source/filter/inc/xiname.hxx
index 75a5936b9b22..4cc53b581a71 100644
--- a/sc/source/filter/inc/xiname.hxx
+++ b/sc/source/filter/inc/xiname.hxx
@@ -28,7 +28,7 @@
#include "rangenam.hxx"
#include <boost/noncopyable.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
class ScRangeData;
class ScTokenArray;
@@ -72,7 +72,7 @@ private:
bool mbVBName:1; /// true = Visual Basic procedure or function.
bool mbMacro:1; /// Whether it's a user-defined macro.
- boost::scoped_ptr<TokenStrmData> mpTokensData; /// For later conversion of token array.
+ std::unique_ptr<TokenStrmData> mpTokensData; /// For later conversion of token array.
};
/** This buffer contains all internal defined names of the document.
diff --git a/sc/source/filter/inc/xiroot.hxx b/sc/source/filter/inc/xiroot.hxx
index 818c7b7714e4..099d885ebfeb 100644
--- a/sc/source/filter/inc/xiroot.hxx
+++ b/sc/source/filter/inc/xiroot.hxx
@@ -21,14 +21,14 @@
#define INCLUDED_SC_SOURCE_FILTER_INC_XIROOT_HXX
#include "xlroot.hxx"
-#include <boost/shared_ptr.hpp>
+#include <memory>
// Forward declarations of objects in public use ==============================
class XclImpStream;
class XclImpString;
-typedef boost::shared_ptr< XclImpString > XclImpStringRef;
+typedef std::shared_ptr< XclImpString > XclImpStringRef;
// Global data ================================================================
@@ -63,28 +63,28 @@ class ScDocumentImport;
/** Stores global buffers and data needed for Excel import filter. */
struct XclImpRootData : public XclRootData
{
- typedef boost::shared_ptr< XclImpAddressConverter > XclImpAddrConvRef;
- typedef boost::shared_ptr< XclImpFormulaCompiler > XclImpFmlaCompRef;
-
- typedef boost::shared_ptr< XclImpSst > XclImpSstRef;
- typedef boost::shared_ptr< XclImpPalette > XclImpPaletteRef;
- typedef boost::shared_ptr< XclImpFontBuffer > XclImpFontBfrRef;
- typedef boost::shared_ptr< XclImpNumFmtBuffer > XclImpNumFmtBfrRef;
- typedef boost::shared_ptr< XclImpXFBuffer > XclImpXFBfrRef;
- typedef boost::shared_ptr< XclImpXFRangeBuffer > XclImpXFRangeBfrRef;
- typedef boost::shared_ptr< XclImpTabInfo > XclImpTabInfoRef;
- typedef boost::shared_ptr< XclImpNameManager > XclImpNameMgrRef;
- typedef boost::shared_ptr< XclImpLinkManager > XclImpLinkMgrRef;
- typedef boost::shared_ptr< XclImpObjectManager > XclImpObjectMgrRef;
- typedef boost::shared_ptr< XclImpCondFormatManager > XclImpCondFmtMgrRef;
- typedef boost::shared_ptr< XclImpValidationManager > XclImpValidationMgrRef;
- typedef boost::shared_ptr< XclImpWebQueryBuffer > XclImpWebQueryBfrRef;
- typedef boost::shared_ptr< XclImpPivotTableManager > XclImpPTableMgrRef;
- typedef boost::shared_ptr< XclImpPageSettings > XclImpPageSettRef;
- typedef boost::shared_ptr< XclImpDocViewSettings > XclImpDocViewSettRef;
- typedef boost::shared_ptr< XclImpTabViewSettings > XclImpTabViewSettRef;
- typedef boost::shared_ptr< XclImpSheetProtectBuffer > XclImpTabProtectRef;
- typedef boost::shared_ptr< XclImpDocProtectBuffer > XclImpDocProtectRef;
+ typedef std::shared_ptr< XclImpAddressConverter > XclImpAddrConvRef;
+ typedef std::shared_ptr< XclImpFormulaCompiler > XclImpFmlaCompRef;
+
+ typedef std::shared_ptr< XclImpSst > XclImpSstRef;
+ typedef std::shared_ptr< XclImpPalette > XclImpPaletteRef;
+ typedef std::shared_ptr< XclImpFontBuffer > XclImpFontBfrRef;
+ typedef std::shared_ptr< XclImpNumFmtBuffer > XclImpNumFmtBfrRef;
+ typedef std::shared_ptr< XclImpXFBuffer > XclImpXFBfrRef;
+ typedef std::shared_ptr< XclImpXFRangeBuffer > XclImpXFRangeBfrRef;
+ typedef std::shared_ptr< XclImpTabInfo > XclImpTabInfoRef;
+ typedef std::shared_ptr< XclImpNameManager > XclImpNameMgrRef;
+ typedef std::shared_ptr< XclImpLinkManager > XclImpLinkMgrRef;
+ typedef std::shared_ptr< XclImpObjectManager > XclImpObjectMgrRef;
+ typedef std::shared_ptr< XclImpCondFormatManager > XclImpCondFmtMgrRef;
+ typedef std::shared_ptr< XclImpValidationManager > XclImpValidationMgrRef;
+ typedef std::shared_ptr< XclImpWebQueryBuffer > XclImpWebQueryBfrRef;
+ typedef std::shared_ptr< XclImpPivotTableManager > XclImpPTableMgrRef;
+ typedef std::shared_ptr< XclImpPageSettings > XclImpPageSettRef;
+ typedef std::shared_ptr< XclImpDocViewSettings > XclImpDocViewSettRef;
+ typedef std::shared_ptr< XclImpTabViewSettings > XclImpTabViewSettRef;
+ typedef std::shared_ptr< XclImpSheetProtectBuffer > XclImpTabProtectRef;
+ typedef std::shared_ptr< XclImpDocProtectBuffer > XclImpDocProtectRef;
XclImpAddrConvRef mxAddrConv; /// The address converter.
XclImpFmlaCompRef mxFmlaComp; /// The formula compiler.
@@ -112,7 +112,7 @@ struct XclImpRootData : public XclRootData
XclImpTabProtectRef mxTabProtect; /// Sheet protection options for current sheet.
XclImpDocProtectRef mxDocProtect; /// Document protection options.
- boost::shared_ptr<ScDocumentImport> mxDocImport;
+ std::shared_ptr<ScDocumentImport> mxDocImport;
bool mbHasCodePage; /// true = CODEPAGE record exists.
bool mbHasBasic; /// true = document contains VB project.
diff --git a/sc/source/filter/inc/xistream.hxx b/sc/source/filter/inc/xistream.hxx
index 45a916550118..0843cd187b3b 100644
--- a/sc/source/filter/inc/xistream.hxx
+++ b/sc/source/filter/inc/xistream.hxx
@@ -22,7 +22,7 @@
#include <comphelper/docpasswordhelper.hxx>
#include <filter/msfilter/mscodec.hxx>
-#include <boost/shared_ptr.hpp>
+#include <memory>
#include "xlstream.hxx"
#include "xlconst.hxx"
@@ -37,7 +37,7 @@ Input stream class for Excel import
// Decryption
class XclImpDecrypter;
-typedef boost::shared_ptr< XclImpDecrypter > XclImpDecrypterRef;
+typedef std::shared_ptr< XclImpDecrypter > XclImpDecrypterRef;
/** Base class for BIFF stream decryption. */
class XclImpDecrypter : public ::comphelper::IDocPasswordVerifier
diff --git a/sc/source/filter/inc/xistyle.hxx b/sc/source/filter/inc/xistyle.hxx
index 9a767fe853ff..f4dc557c9c32 100644
--- a/sc/source/filter/inc/xistyle.hxx
+++ b/sc/source/filter/inc/xistyle.hxx
@@ -21,9 +21,9 @@
#define INCLUDED_SC_SOURCE_FILTER_INC_XISTYLE_HXX
#include <list>
+#include <memory>
#include <tools/mempool.hxx>
#include <boost/noncopyable.hpp>
-#include <boost/shared_ptr.hpp>
#include <boost/ptr_container/ptr_vector.hpp>
#include "rangelst.hxx"
#include "patattr.hxx"
@@ -649,7 +649,7 @@ private:
void SetBorderLine( const ScRange& rRange, SCTAB nScTab, SvxBoxItemLine nLine );
private:
- typedef boost::shared_ptr< XclImpXFRangeColumn > XclImpXFRangeColumnRef;
+ typedef std::shared_ptr< XclImpXFRangeColumn > XclImpXFRangeColumnRef;
typedef ::std::vector< XclImpXFRangeColumnRef > XclImpXFRangeColumnVec;
typedef ::std::pair< XclRange, OUString > XclImpHyperlinkRange;
typedef ::std::list< XclImpHyperlinkRange > XclImpHyperlinkList;
diff --git a/sc/source/filter/inc/xlformula.hxx b/sc/source/filter/inc/xlformula.hxx
index 2f10c3da4b4d..d93c2ebb50ed 100644
--- a/sc/source/filter/inc/xlformula.hxx
+++ b/sc/source/filter/inc/xlformula.hxx
@@ -20,12 +20,12 @@
#ifndef INCLUDED_SC_SOURCE_FILTER_INC_XLFORMULA_HXX
#define INCLUDED_SC_SOURCE_FILTER_INC_XLFORMULA_HXX
-#include <map>
#include <osl/diagnose.h>
#include <formula/opcode.hxx>
#include "address.hxx"
#include "ftools.hxx"
-#include <boost/shared_ptr.hpp>
+#include <map>
+#include <memory>
namespace svl {
@@ -414,7 +414,7 @@ private:
bool mbVolatile; /// True = Formula contains volatile function.
};
-typedef boost::shared_ptr< XclTokenArray > XclTokenArrayRef;
+typedef std::shared_ptr< XclTokenArray > XclTokenArrayRef;
/** Calls the Read() function at the passed token array. */
XclImpStream& operator>>( XclImpStream& rStrm, XclTokenArray& rTokArr );
diff --git a/sc/source/filter/inc/xlpage.hxx b/sc/source/filter/inc/xlpage.hxx
index f5333b96fcbf..b60d21a3f4a9 100644
--- a/sc/source/filter/inc/xlpage.hxx
+++ b/sc/source/filter/inc/xlpage.hxx
@@ -23,6 +23,7 @@
#include <tools/gen.hxx>
#include <boost/noncopyable.hpp>
#include "xltools.hxx"
+#include <memory>
// Constants and Enumerations =================================================
@@ -91,7 +92,7 @@ class SvxBrushItem;
/** Contains all page (print) settings for a single sheet. */
struct XclPageData : private boost::noncopyable
{
- typedef ::std::unique_ptr< SvxBrushItem > SvxBrushItemPtr;
+ typedef std::unique_ptr< SvxBrushItem > SvxBrushItemPtr;
ScfUInt16Vec maHorPageBreaks; /// Horizontal page breaks.
ScfUInt16Vec maVerPageBreaks; /// Vertical page breaks.
diff --git a/sc/source/filter/inc/xlpivot.hxx b/sc/source/filter/inc/xlpivot.hxx
index 601cd2f7c9a7..b0afc1a9363a 100644
--- a/sc/source/filter/inc/xlpivot.hxx
+++ b/sc/source/filter/inc/xlpivot.hxx
@@ -32,7 +32,7 @@
#include "xladdress.hxx"
#include "dpobject.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
class XclImpStream;
class XclExpStream;
@@ -618,7 +618,7 @@ struct XclPTFieldExtInfo
sal_uInt16 mnSortField; /// Index to data field sorting bases on.
sal_uInt16 mnShowField; /// Index to data field AutoShow bases on.
sal_uInt16 mnNumFmt;
- boost::scoped_ptr<OUString> mpFieldTotalName;
+ std::unique_ptr<OUString> mpFieldTotalName;
explicit XclPTFieldExtInfo();
diff --git a/sc/source/filter/inc/xlroot.hxx b/sc/source/filter/inc/xlroot.hxx
index b47043bbda90..645fe797db82 100644
--- a/sc/source/filter/inc/xlroot.hxx
+++ b/sc/source/filter/inc/xlroot.hxx
@@ -27,7 +27,7 @@
#include "xlconst.hxx"
#include "xltools.hxx"
#include <documentimport.hxx>
-#include <boost/shared_ptr.hpp>
+#include <memory>
namespace comphelper { class IDocPasswordVerifier; }
@@ -67,14 +67,14 @@ struct XclRootData
: public XclDebugObjCounter
#endif
{
- typedef boost::shared_ptr< ScEditEngineDefaulter > ScEEDefaulterRef;
- typedef boost::shared_ptr< ScHeaderEditEngine > ScHeaderEERef;
- typedef boost::shared_ptr< EditEngine > EditEngineRef;
- typedef boost::shared_ptr< XclFontPropSetHelper > XclFontPropSetHlpRef;
- typedef boost::shared_ptr< XclChPropSetHelper > XclChPropSetHlpRef;
- typedef boost::shared_ptr< ScExtDocOptions > ScExtDocOptRef;
- typedef boost::shared_ptr< XclTracer > XclTracerRef;
- typedef boost::shared_ptr< RootData > RootDataRef;
+ typedef std::shared_ptr< ScEditEngineDefaulter > ScEEDefaulterRef;
+ typedef std::shared_ptr< ScHeaderEditEngine > ScHeaderEERef;
+ typedef std::shared_ptr< EditEngine > EditEngineRef;
+ typedef std::shared_ptr< XclFontPropSetHelper > XclFontPropSetHlpRef;
+ typedef std::shared_ptr< XclChPropSetHelper > XclChPropSetHlpRef;
+ typedef std::shared_ptr< ScExtDocOptions > ScExtDocOptRef;
+ typedef std::shared_ptr< XclTracer > XclTracerRef;
+ typedef std::shared_ptr< RootData > RootDataRef;
XclBiff meBiff; /// Current BIFF version.
XclOutput meOutput; /// Current Output format.
diff --git a/sc/source/filter/inc/xlview.hxx b/sc/source/filter/inc/xlview.hxx
index 37d88d0cf5f3..5bdd68d0665e 100644
--- a/sc/source/filter/inc/xlview.hxx
+++ b/sc/source/filter/inc/xlview.hxx
@@ -20,11 +20,11 @@
#ifndef INCLUDED_SC_SOURCE_FILTER_INC_XLVIEW_HXX
#define INCLUDED_SC_SOURCE_FILTER_INC_XLVIEW_HXX
-#include <map>
#include <tools/color.hxx>
#include "ftools.hxx"
#include "xladdress.hxx"
-#include <boost/shared_ptr.hpp>
+#include <map>
+#include <memory>
// Constants and enumerations =================================================
@@ -112,7 +112,7 @@ struct XclSelectionData
inline explicit XclSelectionData() : mnCursorIdx( 0 ) {}
};
-typedef boost::shared_ptr< XclSelectionData > XclSelectionDataRef;
+typedef std::shared_ptr< XclSelectionData > XclSelectionDataRef;
/** Contains all view settings for a single sheet. */
struct XclTabViewData
diff --git a/sc/source/filter/oox/formulabuffer.cxx b/sc/source/filter/oox/formulabuffer.cxx
index 39a7d3e4b7fe..293551cb2c45 100644
--- a/sc/source/filter/oox/formulabuffer.cxx
+++ b/sc/source/filter/oox/formulabuffer.cxx
@@ -36,8 +36,8 @@ using namespace ::com::sun::star::table;
using namespace ::com::sun::star::sheet;
using namespace ::com::sun::star::container;
-#include <boost/scoped_ptr.hpp>
#include <boost/noncopyable.hpp>
+#include <memory>
namespace oox { namespace xls {
@@ -250,7 +250,7 @@ void applyArrayFormulas(
ScCompiler aComp(&rDoc.getDoc(), aPos);
aComp.SetNumberFormatter(&rFormatter);
aComp.SetGrammar(formula::FormulaGrammar::GRAM_OOXML);
- boost::scoped_ptr<ScTokenArray> pArray(aComp.CompileString(it->maTokenAndAddress.maTokenStr));
+ std::unique_ptr<ScTokenArray> pArray(aComp.CompileString(it->maTokenAndAddress.maTokenStr));
if (pArray)
rDoc.setMatrixCells(aRange, *pArray, formula::FormulaGrammar::GRAM_OOXML);
}
@@ -318,7 +318,7 @@ class WorkerThread: public salhelper::Thread, private boost::noncopyable
{
ScDocumentImport& mrDoc;
FormulaBuffer::SheetItem& mrItem;
- boost::scoped_ptr<SvNumberFormatter> mpFormatter;
+ std::unique_ptr<SvNumberFormatter> mpFormatter;
const uno::Sequence<sheet::ExternalLinkInfo>& mrExternalLinks;
public:
diff --git a/sc/source/filter/oox/revisionfragment.cxx b/sc/source/filter/oox/revisionfragment.cxx
index e4ca60819958..14fb06f471ba 100644
--- a/sc/source/filter/oox/revisionfragment.cxx
+++ b/sc/source/filter/oox/revisionfragment.cxx
@@ -27,7 +27,7 @@
#include <chgviset.hxx>
#include <richstringcontext.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include <com/sun/star/util/DateTime.hpp>
@@ -266,7 +266,7 @@ void RevisionHeadersFragment::finalizeImport()
const RevisionMetadata& rData = it->second;
pCT->SetUser(rData.maUserName);
pCT->SetFixDateTimeLocal(rData.maDateTime);
- boost::scoped_ptr<oox::core::FastParser> xParser(getOoxFilter().createParser());
+ std::unique_ptr<oox::core::FastParser> xParser(getOoxFilter().createParser());
rtl::Reference<oox::core::FragmentHandler> xFragment(new RevisionLogFragment(*this, aPath, *pCT));
importOoxFragment(xFragment, *xParser);
}
diff --git a/sc/source/filter/oox/stylesbuffer.cxx b/sc/source/filter/oox/stylesbuffer.cxx
index bf63786e9725..a3c126730c44 100644
--- a/sc/source/filter/oox/stylesbuffer.cxx
+++ b/sc/source/filter/oox/stylesbuffer.cxx
@@ -2273,7 +2273,7 @@ void Xf::writeToDoc( ScDocumentImport& rDoc, const table::CellRangeAddress& rRan
}
}
- boost::scoped_ptr<ScPatternAttr> pAttr(new ScPatternAttr(rDoc.getDoc().GetPool()));
+ std::unique_ptr<ScPatternAttr> pAttr(new ScPatternAttr(rDoc.getDoc().GetPool()));
{
SvxRotateMode eRotateMode = SVX_ROTATE_MODE_STANDARD;
diff --git a/sc/source/filter/oox/workbookfragment.cxx b/sc/source/filter/oox/workbookfragment.cxx
index 0560ad52bc8e..681883f9f222 100644
--- a/sc/source/filter/oox/workbookfragment.cxx
+++ b/sc/source/filter/oox/workbookfragment.cxx
@@ -64,7 +64,7 @@
#include <algorithm>
#include <queue>
#include <thread>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include <oox/ole/vbaproject.hxx>
@@ -235,7 +235,7 @@ public:
SolarMutexGuard maGuard;
SAL_INFO( "sc.filter", "got solar\n" );
- boost::scoped_ptr<oox::core::FastParser> xParser(
+ std::unique_ptr<oox::core::FastParser> xParser(
mrWorkbookHandler.getOoxFilter().createParser() );
SAL_INFO( "sc.filter", "start import\n" );
@@ -503,7 +503,7 @@ void WorkbookFragment::finalizeImport()
OUString aRevHeadersPath = getFragmentPathFromFirstType(CREATE_OFFICEDOC_RELATION_TYPE("revisionHeaders"));
if (!aRevHeadersPath.isEmpty())
{
- boost::scoped_ptr<oox::core::FastParser> xParser(getOoxFilter().createParser());
+ std::unique_ptr<oox::core::FastParser> xParser(getOoxFilter().createParser());
rtl::Reference<oox::core::FragmentHandler> xFragment(new RevisionHeadersFragment(*this, aRevHeadersPath));
importOoxFragment(xFragment, *xParser);
}
diff --git a/sc/source/filter/oox/workbookhelper.cxx b/sc/source/filter/oox/workbookhelper.cxx
index 883a58d1a7ab..250a129ae623 100644
--- a/sc/source/filter/oox/workbookhelper.cxx
+++ b/sc/source/filter/oox/workbookhelper.cxx
@@ -86,7 +86,7 @@
#include <officecfg/Office/Calc.hxx>
#include <boost/noncopyable.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
namespace oox {
namespace xls {
@@ -247,7 +247,7 @@ private:
typedef ::std::unique_ptr< WorkbookSettings > WorkbookSettPtr;
typedef ::std::unique_ptr< ViewSettings > ViewSettingsPtr;
typedef ::std::unique_ptr< WorksheetBuffer > WorksheetBfrPtr;
- typedef ::boost::shared_ptr< ThemeBuffer > ThemeBfrRef;
+ typedef ::std::shared_ptr< ThemeBuffer > ThemeBfrRef;
typedef ::std::unique_ptr< StylesBuffer > StylesBfrPtr;
typedef ::std::unique_ptr< SharedStringsBuffer > SharedStrBfrPtr;
typedef ::std::unique_ptr< ExternalLinkBuffer > ExtLinkBfrPtr;
@@ -312,7 +312,7 @@ private:
bool mbHasCodePage; /// True = CODEPAGE record exists in imported stream.
ScDocument* mpDoc;
ScDocShell* mpDocShell;
- boost::scoped_ptr<ScDocumentImport> mxDocImport;
+ std::unique_ptr<ScDocumentImport> mxDocImport;
};
WorkbookGlobals::WorkbookGlobals( ExcelFilter& rFilter ) :
diff --git a/sc/source/filter/orcus/interface.cxx b/sc/source/filter/orcus/interface.cxx
index ee04869f93d7..25d1475c5d14 100644
--- a/sc/source/filter/orcus/interface.cxx
+++ b/sc/source/filter/orcus/interface.cxx
@@ -663,7 +663,7 @@ void ScOrcusSheet::set_array_formula(
ScCompiler aComp(&mrDoc.getDoc(), aRange.aStart);
aComp.SetGrammar(eGrammar);
- boost::scoped_ptr<ScTokenArray> pArray(aComp.CompileString(aFormula));
+ std::unique_ptr<ScTokenArray> pArray(aComp.CompileString(aFormula));
if (!pArray)
return;
diff --git a/sc/source/filter/rtf/eeimpars.cxx b/sc/source/filter/rtf/eeimpars.cxx
index 341dbf79daad..d988d365dbe8 100644
--- a/sc/source/filter/rtf/eeimpars.cxx
+++ b/sc/source/filter/rtf/eeimpars.cxx
@@ -56,7 +56,7 @@
#include "globstr.hrc"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
ScEEImport::ScEEImport( ScDocument* pDocP, const ScRange& rRange ) :
maRange( rRange ),
diff --git a/sc/source/filter/xcl97/xcl97rec.cxx b/sc/source/filter/xcl97/xcl97rec.cxx
index d4085ef455ea..c64a78837afa 100644
--- a/sc/source/filter/xcl97/xcl97rec.cxx
+++ b/sc/source/filter/xcl97/xcl97rec.cxx
@@ -80,7 +80,7 @@
#include <oox/export/vmlexport.hxx>
#include <boost/checked_delete.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace ::com::sun::star;
using ::com::sun::star::uno::Reference;
@@ -374,7 +374,7 @@ void XclObj::ImplWriteAnchor( const XclExpRoot& /*rRoot*/, const SdrObject* pSdr
}
else if( pSdrObj )
{
- boost::scoped_ptr< XclExpDffAnchorBase > xDffAnchor( mrEscherEx.CreateDffAnchor( *pSdrObj ) );
+ std::unique_ptr< XclExpDffAnchorBase > xDffAnchor( mrEscherEx.CreateDffAnchor( *pSdrObj ) );
xDffAnchor->WriteDffData( mrEscherEx );
}
}
@@ -427,7 +427,7 @@ void XclObj::WriteBody( XclExpStream& rStrm )
// create a substream to be able to create subrecords
SvMemoryStream aMemStrm;
- boost::scoped_ptr< XclExpStream > pXclStrm( new XclExpStream( aMemStrm, rStrm.GetRoot() ) );
+ std::unique_ptr< XclExpStream > pXclStrm( new XclExpStream( aMemStrm, rStrm.GetRoot() ) );
// write the ftCmo subrecord
pXclStrm->StartRecord( EXC_ID_OBJCMO, 18 );
diff --git a/sc/source/filter/xml/XMLExportIterator.hxx b/sc/source/filter/xml/XMLExportIterator.hxx
index d0e5a65888e8..12225c2d116f 100644
--- a/sc/source/filter/xml/XMLExportIterator.hxx
+++ b/sc/source/filter/xml/XMLExportIterator.hxx
@@ -37,7 +37,7 @@
#include "cellvalue.hxx"
#include <boost/noncopyable.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
class ScHorizontalCellIterator;
struct ScMyCell;
@@ -330,7 +330,7 @@ class ScMyNotEmptyCellsIterator : boost::noncopyable
ScMyDetectiveOpContainer* pDetectiveOp;
ScXMLExport& rExport;
- boost::scoped_ptr<ScHorizontalCellIterator> mpCellItr;
+ std::unique_ptr<ScHorizontalCellIterator> mpCellItr;
SCCOL nCellCol;
SCROW nCellRow;
diff --git a/sc/source/filter/xml/XMLStylesImportHelper.hxx b/sc/source/filter/xml/XMLStylesImportHelper.hxx
index b4f5e74de5ea..8d701654d0ff 100644
--- a/sc/source/filter/xml/XMLStylesImportHelper.hxx
+++ b/sc/source/filter/xml/XMLStylesImportHelper.hxx
@@ -24,10 +24,10 @@
#include "simplerangelist.hxx"
#include <rtl/ustring.hxx>
+#include <list>
+#include <memory>
#include <set>
#include <vector>
-#include <list>
-#include <boost/shared_ptr.hpp>
class ScXMLImport;
@@ -65,7 +65,7 @@ public:
struct ScMyCurrencyStyle
{
OUString sCurrency;
- ::boost::shared_ptr<ScSimpleRangeList> mpRanges;
+ std::shared_ptr<ScSimpleRangeList> mpRanges;
ScMyCurrencyStyle() :
mpRanges(new ScSimpleRangeList)
@@ -85,13 +85,13 @@ typedef std::set<ScMyCurrencyStyle, LessCurrencyStyle> ScMyCurrencyStylesSet;
class ScMyStyleRanges : public SvRefBase
{
- ::boost::shared_ptr<ScSimpleRangeList> mpTextList;
- ::boost::shared_ptr<ScSimpleRangeList> mpNumberList;
- ::boost::shared_ptr<ScSimpleRangeList> mpTimeList;
- ::boost::shared_ptr<ScSimpleRangeList> mpDateTimeList;
- ::boost::shared_ptr<ScSimpleRangeList> mpPercentList;
- ::boost::shared_ptr<ScSimpleRangeList> mpLogicalList;
- ::boost::shared_ptr<ScSimpleRangeList> mpUndefinedList;
+ std::shared_ptr<ScSimpleRangeList> mpTextList;
+ std::shared_ptr<ScSimpleRangeList> mpNumberList;
+ std::shared_ptr<ScSimpleRangeList> mpTimeList;
+ std::shared_ptr<ScSimpleRangeList> mpDateTimeList;
+ std::shared_ptr<ScSimpleRangeList> mpPercentList;
+ std::shared_ptr<ScSimpleRangeList> mpLogicalList;
+ std::shared_ptr<ScSimpleRangeList> mpUndefinedList;
ScMyCurrencyStylesSet* pCurrencyList;
static void SetStylesToRanges(const ::std::list<ScRange>& rList,
diff --git a/sc/source/filter/xml/xmlbodyi.cxx b/sc/source/filter/xml/xmlbodyi.cxx
index 24e0860257fb..c2b4b00f1ada 100644
--- a/sc/source/filter/xml/xmlbodyi.cxx
+++ b/sc/source/filter/xml/xmlbodyi.cxx
@@ -51,7 +51,7 @@
#include <com/sun/star/sheet/XSpreadsheetDocument.hpp>
#include <sal/types.h>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace com::sun::star;
using namespace xmloff::token;
@@ -268,7 +268,7 @@ void ScXMLBodyContext::EndElement()
// #i37959# handle document protection after the sheet settings
if (bProtected)
{
- boost::scoped_ptr<ScDocProtection> pProtection(new ScDocProtection);
+ std::unique_ptr<ScDocProtection> pProtection(new ScDocProtection);
pProtection->setProtected(true);
uno::Sequence<sal_Int8> aPass;
diff --git a/sc/source/filter/xml/xmlcelli.cxx b/sc/source/filter/xml/xmlcelli.cxx
index 7712e528d2b2..601d71e559c5 100644
--- a/sc/source/filter/xml/xmlcelli.cxx
+++ b/sc/source/filter/xml/xmlcelli.cxx
@@ -415,7 +415,7 @@ void ScXMLTableRowCellContext::PushFormat(sal_Int32 nBegin, sal_Int32 nEnd, cons
ScAddress aCellPos = rXMLImport.GetTables().GetCurrentCellPos();
pSheetData->AddTextStyle(rStyleName, aCellPos, rFmt.maSelection);
- boost::scoped_ptr<SfxPoolItem> pPoolItem;
+ std::unique_ptr<SfxPoolItem> pPoolItem;
sal_uInt16 nLastItemID = EE_CHAR_END + 1;
std::vector<XMLPropertyState>::const_iterator it = rProps.begin(), itEnd = rProps.end();
@@ -1369,7 +1369,7 @@ void ScXMLTableRowCellContext::PutFormulaCell( const ScAddress& rCellPos )
OUString aText = maFormula->first;
- ::boost::scoped_ptr<ScExternalRefManager::ApiGuard> pExtRefGuard (
+ std::unique_ptr<ScExternalRefManager::ApiGuard> pExtRefGuard (
new ScExternalRefManager::ApiGuard(pDoc));
if ( !aText.isEmpty() )
diff --git a/sc/source/filter/xml/xmlcelli.hxx b/sc/source/filter/xml/xmlcelli.hxx
index c9ed567b9f64..14f605e790b9 100644
--- a/sc/source/filter/xml/xmlcelli.hxx
+++ b/sc/source/filter/xml/xmlcelli.hxx
@@ -28,9 +28,9 @@
#include <editeng/flditem.hxx>
#include <boost/optional.hpp>
-#include <boost/scoped_ptr.hpp>
#include <boost/ptr_container/ptr_vector.hpp>
#include <boost/noncopyable.hpp>
+#include <memory>
class ScXMLImport;
class ScFormulaCell;
@@ -72,7 +72,7 @@ class ScXMLTableRowCellContext : public ScXMLImportContext
ParaFormatsType maFormats;
FieldsType maFields;
- boost::scoped_ptr< ScXMLAnnotationData > mxAnnotationData;
+ std::unique_ptr< ScXMLAnnotationData > mxAnnotationData;
ScMyImpDetectiveObjVec* pDetectiveObjVec;
ScMyImpCellRangeSource* pCellRangeSource;
double fValue;
diff --git a/sc/source/filter/xml/xmldpimp.hxx b/sc/source/filter/xml/xmldpimp.hxx
index 47f039301afb..809453655170 100644
--- a/sc/source/filter/xml/xmldpimp.hxx
+++ b/sc/source/filter/xml/xmldpimp.hxx
@@ -81,7 +81,7 @@ class ScXMLDataPilotTableContext : public SvXMLImportContext
};
ScDocument* pDoc;
ScDPObject* pDPObject;
- boost::scoped_ptr<ScDPSaveData> pDPSave;
+ std::unique_ptr<ScDPSaveData> pDPSave;
ScDPDimensionSaveData* pDPDimSaveData;
GrandTotalItem maRowGrandTotal;
GrandTotalItem maColGrandTotal;
diff --git a/sc/source/filter/xml/xmldrani.hxx b/sc/source/filter/xml/xmldrani.hxx
index d66c9be840eb..58e3ec15aa67 100644
--- a/sc/source/filter/xml/xmldrani.hxx
+++ b/sc/source/filter/xml/xmldrani.hxx
@@ -33,7 +33,7 @@
#include "dbdata.hxx"
#include "xmlimprt.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
class ScDBData;
struct ScQueryParam;
@@ -68,7 +68,7 @@ struct ScSubTotalRule
class ScXMLDatabaseRangeContext : public SvXMLImportContext
{
- boost::scoped_ptr<ScQueryParam> mpQueryParam;
+ std::unique_ptr<ScQueryParam> mpQueryParam;
ScRange maRange;
OUString sDatabaseRangeName;
OUString sConnectionResource;
diff --git a/sc/source/filter/xml/xmlexprt.cxx b/sc/source/filter/xml/xmlexprt.cxx
index 04a273c8964a..a72459b1d2e7 100644
--- a/sc/source/filter/xml/xmlexprt.cxx
+++ b/sc/source/filter/xml/xmlexprt.cxx
@@ -163,9 +163,9 @@
#include <sfx2/linkmgr.hxx>
#include <sfx2/objsh.hxx>
+#include <memory>
#include <vector>
#include <vbahelper/vbaaccesshelper.hxx>
-#include <boost/scoped_ptr.hpp>
//! not found in unonames.hxx
#define SC_LAYERID "LayerID"
@@ -2934,7 +2934,7 @@ namespace {
void writeContent(
ScXMLExport& rExport, const OUString& rStyleName, const OUString& rContent, const SvxFieldData* pField )
{
- boost::scoped_ptr<SvXMLElementExport> pElem;
+ std::unique_ptr<SvXMLElementExport> pElem;
if (!rStyleName.isEmpty())
{
// Formatted section with automatic style.
@@ -3394,7 +3394,7 @@ void ScXMLExport::ExportShape(const uno::Reference < drawing::XShape >& xShape,
// no hyperlink property
}
- boost::scoped_ptr< SvXMLElementExport > pDrawA;
+ std::unique_ptr< SvXMLElementExport > pDrawA;
// enclose shapes with <draw:a> element only if sHlink contains something
if ( !sHlink.isEmpty() )
{
diff --git a/sc/source/filter/xml/xmlexprt.hxx b/sc/source/filter/xml/xmlexprt.hxx
index 0c26018f26b7..c2ca5f5c2f6d 100644
--- a/sc/source/filter/xml/xmlexprt.hxx
+++ b/sc/source/filter/xml/xmlexprt.hxx
@@ -33,7 +33,7 @@ namespace com { namespace sun { namespace star {
namespace beans { class XPropertySet; }
} } }
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include <unordered_map>
class ScOutlineArray;
@@ -79,9 +79,9 @@ class ScXMLExport : public SvXMLExport
com::sun::star::uno::Reference<com::sun::star::io::XInputStream> xSourceStream;
sal_Int32 nSourceStreamPos;
- mutable boost::scoped_ptr<ScXMLEditAttributeMap> mpEditAttrMap;
- boost::scoped_ptr<ScMyNotEmptyCellsIterator> mpCellsItr;
- boost::scoped_ptr<sc::CompileFormulaContext> mpCompileFormulaCxt;
+ mutable std::unique_ptr<ScXMLEditAttributeMap> mpEditAttrMap;
+ std::unique_ptr<ScMyNotEmptyCellsIterator> mpCellsItr;
+ std::unique_ptr<sc::CompileFormulaContext> mpCompileFormulaCxt;
rtl::Reference < XMLPropertyHandlerFactory > xScPropHdlFactory;
rtl::Reference < XMLPropertySetMapper > xCellStylesPropertySetMapper;
rtl::Reference < XMLPropertySetMapper > xColumnStylesPropertySetMapper;
diff --git a/sc/source/filter/xml/xmlimprt.cxx b/sc/source/filter/xml/xmlimprt.cxx
index 94072269aebb..10dade62d3da 100644
--- a/sc/source/filter/xml/xmlimprt.cxx
+++ b/sc/source/filter/xml/xmlimprt.cxx
@@ -2457,7 +2457,7 @@ void ScXMLImport::SetChangeTrackingViewSettings(const com::sun::star::uno::Seque
{
ScXMLImport::MutexGuard aGuard(*this);
sal_Int16 nTemp16(0);
- boost::scoped_ptr<ScChangeViewSettings> pViewSettings(new ScChangeViewSettings());
+ std::unique_ptr<ScChangeViewSettings> pViewSettings(new ScChangeViewSettings());
for (sal_Int32 i = 0; i < nCount; ++i)
{
OUString sName(rChangeProps[i].Name);
diff --git a/sc/source/filter/xml/xmlimprt.hxx b/sc/source/filter/xml/xmlimprt.hxx
index ae5ffe1747f9..81a9520891e3 100644
--- a/sc/source/filter/xml/xmlimprt.hxx
+++ b/sc/source/filter/xml/xmlimprt.hxx
@@ -42,12 +42,12 @@
#include <com/sun/star/util/XNumberFormatTypes.hpp>
#include <com/sun/star/sheet/XSheetCellRangeContainer.hpp>
+#include <memory>
#include <unordered_map>
#include <vector>
#include <boost/ptr_container/ptr_list.hpp>
#include <boost/ptr_container/ptr_map.hpp>
#include <boost/noncopyable.hpp>
-#include <boost/scoped_ptr.hpp>
class ScMyStyleNumberFormats;
class XMLNumberFormatAttributesExportHelper;
@@ -828,12 +828,12 @@ class ScXMLImport: public SvXMLImport, boost::noncopyable
CellTypeMap aCellTypeMap;
ScDocument* pDoc;
- boost::scoped_ptr<ScDocumentImport> mpDocImport;
- boost::scoped_ptr<ScCompiler> mpComp; // For error-checking of cached string cell values.
- boost::scoped_ptr<ScEditEngineDefaulter> mpEditEngine;
- boost::scoped_ptr<sc::PivotTableSources> mpPivotSources;
+ std::unique_ptr<ScDocumentImport> mpDocImport;
+ std::unique_ptr<ScCompiler> mpComp; // For error-checking of cached string cell values.
+ std::unique_ptr<ScEditEngineDefaulter> mpEditEngine;
+ std::unique_ptr<sc::PivotTableSources> mpPivotSources;
- mutable boost::scoped_ptr<ScXMLEditAttributeMap> mpEditAttrMap;
+ mutable std::unique_ptr<ScXMLEditAttributeMap> mpEditAttrMap;
ScXMLChangeTrackingImportHelper* pChangeTrackingImportHelper;
std::list<SvXMLImportContext*> aViewContextList;
ScMyStylesImportHelper* pStylesImportHelper;
diff --git a/sc/source/filter/xml/xmlnexpi.hxx b/sc/source/filter/xml/xmlnexpi.hxx
index cce47678b4dc..46925b125a86 100644
--- a/sc/source/filter/xml/xmlnexpi.hxx
+++ b/sc/source/filter/xml/xmlnexpi.hxx
@@ -24,7 +24,7 @@
#include "address.hxx"
#include "xmlimprt.hxx"
-#include <boost/shared_ptr.hpp>
+#include <memory>
struct ScMyNamedExpression;
class ScRangeName;
@@ -87,7 +87,7 @@ public:
virtual void EndElement() SAL_OVERRIDE;
private:
- ::boost::shared_ptr<Inserter> mpInserter;
+ std::shared_ptr<Inserter> mpInserter;
};
class ScXMLNamedRangeContext : public SvXMLImportContext
diff --git a/sc/source/filter/xml/xmlsubti.cxx b/sc/source/filter/xml/xmlsubti.cxx
index f8da27fb556c..88b3ede5fad7 100644
--- a/sc/source/filter/xml/xmlsubti.cxx
+++ b/sc/source/filter/xml/xmlsubti.cxx
@@ -49,7 +49,7 @@
#include <com/sun/star/util/XProtectable.hpp>
#include <com/sun/star/sheet/XArrayFormulaRange.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace com::sun::star;
@@ -205,7 +205,7 @@ void ScMyTables::DeleteTable()
uno::Sequence<sal_Int8> aHash;
::sax::Converter::decodeBase64(aHash, maProtectionData.maPassword);
- boost::scoped_ptr<ScTableProtection> pProtect(new ScTableProtection);
+ std::unique_ptr<ScTableProtection> pProtect(new ScTableProtection);
pProtect->setProtected(maProtectionData.mbProtected);
pProtect->setPasswordHash(aHash, maProtectionData.meHash1, maProtectionData.meHash2);
pProtect->setOption(ScTableProtection::SELECT_LOCKED_CELLS, maProtectionData.mbSelectProtectedCells);
@@ -278,7 +278,7 @@ void ScMyTables::AddMatrixRange(
maMatrixRangeList.Append(aScRange);
ScDocumentImport& rDoc = rImport.GetDoc();
- boost::scoped_ptr<ScTokenArray> pCode(new ScTokenArray);
+ std::unique_ptr<ScTokenArray> pCode(new ScTokenArray);
pCode->AddStringXML( rFormula );
if( (eGrammar == formula::FormulaGrammar::GRAM_EXTERNAL) && !rFormulaNmsp.isEmpty() )
pCode->AddStringXML( rFormulaNmsp );
diff --git a/sc/source/ui/StatisticsDialogs/AnalysisOfVarianceDialog.cxx b/sc/source/ui/StatisticsDialogs/AnalysisOfVarianceDialog.cxx
index 3eb3ba010983..1a3420650edb 100644
--- a/sc/source/ui/StatisticsDialogs/AnalysisOfVarianceDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/AnalysisOfVarianceDialog.cxx
@@ -79,7 +79,7 @@ OUString lclCreateMultiParameterFormula(
void lclMakeSubRangesList(ScRangeList& rRangeList, ScRange& rInputRange, ScStatisticsInputOutputDialog::GroupedBy aGroupedBy)
{
- boost::scoped_ptr<DataRangeIterator> pIterator;
+ std::unique_ptr<DataRangeIterator> pIterator;
if (aGroupedBy == ScStatisticsInputOutputDialog::BY_COLUMN)
pIterator.reset(new DataRangeByColumnIterator(rInputRange));
else
diff --git a/sc/source/ui/StatisticsDialogs/ExponentialSmoothingDialog.cxx b/sc/source/ui/StatisticsDialogs/ExponentialSmoothingDialog.cxx
index 9acf9ed6f1d7..e023d45accf9 100644
--- a/sc/source/ui/StatisticsDialogs/ExponentialSmoothingDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/ExponentialSmoothingDialog.cxx
@@ -78,7 +78,7 @@ ScRange ScExponentialSmoothingDialog::ApplyOutput(ScDocShell* pDocShell)
// Exponential Smoothing
output.push();
- boost::scoped_ptr<DataRangeIterator> pIterator;
+ std::unique_ptr<DataRangeIterator> pIterator;
if (mGroupedBy == BY_COLUMN)
pIterator.reset(new DataRangeByColumnIterator(mInputRange));
else
diff --git a/sc/source/ui/StatisticsDialogs/MovingAverageDialog.cxx b/sc/source/ui/StatisticsDialogs/MovingAverageDialog.cxx
index 8514dfc1342b..4bebec6c547b 100644
--- a/sc/source/ui/StatisticsDialogs/MovingAverageDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/MovingAverageDialog.cxx
@@ -63,7 +63,7 @@ ScRange ScMovingAverageDialog::ApplyOutput(ScDocShell* pDocShell)
formula::FormulaGrammar::mergeToGrammar( formula::FormulaGrammar::GRAM_ENGLISH, mAddressDetails.eConv));
FormulaTemplate aTemplate(mDocument);
- boost::scoped_ptr<DataRangeIterator> pIterator;
+ std::unique_ptr<DataRangeIterator> pIterator;
if (mGroupedBy == BY_COLUMN)
pIterator.reset(new DataRangeByColumnIterator(mInputRange));
else
diff --git a/sc/source/ui/StatisticsDialogs/TableFillingAndNavigationTools.cxx b/sc/source/ui/StatisticsDialogs/TableFillingAndNavigationTools.cxx
index b7128e277560..fe746d92c26d 100644
--- a/sc/source/ui/StatisticsDialogs/TableFillingAndNavigationTools.cxx
+++ b/sc/source/ui/StatisticsDialogs/TableFillingAndNavigationTools.cxx
@@ -8,7 +8,7 @@
*
*/
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include <editeng/editobj.hxx>
#include <editeng/wghtitem.hxx>
@@ -192,7 +192,7 @@ void AddressWalkerWriter::writeBoldString(const OUString& aString)
SvxWeightItem aWeight(WEIGHT_BOLD, EE_CHAR_WEIGHT);
aItemSet.Put(aWeight);
rEngine.QuickSetAttribs(aItemSet, ESelection(0, 0, 0, aString.getLength()) );
- boost::scoped_ptr<EditTextObject> pEditText(rEngine.CreateTextObject());
+ std::unique_ptr<EditTextObject> pEditText(rEngine.CreateTextObject());
mpDocShell->GetDocFunc().SetEditCell(mCurrentAddress, *pEditText, true);
}
diff --git a/sc/source/ui/app/inputhdl.cxx b/sc/source/ui/app/inputhdl.cxx
index 6bb0d37b9fa4..9e4b8ac749ab 100644
--- a/sc/source/ui/app/inputhdl.cxx
+++ b/sc/source/ui/app/inputhdl.cxx
@@ -1247,7 +1247,7 @@ static OUString lcl_Calculate( const OUString& rFormula, ScDocument* pDoc, const
if(rFormula.isEmpty())
return OUString();
- boost::scoped_ptr<ScSimpleFormulaCalculator> pCalc( new ScSimpleFormulaCalculator( pDoc, rPos, rFormula ) );
+ std::unique_ptr<ScSimpleFormulaCalculator> pCalc( new ScSimpleFormulaCalculator( pDoc, rPos, rFormula ) );
// FIXME: HACK! In order to not get a #REF! for ColRowNames, if a name is actually inserted as a Range
// into the whole Formula, but is interpreted as a single cell reference when displaying it on its own
diff --git a/sc/source/ui/app/uiitems.cxx b/sc/source/ui/app/uiitems.cxx
index 08144fc4e857..a1c9b242fdae 100644
--- a/sc/source/ui/app/uiitems.cxx
+++ b/sc/source/ui/app/uiitems.cxx
@@ -50,8 +50,8 @@ ScInputStatusItem::ScInputStatusItem(
aStartPos ( rStartPos ),
aEndPos ( rEndPos ),
aString ( rString ),
- pEditData ( pData ? pData->Clone() : NULL ),
- mpMisspellRanges(NULL)
+ pEditData ( pData ? pData->Clone() : nullptr ),
+ mpMisspellRanges(nullptr)
{
}
@@ -61,7 +61,7 @@ ScInputStatusItem::ScInputStatusItem( const ScInputStatusItem& rItem ) :
aStartPos ( rItem.aStartPos ),
aEndPos ( rItem.aEndPos ),
aString ( rItem.aString ),
- pEditData ( rItem.pEditData ? rItem.pEditData->Clone() : NULL ),
+ pEditData ( rItem.pEditData ? rItem.pEditData->Clone() : nullptr ),
mpMisspellRanges(rItem.mpMisspellRanges)
{
}
@@ -146,7 +146,7 @@ ScSortItem::ScSortItem( sal_uInt16 nWhichP,
ScSortItem::ScSortItem( sal_uInt16 nWhichP,
const ScSortParam* pSortData ) :
SfxPoolItem ( nWhichP ),
- pViewData ( NULL )
+ pViewData ( nullptr )
{
if ( pSortData ) theSortData = *pSortData;
}
@@ -191,7 +191,7 @@ ScQueryItem::ScQueryItem( sal_uInt16 nWhichP,
ScViewData* ptrViewData,
const ScQueryParam* pQueryData ) :
SfxPoolItem ( nWhichP ),
- mpQueryData(NULL),
+ mpQueryData(nullptr),
pViewData ( ptrViewData ),
bIsAdvanced ( false )
{
@@ -204,8 +204,8 @@ ScQueryItem::ScQueryItem( sal_uInt16 nWhichP,
ScQueryItem::ScQueryItem( sal_uInt16 nWhichP,
const ScQueryParam* pQueryData ) :
SfxPoolItem ( nWhichP ),
- mpQueryData(NULL),
- pViewData ( NULL ),
+ mpQueryData(nullptr),
+ pViewData ( nullptr ),
bIsAdvanced ( false )
{
if (pQueryData)
@@ -281,7 +281,7 @@ ScSubTotalItem::ScSubTotalItem( sal_uInt16 nWhichP,
ScSubTotalItem::ScSubTotalItem( sal_uInt16 nWhichP,
const ScSubTotalParam* pSubTotalData ) :
SfxPoolItem ( nWhichP ),
- pViewData ( NULL )
+ pViewData ( nullptr )
{
if ( pSubTotalData ) theSubTotalData = *pSubTotalData;
}
@@ -324,7 +324,7 @@ bool ScSubTotalItem::QueryValue( com::sun::star::uno::Any& rVal, sal_uInt8 /* nM
*/
ScUserListItem::ScUserListItem( sal_uInt16 nWhichP )
: SfxPoolItem ( nWhichP ),
- pUserList ( NULL )
+ pUserList ( nullptr )
{
}
@@ -334,7 +334,7 @@ ScUserListItem::ScUserListItem( const ScUserListItem& rItem )
if ( rItem.pUserList )
pUserList = new ScUserList( *(rItem.pUserList) );
else
- pUserList = NULL;
+ pUserList = nullptr;
}
ScUserListItem::~ScUserListItem()
diff --git a/sc/source/ui/cctrl/checklistmenu.cxx b/sc/source/ui/cctrl/checklistmenu.cxx
index 9911d3b8c9ae..75daa6ab295e 100644
--- a/sc/source/ui/cctrl/checklistmenu.cxx
+++ b/sc/source/ui/cctrl/checklistmenu.cxx
@@ -43,13 +43,13 @@ using ::std::vector;
ScMenuFloatingWindow::MenuItemData::MenuItemData() :
mbEnabled(true), mbSeparator(false),
- mpAction(static_cast<ScCheckListMenuWindow::Action*>(NULL)),
- mpSubMenuWin(static_cast<ScMenuFloatingWindow*>(NULL))
+ mpAction(static_cast<ScCheckListMenuWindow::Action*>(nullptr)),
+ mpSubMenuWin(static_cast<ScMenuFloatingWindow*>(nullptr))
{
}
ScMenuFloatingWindow::SubMenuItemData::SubMenuItemData(ScMenuFloatingWindow* pParent) :
- mpSubMenu(NULL),
+ mpSubMenu(nullptr),
mnMenuPos(MENU_NOT_SELECTED),
mpParent(pParent)
{
@@ -59,7 +59,7 @@ ScMenuFloatingWindow::SubMenuItemData::SubMenuItemData(ScMenuFloatingWindow* pPa
void ScMenuFloatingWindow::SubMenuItemData::reset()
{
- mpSubMenu = NULL;
+ mpSubMenu = nullptr;
mnMenuPos = MENU_NOT_SELECTED;
maTimer.Stop();
}
@@ -491,7 +491,7 @@ void ScMenuFloatingWindow::handleMenuTimeout(SubMenuItemData* pTimer)
if (maCloseTimer.mpSubMenu)
{
maCloseTimer.mpSubMenu->EndPopupMode();
- maCloseTimer.mpSubMenu = NULL;
+ maCloseTimer.mpSubMenu = nullptr;
maCloseTimer.maTimer.Stop();
}
@@ -502,10 +502,10 @@ void ScMenuFloatingWindow::handleMenuTimeout(SubMenuItemData* pTimer)
// end submenu.
if (maCloseTimer.mpSubMenu)
{
- maOpenTimer.mpSubMenu = NULL;
+ maOpenTimer.mpSubMenu = nullptr;
maCloseTimer.mpSubMenu->EndPopupMode();
- maCloseTimer.mpSubMenu = NULL;
+ maCloseTimer.mpSubMenu = nullptr;
Invalidate();
maOpenTimer.mnMenuPos = MENU_NOT_SELECTED;
@@ -647,7 +647,7 @@ void ScMenuFloatingWindow::clearSelectedMenuItem()
ScMenuFloatingWindow* ScMenuFloatingWindow::getSubMenuWindow(size_t nPos) const
{
if (maMenuItems.size() <= nPos)
- return NULL;
+ return nullptr;
return maMenuItems[nPos].mpSubMenuWin.get();
}
@@ -849,7 +849,7 @@ ScCheckListMenuWindow::Member::Member()
: mbVisible(true)
, mbDate(false)
, mbLeaf(false)
- , mpParent(NULL)
+ , mpParent(nullptr)
{
}
@@ -883,9 +883,9 @@ ScCheckListMenuWindow::ScCheckListMenuWindow(vcl::Window* pParent, ScDocument* p
maBtnOk(VclPtr<OKButton>::Create(this)),
maBtnCancel(VclPtr<CancelButton>::Create(this)),
mnCurTabStop(0),
- mpExtendedData(NULL),
- mpOKAction(NULL),
- mpPopupEndAction(NULL),
+ mpExtendedData(nullptr),
+ mpOKAction(nullptr),
+ mpPopupEndAction(nullptr),
maWndSize(),
mePrevToggleAllState(TRISTATE_INDET)
{
@@ -1397,17 +1397,17 @@ void ScCheckListMenuWindow::addDateMember(const OUString& rsName, double nVal, b
maChecks->SetUpdateMode(false);
- SvTreeListEntry* pYearEntry = maChecks->FindEntry(NULL, aYearName);
+ SvTreeListEntry* pYearEntry = maChecks->FindEntry(nullptr, aYearName);
if (!pYearEntry)
{
- pYearEntry = maChecks->InsertEntry(aYearName, NULL, true);
+ pYearEntry = maChecks->InsertEntry(aYearName, nullptr, true);
Member aMemYear;
aMemYear.maName = aYearName;
aMemYear.maRealName = rsName;
aMemYear.mbDate = true;
aMemYear.mbLeaf = false;
aMemYear.mbVisible = bVisible;
- aMemYear.mpParent = NULL;
+ aMemYear.mpParent = nullptr;
maMembers.push_back(aMemYear);
}
@@ -1449,12 +1449,12 @@ void ScCheckListMenuWindow::addMember(const OUString& rName, bool bVisible)
aMember.mbDate = false;
aMember.mbLeaf = true;
aMember.mbVisible = bVisible;
- aMember.mpParent = NULL;
+ aMember.mpParent = nullptr;
maMembers.push_back(aMember);
}
ScCheckListBox::ScCheckListBox( vcl::Window* pParent, WinBits nWinStyle )
- : SvTreeListBox( pParent, nWinStyle ), mpCheckButton( NULL )
+ : SvTreeListBox( pParent, nWinStyle ), mpCheckButton( nullptr )
{
Init();
}
@@ -1470,7 +1470,7 @@ SvTreeListEntry* ScCheckListBox::FindEntry( SvTreeListEntry* pParent, const OUSt
pEntry = pParent ? NextSibling( pEntry ) : GetEntry( ++nRootPos );
}
- return NULL;
+ return nullptr;
}
void ScCheckListBox::Init()
@@ -1554,7 +1554,7 @@ void ScCheckListBox::ShowCheckEntry( const OUString& sName, SvTreeListEntry* pPa
if ( !pEntry )
{
pEntry = InsertEntry(
- sName, NULL, false, TREELIST_APPEND, NULL,
+ sName, nullptr, false, TREELIST_APPEND, nullptr,
SvLBoxButtonKind_enabledCheckbox);
SetCheckButtonState(
@@ -1578,13 +1578,13 @@ SvTreeListEntry* ScCheckListBox::CountCheckedEntries( SvTreeListEntry* pParent,
CountCheckedEntries( pEntry, nCount );
pEntry = NextSibling( pEntry );
}
- return NULL;
+ return nullptr;
}
sal_uInt16 ScCheckListBox::GetCheckedEntryCount() const
{
sal_uLong nCount = 0;
- CountCheckedEntries( NULL, nCount );
+ CountCheckedEntries( nullptr, nCount );
return nCount;
}
@@ -1636,7 +1636,7 @@ void ScCheckListMenuWindow::initMembers()
// Expand first node of checked dates
if (!maMembers[i].mpParent && maChecks->IsChecked(maMembers[i].maName, maMembers[i].mpParent))
{
- SvTreeListEntry* pEntry = maChecks->FindEntry(NULL, maMembers[i].maName);
+ SvTreeListEntry* pEntry = maChecks->FindEntry(nullptr, maMembers[i].maName);
if (pEntry)
maChecks->Expand(pEntry);
}
@@ -1647,7 +1647,7 @@ void ScCheckListMenuWindow::initMembers()
if (aLabel.isEmpty())
aLabel = ScGlobal::GetRscString(STR_EMPTYDATA);
SvTreeListEntry* pEntry = maChecks->InsertEntry(
- aLabel, NULL, false, TREELIST_APPEND, NULL,
+ aLabel, nullptr, false, TREELIST_APPEND, nullptr,
SvLBoxButtonKind_enabledCheckbox);
maChecks->SetCheckButtonState(
diff --git a/sc/source/ui/condformat/condformatdlgentry.cxx b/sc/source/ui/condformat/condformatdlgentry.cxx
index 3d9d0b9428c1..46c764e5b209 100644
--- a/sc/source/ui/condformat/condformatdlgentry.cxx
+++ b/sc/source/ui/condformat/condformatdlgentry.cxx
@@ -308,7 +308,7 @@ IMPL_LINK(ScConditionFrmtEntry, OnEdChanged, Edit*, pEdit)
ScCompiler aComp( mpDoc, maPos );
aComp.SetGrammar( mpDoc->GetGrammar() );
- boost::scoped_ptr<ScTokenArray> ta(aComp.CompileString(aFormula));
+ std::unique_ptr<ScTokenArray> ta(aComp.CompileString(aFormula));
// Error, warn the user
if( ta->GetCodeError() || ( ta->GetLen() == 0 ) )
diff --git a/sc/source/ui/dbgui/PivotLayoutTreeList.cxx b/sc/source/ui/dbgui/PivotLayoutTreeList.cxx
index 30c42c5c65b8..3b6dc553cf8f 100644
--- a/sc/source/ui/dbgui/PivotLayoutTreeList.cxx
+++ b/sc/source/ui/dbgui/PivotLayoutTreeList.cxx
@@ -56,7 +56,7 @@ bool ScPivotLayoutTreeList::DoubleClickHdl()
vector<ScDPName> aDataFieldNames;
mpParent->PushDataFieldNames(aDataFieldNames);
- boost::scoped_ptr<AbstractScDPSubtotalDlg> pDialog(
+ std::unique_ptr<AbstractScDPSubtotalDlg> pDialog(
pFactory->CreateScDPSubtotalDlg(this, mpParent->maPivotTableObject, rCurrentLabelData, rCurrentFunctionData, aDataFieldNames, true));
if (pDialog->Execute() == RET_OK)
diff --git a/sc/source/ui/dbgui/PivotLayoutTreeListData.cxx b/sc/source/ui/dbgui/PivotLayoutTreeListData.cxx
index a45b650135ef..5f9a2fb720c9 100644
--- a/sc/source/ui/dbgui/PivotLayoutTreeListData.cxx
+++ b/sc/source/ui/dbgui/PivotLayoutTreeListData.cxx
@@ -81,7 +81,7 @@ bool ScPivotLayoutTreeListData::DoubleClickHdl()
ScAbstractDialogFactory* pFactory = ScAbstractDialogFactory::Create();
- boost::scoped_ptr<AbstractScDPFunctionDlg> pDialog(
+ std::unique_ptr<AbstractScDPFunctionDlg> pDialog(
pFactory->CreateScDPFunctionDlg(this, mpParent->GetLabelDataVector(), rCurrentLabelData, rCurrentFunctionData));
if (pDialog->Execute() == RET_OK)
diff --git a/sc/source/ui/dbgui/pvfundlg.cxx b/sc/source/ui/dbgui/pvfundlg.cxx
index 1df27049e7d1..e54cc5ce619b 100644
--- a/sc/source/ui/dbgui/pvfundlg.cxx
+++ b/sc/source/ui/dbgui/pvfundlg.cxx
@@ -39,7 +39,6 @@
#include "dputil.hxx"
#include <vector>
-#include <boost/scoped_ptr.hpp>
using namespace ::com::sun::star::sheet;
diff --git a/sc/source/ui/docshell/docfunc.cxx b/sc/source/ui/docshell/docfunc.cxx
index e8d6a7832847..0ff11a59c12a 100644
--- a/sc/source/ui/docshell/docfunc.cxx
+++ b/sc/source/ui/docshell/docfunc.cxx
@@ -91,7 +91,7 @@
#include <memory>
#include <utility>
#include <basic/basmgr.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include <set>
#include <vector>
@@ -618,7 +618,7 @@ bool ScDocFunc::DeleteContents(
}
// To keep track of all non-empty cells within the deleted area.
- boost::shared_ptr<ScSimpleUndo::DataSpansType> pDataSpans;
+ std::shared_ptr<ScSimpleUndo::DataSpansType> pDataSpans;
if ( bRecord )
{
@@ -686,7 +686,7 @@ bool ScDocFunc::DeleteCell(
rDoc.DeleteObjectsInArea(rPos.Col(), rPos.Row(), rPos.Col(), rPos.Row(), rMark);
// To keep track of all non-empty cells within the deleted area.
- boost::shared_ptr<ScSimpleUndo::DataSpansType> pDataSpans;
+ std::shared_ptr<ScSimpleUndo::DataSpansType> pDataSpans;
ScDocument* pUndoDoc = NULL;
if (bRecord)
@@ -978,7 +978,7 @@ bool ScDocFunc::SetStringOrEditCell( const ScAddress& rPos, const OUString& rStr
{
ScFieldEditEngine& rEngine = rDoc.GetEditEngine();
rEngine.SetText(rStr);
- boost::scoped_ptr<EditTextObject> pEditText(rEngine.CreateTextObject());
+ std::unique_ptr<EditTextObject> pEditText(rEngine.CreateTextObject());
return SetEditCell(rPos, *pEditText, bInteraction);
}
else
@@ -1106,7 +1106,7 @@ bool ScDocFunc::PutData( const ScAddress& rPos, ScEditEngineDefaulter& rEngine,
}
// A copy of pNewData will be stored in the cell.
- boost::scoped_ptr<EditTextObject> pNewData(rEngine.CreateTextObject());
+ std::unique_ptr<EditTextObject> pNewData(rEngine.CreateTextObject());
bRet = SetEditCell(rPos, *pNewData, !bApi);
// Set the paragraph attributes back to the EditEngine.
@@ -1177,7 +1177,7 @@ bool ScDocFunc::SetCellText(
{
ScDocument& rDoc = rDocShell.GetDocument();
- ::boost::scoped_ptr<ScExternalRefManager::ApiGuard> pExtRefGuard;
+ ::std::unique_ptr<ScExternalRefManager::ApiGuard> pExtRefGuard;
if (bApi)
pExtRefGuard.reset(new ScExternalRefManager::ApiGuard(&rDoc));
@@ -5320,7 +5320,7 @@ void ScDocFunc::ReplaceConditionalFormat( sal_uLong nOldFormat, ScConditionalFor
IDF_ALL, false, pUndoDoc );
}
- boost::scoped_ptr<ScRange> pRepaintRange;
+ std::unique_ptr<ScRange> pRepaintRange;
if(nOldFormat)
{
ScConditionalFormat* pOldFormat = rDoc.GetCondFormList(nTab)->GetFormat(nOldFormat);
diff --git a/sc/source/ui/docshell/docfuncutil.cxx b/sc/source/ui/docshell/docfuncutil.cxx
index 1adb1355d556..63f1f1caca7f 100644
--- a/sc/source/ui/docshell/docfuncutil.cxx
+++ b/sc/source/ui/docshell/docfuncutil.cxx
@@ -74,7 +74,7 @@ ScDocument* DocFuncUtil::createDeleteContentsUndoDoc(
void DocFuncUtil::addDeleteContentsUndo(
svl::IUndoManager* pUndoMgr, ScDocShell* pDocSh, const ScMarkData& rMark,
const ScRange& rRange, ScDocument* pUndoDoc, InsertDeleteFlags nFlags,
- const boost::shared_ptr<ScSimpleUndo::DataSpansType>& pSpans,
+ const std::shared_ptr<ScSimpleUndo::DataSpansType>& pSpans,
bool bMulti, bool bDrawUndo )
{
std::unique_ptr<ScUndoDeleteContents> pUndo(
diff --git a/sc/source/ui/docshell/docsh.cxx b/sc/source/ui/docshell/docsh.cxx
index 18add14fadfc..e724f6811ac3 100644
--- a/sc/source/ui/docshell/docsh.cxx
+++ b/sc/source/ui/docshell/docsh.cxx
@@ -129,14 +129,14 @@
#include "sccollaboration.hxx"
#endif
+#include <memory>
#include <vector>
-#include <boost/shared_ptr.hpp>
using namespace com::sun::star;
using ::com::sun::star::uno::Reference;
using ::com::sun::star::uno::UNO_QUERY;
using ::com::sun::star::lang::XMultiServiceFactory;
-using ::boost::shared_ptr;
+using std::shared_ptr;
using ::std::vector;
// STATIC DATA -----------------------------------------------------------
diff --git a/sc/source/ui/docshell/docsh3.cxx b/sc/source/ui/docshell/docsh3.cxx
index 392435475f0c..0671e754a2fb 100644
--- a/sc/source/ui/docshell/docsh3.cxx
+++ b/sc/source/ui/docshell/docsh3.cxx
@@ -61,7 +61,7 @@
#include "conflictsdlg.hxx"
#include "globstr.hrc"
#include "markdata.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
// Redraw - Benachrichtigungen
@@ -642,7 +642,7 @@ void ScDocShell::ExecuteChangeCommentDialog( ScChangeAction* pAction, vcl::Windo
aSet.Put( SvxPostItAuthorItem( aAuthor, SID_ATTR_POSTIT_AUTHOR ) );
aSet.Put( SvxPostItDateItem ( aDate, SID_ATTR_POSTIT_DATE ) );
- boost::scoped_ptr<ScRedComDialog> pDlg(new ScRedComDialog( pParent, aSet,this,pAction,bPrevNext));
+ std::unique_ptr<ScRedComDialog> pDlg(new ScRedComDialog( pParent, aSet,this,pAction,bPrevNext));
pDlg->Execute();
}
diff --git a/sc/source/ui/docshell/docsh4.cxx b/sc/source/ui/docshell/docsh4.cxx
index b422a5150163..1b74471c2cdc 100644
--- a/sc/source/ui/docshell/docsh4.cxx
+++ b/sc/source/ui/docshell/docsh4.cxx
@@ -98,7 +98,7 @@ using namespace ::com::sun::star;
#include "conditio.hxx"
#include "sheetevents.hxx"
#include <documentlinkmgr.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#define IS_SHARE_HEADER(set) \
static_cast<const SfxBoolItem&>( \
@@ -326,7 +326,7 @@ void ScDocShell::Execute( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScColRowLabelDlg> pDlg(pFact->CreateScColRowLabelDlg(pParent, bRowHeaders, bColHeaders));
+ std::unique_ptr<AbstractScColRowLabelDlg> pDlg(pFact->CreateScColRowLabelDlg(pParent, bRowHeaders, bColHeaders));
OSL_ENSURE(pDlg, "Dialog create fail!");
if ( pDlg->Execute() == RET_OK )
{
@@ -872,7 +872,7 @@ void ScDocShell::Execute( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScNewScenarioDlg> pNewDlg(pFact->CreateScNewScenarioDlg(GetActiveDialogParent(), aName, true, bSheetProtected));
+ std::unique_ptr<AbstractScNewScenarioDlg> pNewDlg(pFact->CreateScNewScenarioDlg(GetActiveDialogParent(), aName, true, bSheetProtected));
OSL_ENSURE(pNewDlg, "Dialog create fail!");
pNewDlg->SetScenarioData( aName, aComment, aColor, nFlags );
if ( pNewDlg->Execute() == RET_OK )
@@ -1551,7 +1551,7 @@ void ScDocShell::ExecutePageStyle( SfxViewShell& rCaller,
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScStyleDlg( GetActiveDialogParent(), *pStyleSheet, RID_SCDLG_STYLES_PAGE, RID_SCDLG_STYLES_PAGE ));
+ std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScStyleDlg( GetActiveDialogParent(), *pStyleSheet, RID_SCDLG_STYLES_PAGE, RID_SCDLG_STYLES_PAGE ));
OSL_ENSURE(pDlg, "Dialog create fail!");
if ( pDlg->Execute() == RET_OK )
@@ -1706,7 +1706,7 @@ void ScDocShell::ExecutePageStyle( SfxViewShell& rCaller,
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScHFEditDlg( SfxViewFrame::Current(),
+ std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScHFEditDlg( SfxViewFrame::Current(),
GetActiveDialogParent(),
rStyleSet,
aStr,
diff --git a/sc/source/ui/docshell/documentlinkmgr.cxx b/sc/source/ui/docshell/documentlinkmgr.cxx
index 75c2da638bd3..19a8f0953768 100644
--- a/sc/source/ui/docshell/documentlinkmgr.cxx
+++ b/sc/source/ui/docshell/documentlinkmgr.cxx
@@ -27,7 +27,7 @@
#include <vcl/layout.hxx>
#include <boost/noncopyable.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
namespace sc {
@@ -35,11 +35,11 @@ struct DocumentLinkManagerImpl : boost::noncopyable
{
ScDocument& mrDoc;
SfxObjectShell* mpShell;
- boost::scoped_ptr<DataStream> mpDataStream;
- boost::scoped_ptr<sfx2::LinkManager> mpLinkManager;
+ std::unique_ptr<DataStream> mpDataStream;
+ std::unique_ptr<sfx2::LinkManager> mpLinkManager;
DocumentLinkManagerImpl( ScDocument& rDoc, SfxObjectShell* pShell ) :
- mrDoc(rDoc), mpShell(pShell), mpDataStream(NULL), mpLinkManager(NULL) {}
+ mrDoc(rDoc), mpShell(pShell), mpDataStream(nullptr), mpLinkManager(nullptr) {}
~DocumentLinkManagerImpl()
{
diff --git a/sc/source/ui/docshell/externalrefmgr.cxx b/sc/source/ui/docshell/externalrefmgr.cxx
index 96d174308807..5b7dcb5a79c3 100644
--- a/sc/source/ui/docshell/externalrefmgr.cxx
+++ b/sc/source/ui/docshell/externalrefmgr.cxx
@@ -59,8 +59,6 @@
#include <memory>
#include <algorithm>
-#include <boost/scoped_ptr.hpp>
-
using ::std::unique_ptr;
using ::com::sun::star::uno::Any;
using ::std::vector;
@@ -599,7 +597,7 @@ ScExternalRefCache::TokenArrayRef ScExternalRefCache::getCellRangeData(
// Cache hit!
return itrRange->second;
- ::boost::scoped_ptr<ScRange> pNewRange;
+ std::unique_ptr<ScRange> pNewRange;
TokenArrayRef pArray;
bool bFirstTab = true;
for (size_t nTab = nTabFirstId; nTab <= nTabLastId; ++nTab)
@@ -1468,7 +1466,7 @@ static ScTokenArray* convertToTokenArray(
// range to it.
return NULL;
- ::boost::scoped_ptr<ScRange> pUsedRange;
+ std::unique_ptr<ScRange> pUsedRange;
unique_ptr<ScTokenArray> pArray(new ScTokenArray);
bool bFirstTab = true;
diff --git a/sc/source/ui/docshell/impex.cxx b/sc/source/ui/docshell/impex.cxx
index da82e0b5df16..4feaccc3af15 100644
--- a/sc/source/ui/docshell/impex.cxx
+++ b/sc/source/ui/docshell/impex.cxx
@@ -54,7 +54,7 @@
#include "globstr.hrc"
#include <vcl/svapp.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
// We don't want to end up with 2GB read in one line just because of malformed
// multiline fields, so chop it _somewhere_, which is twice supported columns
@@ -1266,7 +1266,7 @@ bool ScImportExport::ExtText2Doc( SvStream& rStrm )
sal_uInt64 const nOldPos = rStrm.Tell();
sal_uInt64 const nRemaining = rStrm.remainingSize();
- boost::scoped_ptr<ScProgress> xProgress( new ScProgress( pDocSh,
+ std::unique_ptr<ScProgress> xProgress( new ScProgress( pDocSh,
ScGlobal::GetRscString( STR_LOAD_DOC ), nRemaining ));
rStrm.StartReadingUnicodeText( rStrm.GetStreamCharSet() );
@@ -1295,8 +1295,8 @@ bool ScImportExport::ExtText2Doc( SvStream& rStrm )
CalendarWrapper aCalendar( comphelper::getProcessComponentContext() );
aCalendar.loadDefaultCalendar(
LanguageTag::convertToLocale( eDocLang ) );
- boost::scoped_ptr< ::utl::TransliterationWrapper > pEnglishTransliteration;
- boost::scoped_ptr< CalendarWrapper > pEnglishCalendar;
+ std::unique_ptr< ::utl::TransliterationWrapper > pEnglishTransliteration;
+ std::unique_ptr< CalendarWrapper > pEnglishCalendar;
if ( eDocLang != LANGUAGE_ENGLISH_US )
{
pEnglishTransliteration.reset(new ::utl::TransliterationWrapper (
diff --git a/sc/source/ui/drawfunc/drawsh.cxx b/sc/source/ui/drawfunc/drawsh.cxx
index 3958b3745709..dd8303e809e8 100644
--- a/sc/source/ui/drawfunc/drawsh.cxx
+++ b/sc/source/ui/drawfunc/drawsh.cxx
@@ -58,7 +58,7 @@
#include <sfx2/viewsh.hxx>
#include <com/sun/star/util/XModifiable.hpp>
#include <com/sun/star/frame/XFrame.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
TYPEINIT1( ScDrawShell, SfxShell );
@@ -263,7 +263,7 @@ void ScDrawShell::ExecDrawAttr( SfxRequest& rReq )
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
if ( pFact )
{
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateCaptionDialog( pWin, pView ));
+ std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateCaptionDialog( pWin, pView ));
const sal_uInt16* pRange = pDlg->GetInputRanges( *aNewAttr.GetPool() );
SfxItemSet aCombSet( *aNewAttr.GetPool(), pRange );
@@ -285,7 +285,7 @@ void ScDrawShell::ExecDrawAttr( SfxRequest& rReq )
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
if(pFact)
{
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateSvxTransformTabDialog( pWin, &aNewAttr,pView ));
+ std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateSvxTransformTabDialog( pWin, &aNewAttr,pView ));
OSL_ENSURE(pDlg, "Dialog creation failed!");
if (pDlg->Execute() == RET_OK)
{
@@ -334,7 +334,7 @@ void ScDrawShell::ExecuteMacroAssign( SdrObject* pObj, vcl::Window* pWin )
}
// create empty itemset for macro-dlg
- boost::scoped_ptr<SfxItemSet> pItemSet(new SfxItemSet(SfxGetpApp()->GetPool(), SID_ATTR_MACROITEM, SID_ATTR_MACROITEM, SID_EVENTCONFIG, SID_EVENTCONFIG, 0 ));
+ std::unique_ptr<SfxItemSet> pItemSet(new SfxItemSet(SfxGetpApp()->GetPool(), SID_ATTR_MACROITEM, SID_ATTR_MACROITEM, SID_EVENTCONFIG, SID_EVENTCONFIG, 0 ));
pItemSet->Put ( aItem, SID_ATTR_MACROITEM );
SfxEventNamesItem aNamesItem(SID_EVENTCONFIG);
@@ -346,7 +346,7 @@ void ScDrawShell::ExecuteMacroAssign( SdrObject* pObj, vcl::Window* pWin )
xFrame = GetViewShell()->GetViewFrame()->GetFrame().GetFrameInterface();
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
- boost::scoped_ptr<SfxAbstractDialog> pMacroDlg(pFact->CreateSfxDialog( pWin, *pItemSet, xFrame, SID_EVENTCONFIG ));
+ std::unique_ptr<SfxAbstractDialog> pMacroDlg(pFact->CreateSfxDialog( pWin, *pItemSet, xFrame, SID_EVENTCONFIG ));
if ( pMacroDlg && pMacroDlg->Execute() == RET_OK )
{
const SfxItemSet* pOutSet = pMacroDlg->GetOutputItemSet();
@@ -391,7 +391,7 @@ void ScDrawShell::ExecuteLineDlg( SfxRequest& rReq, sal_uInt16 nTabPage )
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "Dialog creation failed!");
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateSvxLineTabDialog( pViewData->GetDialogParent(),
+ std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateSvxLineTabDialog( pViewData->GetDialogParent(),
&aNewAttr,
pViewData->GetDocument()->GetDrawLayer(),
pObj,
@@ -422,7 +422,7 @@ void ScDrawShell::ExecuteAreaDlg( SfxRequest& rReq, sal_uInt16 nTabPage )
pView->MergeAttrFromMarked( aNewAttr, false );
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
- boost::scoped_ptr<AbstractSvxAreaTabDialog> pDlg(pFact->CreateSvxAreaTabDialog(
+ std::unique_ptr<AbstractSvxAreaTabDialog> pDlg(pFact->CreateSvxAreaTabDialog(
pViewData->GetDialogParent(), &aNewAttr,
pViewData->GetDocument()->GetDrawLayer(), true));
@@ -451,7 +451,7 @@ void ScDrawShell::ExecuteTextAttrDlg( SfxRequest& rReq, sal_uInt16 /* nTabPage *
pView->MergeAttrFromMarked( aNewAttr, false );
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateTextTabDialog( pViewData->GetDialogParent(), &aNewAttr, pView ));
+ std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateTextTabDialog( pViewData->GetDialogParent(), &aNewAttr, pView ));
sal_uInt16 nResult = pDlg->Execute();
diff --git a/sc/source/ui/drawfunc/drawsh5.cxx b/sc/source/ui/drawfunc/drawsh5.cxx
index 772dabbed720..d3f2dad76446 100644
--- a/sc/source/ui/drawfunc/drawsh5.cxx
+++ b/sc/source/ui/drawfunc/drawsh5.cxx
@@ -56,7 +56,7 @@
#include "userdat.hxx"
#include "postit.hxx"
#include "drtxtob.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include "sc.hrc"
@@ -487,7 +487,7 @@ void ScDrawShell::ExecDrawFunc( SfxRequest& rReq )
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "Dialog creation failed!");
- boost::scoped_ptr<AbstractSvxObjectNameDialog> pDlg(pFact->CreateSvxObjectNameDialog(NULL, aName));
+ std::unique_ptr<AbstractSvxObjectNameDialog> pDlg(pFact->CreateSvxObjectNameDialog(NULL, aName));
OSL_ENSURE(pDlg, "Dialog creation failed!");
pDlg->SetCheckNameHdl(LINK(this, ScDrawShell, NameObjectHdl));
@@ -556,7 +556,7 @@ void ScDrawShell::ExecDrawFunc( SfxRequest& rReq )
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "Dialog creation failed!");
- boost::scoped_ptr<AbstractSvxObjectTitleDescDialog> pDlg(pFact->CreateSvxObjectTitleDescDialog(NULL, aTitle, aDescription));
+ std::unique_ptr<AbstractSvxObjectTitleDescDialog> pDlg(pFact->CreateSvxObjectTitleDescDialog(NULL, aTitle, aDescription));
OSL_ENSURE(pDlg, "Dialog creation failed!");
if(RET_OK == pDlg->Execute())
diff --git a/sc/source/ui/drawfunc/drtxtob.cxx b/sc/source/ui/drawfunc/drtxtob.cxx
index e74c17fca932..04b9d34dc68c 100644
--- a/sc/source/ui/drawfunc/drtxtob.cxx
+++ b/sc/source/ui/drawfunc/drtxtob.cxx
@@ -79,7 +79,7 @@
#define ScDrawTextObjectBar
#include "scslots.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace ::com::sun::star;
@@ -876,7 +876,7 @@ void ScDrawTextObjectBar::ExecuteAttr( SfxRequest &rReq )
case SID_DRAWTEXT_ATTR_DLG:
{
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateTextTabDialog( pViewData->GetDialogParent(), &aEditAttr, pView ));
+ std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateTextTabDialog( pViewData->GetDialogParent(), &aEditAttr, pView ));
bDone = ( RET_OK == pDlg->Execute() );
diff --git a/sc/source/ui/drawfunc/drtxtob1.cxx b/sc/source/ui/drawfunc/drtxtob1.cxx
index 1c03ba30758d..1c066228c92b 100644
--- a/sc/source/ui/drawfunc/drtxtob1.cxx
+++ b/sc/source/ui/drawfunc/drtxtob1.cxx
@@ -39,7 +39,7 @@
#include <gridwin.hxx>
#include "scabstdlg.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
bool ScDrawTextObjectBar::ExecuteCharDlg( const SfxItemSet& rArgs,
SfxItemSet& rOutSet , sal_uInt16 nSlot)
@@ -47,7 +47,7 @@ bool ScDrawTextObjectBar::ExecuteCharDlg( const SfxItemSet& rArgs,
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
assert(pFact && "ScAbstractFactory create fail!");
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScCharDlg(
+ std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScCharDlg(
pViewData->GetDialogParent(), &rArgs,
pViewData->GetSfxDocShell()));
assert(pDlg && "Dialog create fail!");
@@ -94,7 +94,7 @@ bool ScDrawTextObjectBar::ExecuteParaDlg( const SfxItemSet& rArgs,
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScParagraphDlg(
+ std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScParagraphDlg(
pViewData->GetDialogParent(), &aNewAttr));
OSL_ENSURE(pDlg, "Dialog create fail!");
bool bRet = ( pDlg->Execute() == RET_OK );
@@ -114,7 +114,7 @@ void ScDrawTextObjectBar::ExecutePasteContents( SfxRequest & /* rReq */ )
SdrView* pView = pViewData->GetScDrawView();
OutlinerView* pOutView = pView->GetTextEditOutlinerView();
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
- boost::scoped_ptr<SfxAbstractPasteDialog> pDlg(pFact->CreatePasteDialog( pViewData->GetDialogParent() ));
+ std::unique_ptr<SfxAbstractPasteDialog> pDlg(pFact->CreatePasteDialog( pViewData->GetDialogParent() ));
pDlg->Insert( SotClipboardFormatId::STRING, EMPTY_OUSTRING );
pDlg->Insert( SotClipboardFormatId::RTF, EMPTY_OUSTRING );
diff --git a/sc/source/ui/drawfunc/fuins2.cxx b/sc/source/ui/drawfunc/fuins2.cxx
index 03c8720b94e5..02c5ecca76fb 100644
--- a/sc/source/ui/drawfunc/fuins2.cxx
+++ b/sc/source/ui/drawfunc/fuins2.cxx
@@ -80,7 +80,7 @@ using namespace ::com::sun::star;
#include "drawview.hxx"
#include "markdata.hxx"
#include "gridwin.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
namespace {
@@ -242,7 +242,7 @@ FuInsertOLE::FuInsertOLE(ScTabViewShell* pViewSh, vcl::Window* pWin, ScDrawView*
case SID_INSERT_FLOATINGFRAME :
{
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
- boost::scoped_ptr<SfxAbstractInsertObjectDialog> pDlg(
+ std::unique_ptr<SfxAbstractInsertObjectDialog> pDlg(
pFact->CreateInsertObjectDialog( pViewShell->GetWindow(), SC_MOD()->GetSlotPool()->GetSlot(nSlot)->GetCommandString(),
xStorage, &aServerLst ));
if ( pDlg )
diff --git a/sc/source/ui/drawfunc/mediash.cxx b/sc/source/ui/drawfunc/mediash.cxx
index 13cd9597749e..17d3dd569e43 100644
--- a/sc/source/ui/drawfunc/mediash.cxx
+++ b/sc/source/ui/drawfunc/mediash.cxx
@@ -71,7 +71,7 @@ void ScMediaShell::GetMediaState( SfxItemSet& rSet )
{
if( SID_AVMEDIA_TOOLBOX == nWhich )
{
- boost::scoped_ptr<SdrMarkList> pMarkList(new SdrMarkList( pView->GetMarkedObjectList() ));
+ std::unique_ptr<SdrMarkList> pMarkList(new SdrMarkList( pView->GetMarkedObjectList() ));
bool bDisable = true;
if( 1 == pMarkList->GetMarkCount() )
@@ -111,7 +111,7 @@ void ScMediaShell::ExecuteMedia( SfxRequest& rReq )
if( pItem )
{
- boost::scoped_ptr<SdrMarkList> pMarkList(new SdrMarkList( pView->GetMarkedObjectList() ));
+ std::unique_ptr<SdrMarkList> pMarkList(new SdrMarkList( pView->GetMarkedObjectList() ));
if( 1 == pMarkList->GetMarkCount() )
{
diff --git a/sc/source/ui/formdlg/formula.cxx b/sc/source/ui/formdlg/formula.cxx
index ba871d415bb3..b2ae1297d81e 100644
--- a/sc/source/ui/formdlg/formula.cxx
+++ b/sc/source/ui/formdlg/formula.cxx
@@ -308,7 +308,7 @@ bool ScFormulaDlg::Close()
bool ScFormulaDlg::calculateValue( const OUString& rStrExp, OUString& rStrResult )
{
- boost::scoped_ptr<ScSimpleFormulaCalculator> pFCell( new ScSimpleFormulaCalculator( pDoc, aCursorPos, rStrExp ) );
+ std::unique_ptr<ScSimpleFormulaCalculator> pFCell( new ScSimpleFormulaCalculator( pDoc, aCursorPos, rStrExp ) );
pFCell->SetLimitString(true);
// HACK! to avoid neither #REF! from ColRowNames
diff --git a/sc/source/ui/inc/checklistmenu.hxx b/sc/source/ui/inc/checklistmenu.hxx
index f3289aa2e640..d7e5c798c916 100644
--- a/sc/source/ui/inc/checklistmenu.hxx
+++ b/sc/source/ui/inc/checklistmenu.hxx
@@ -17,7 +17,7 @@
#include <vcl/timer.hxx>
#include <svx/checklbx.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include <unordered_map>
namespace com { namespace sun { namespace star {
@@ -150,13 +150,13 @@ private:
bool mbEnabled:1;
bool mbSeparator:1;
- ::boost::shared_ptr<Action> mpAction;
+ std::shared_ptr<Action> mpAction;
VclPtr<ScMenuFloatingWindow> mpSubMenuWin;
MenuItemData();
};
- ::std::vector<MenuItemData> maMenuItems;
+ std::vector<MenuItemData> maMenuItems;
struct SubMenuItemData
{
@@ -345,13 +345,13 @@ private:
VclPtr<OKButton> maBtnOk;
VclPtr<CancelButton> maBtnCancel;
- ::std::vector<VclPtr<vcl::Window> > maTabStopCtrls;
+ std::vector<VclPtr<vcl::Window> > maTabStopCtrls;
size_t mnCurTabStop;
- ::std::vector<Member> maMembers;
- boost::scoped_ptr<ExtendedData> mpExtendedData;
- boost::scoped_ptr<Action> mpOKAction;
- boost::scoped_ptr<Action> mpPopupEndAction;
+ std::vector<Member> maMembers;
+ std::unique_ptr<ExtendedData> mpExtendedData;
+ std::unique_ptr<Action> mpOKAction;
+ std::unique_ptr<Action> mpPopupEndAction;
Config maConfig;
Size maWndSize; /// whole window size.
diff --git a/sc/source/ui/inc/condformatdlgentry.hxx b/sc/source/ui/inc/condformatdlgentry.hxx
index 814e366f9598..3fd588dee14f 100644
--- a/sc/source/ui/inc/condformatdlgentry.hxx
+++ b/sc/source/ui/inc/condformatdlgentry.hxx
@@ -235,7 +235,7 @@ class ScDataBarFrmtEntry : public ScCondFrmtEntry
VclPtr<PushButton> maBtOptions;
- boost::scoped_ptr<ScDataBarFormatData> mpDataBarData;
+ std::unique_ptr<ScDataBarFormatData> mpDataBarData;
ScFormatEntry* createDatabarEntry() const;
diff --git a/sc/source/ui/inc/datastream.hxx b/sc/source/ui/inc/datastream.hxx
index e962b61aa78c..48323642f207 100644
--- a/sc/source/ui/inc/datastream.hxx
+++ b/sc/source/ui/inc/datastream.hxx
@@ -18,7 +18,6 @@
#include <address.hxx>
#include <boost/noncopyable.hpp>
-#include <boost/scoped_ptr.hpp>
#include <vector>
#include <documentstreamaccess.hxx>
diff --git a/sc/source/ui/inc/docfuncutil.hxx b/sc/source/ui/inc/docfuncutil.hxx
index 65bf820526be..e1db8ce58c35 100644
--- a/sc/source/ui/inc/docfuncutil.hxx
+++ b/sc/source/ui/inc/docfuncutil.hxx
@@ -10,7 +10,7 @@
#include <undobase.hxx>
-#include <boost/shared_ptr.hpp>
+#include <memory>
class ScDocument;
class ScMarkData;
@@ -32,7 +32,7 @@ public:
static void addDeleteContentsUndo(
svl::IUndoManager* pUndoMgr, ScDocShell* pDocSh, const ScMarkData& rMark,
const ScRange& rRange, ScDocument* pUndoDoc, InsertDeleteFlags nFlags,
- const boost::shared_ptr<ScSimpleUndo::DataSpansType>& pSpans,
+ const std::shared_ptr<ScSimpleUndo::DataSpansType>& pSpans,
bool bMulti, bool bDrawUndo );
static ScSimpleUndo::DataSpansType* getNonEmptyCellSpans(
diff --git a/sc/source/ui/inc/docsh.hxx b/sc/source/ui/inc/docsh.hxx
index 5d6b5b87d1bb..0b5fdcdecc95 100644
--- a/sc/source/ui/inc/docsh.hxx
+++ b/sc/source/ui/inc/docsh.hxx
@@ -35,8 +35,8 @@
#include "optutil.hxx"
#include "docuno.hxx"
-#include <boost/scoped_ptr.hpp>
#include <config_telepathy.h>
+#include <memory>
#include <unordered_map>
class ScRefreshTimerProtector;
@@ -453,7 +453,7 @@ typedef tools::SvRef<ScDocShell> ScDocShellRef;
class SC_DLLPUBLIC ScDocShellModificator
{
ScDocShell& rDocShell;
- boost::scoped_ptr<ScRefreshTimerProtector> mpProtector;
+ std::unique_ptr<ScRefreshTimerProtector> mpProtector;
bool bAutoCalcShellDisabled;
bool bIdleEnabled;
diff --git a/sc/source/ui/inc/filtdlg.hxx b/sc/source/ui/inc/filtdlg.hxx
index 92ed9bba988e..f01e1feeda5a 100644
--- a/sc/source/ui/inc/filtdlg.hxx
+++ b/sc/source/ui/inc/filtdlg.hxx
@@ -36,7 +36,6 @@
#include <map>
#include <boost/ptr_container/ptr_map.hpp>
#include <boost/noncopyable.hpp>
-#include <boost/scoped_ptr.hpp>
class ScFilterOptionsMgr;
class ScViewData;
diff --git a/sc/source/ui/inc/pvfundlg.hxx b/sc/source/ui/inc/pvfundlg.hxx
index 83350a8fb948..ce2b8b6cbe68 100644
--- a/sc/source/ui/inc/pvfundlg.hxx
+++ b/sc/source/ui/inc/pvfundlg.hxx
@@ -35,7 +35,7 @@
#include <sfx2/itemconnect.hxx>
#include "pivot.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include <unordered_map>
typedef sfx::ListBoxWrapper< sal_Int32 > ScDPListBoxWrapper;
@@ -90,7 +90,7 @@ private:
NameMapType maBaseFieldNameMap; // cache for base field display -> original name.
NameMapType maBaseItemNameMap; // cache for base item display -> original name.
- boost::scoped_ptr<ScDPListBoxWrapper> mxLbTypeWrp; /// Wrapper for direct usage of API constants.
+ std::unique_ptr<ScDPListBoxWrapper> mxLbTypeWrp; /// Wrapper for direct usage of API constants.
const ScDPLabelDataVector& mrLabelVec; /// Data of all labels.
bool mbEmptyItem; /// true = Empty base item in listbox.
@@ -176,8 +176,8 @@ private:
VclPtr<FixedText> m_pFtHierarchy;
VclPtr<ListBox> m_pLbHierarchy;
- boost::scoped_ptr<ScDPListBoxWrapper> m_xLbLayoutWrp; /// Wrapper for direct usage of API constants.
- boost::scoped_ptr<ScDPListBoxWrapper> m_xLbShowFromWrp; /// Wrapper for direct usage of API constants.
+ std::unique_ptr<ScDPListBoxWrapper> m_xLbLayoutWrp; /// Wrapper for direct usage of API constants.
+ std::unique_ptr<ScDPListBoxWrapper> m_xLbShowFromWrp; /// Wrapper for direct usage of API constants.
ScDPObject& mrDPObj; /// The DataPilot object (for member names).
ScDPLabelData maLabelData; /// Cache for members data.
diff --git a/sc/source/ui/inc/retypepassdlg.hxx b/sc/source/ui/inc/retypepassdlg.hxx
index 19cc33ebec57..93a895c4c68f 100644
--- a/sc/source/ui/inc/retypepassdlg.hxx
+++ b/sc/source/ui/inc/retypepassdlg.hxx
@@ -31,7 +31,7 @@
#include "tabprotection.hxx"
-#include <boost/shared_ptr.hpp>
+#include <memory>
namespace vcl { class Window; }
class ScDocProtection;
@@ -41,8 +41,8 @@ class ScDocument;
class ScRetypePassDlg : public ModalDialog
{
public:
- typedef ::boost::shared_ptr<ScDocProtection> DocProtectionPtr;
- typedef ::boost::shared_ptr<ScTableProtection> TabProtectionPtr;
+ typedef std::shared_ptr<ScDocProtection> DocProtectionPtr;
+ typedef std::shared_ptr<ScTableProtection> TabProtectionPtr;
explicit ScRetypePassDlg(vcl::Window* pParent);
virtual ~ScRetypePassDlg();
diff --git a/sc/source/ui/inc/tabview.hxx b/sc/source/ui/inc/tabview.hxx
index 5e3ea93c2cd5..e207569c49a0 100644
--- a/sc/source/ui/inc/tabview.hxx
+++ b/sc/source/ui/inc/tabview.hxx
@@ -30,7 +30,6 @@
#include "drawview.hxx"
#include <boost/noncopyable.hpp>
-#include <boost/scoped_ptr.hpp>
namespace editeng {
struct MisspellRanges;
diff --git a/sc/source/ui/inc/uiitems.hxx b/sc/source/ui/inc/uiitems.hxx
index 779375140ce3..56b70aa13037 100644
--- a/sc/source/ui/inc/uiitems.hxx
+++ b/sc/source/ui/inc/uiitems.hxx
@@ -27,8 +27,8 @@
#include "paramisc.hxx"
#include <svl/poolitem.hxx>
+#include <memory>
#include <vector>
-#include <boost/scoped_ptr.hpp>
namespace editeng {
struct MisspellRanges;
@@ -177,7 +177,7 @@ public:
void SetAdvancedQuerySource(const ScRange* pSource);
private:
- boost::scoped_ptr<ScQueryParam> mpQueryData;
+ std::unique_ptr<ScQueryParam> mpQueryData;
ScViewData* pViewData;
ScRange aAdvSource;
bool bIsAdvanced;
diff --git a/sc/source/ui/inc/undoblk.hxx b/sc/source/ui/inc/undoblk.hxx
index e19ade3db28c..53111f41f997 100644
--- a/sc/source/ui/inc/undoblk.hxx
+++ b/sc/source/ui/inc/undoblk.hxx
@@ -26,8 +26,7 @@
#include "cellmergeoption.hxx"
#include "paramisc.hxx"
-#include <boost/shared_ptr.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
class ScDocShell;
class ScDocument;
@@ -267,10 +266,10 @@ public:
virtual OUString GetComment() const SAL_OVERRIDE;
- void SetDataSpans( const boost::shared_ptr<DataSpansType>& pSpans );
+ void SetDataSpans( const std::shared_ptr<DataSpansType>& pSpans );
private:
- boost::shared_ptr<DataSpansType> mpDataSpans; // Spans of non-empty cells.
+ std::shared_ptr<DataSpansType> mpDataSpans; // Spans of non-empty cells.
ScRange aRange;
ScMarkData aMarkData;
@@ -346,7 +345,7 @@ public:
private:
ScMarkData aMarkData;
ScRange aRange;
- boost::scoped_ptr<ScEditDataArray> mpDataArray;
+ std::unique_ptr<ScEditDataArray> mpDataArray;
ScDocument* pUndoDoc;
bool bMulti;
ScPatternAttr* pApplyPattern;
@@ -641,8 +640,8 @@ public:
private:
void DoChange(ScDocument* pDoc);
- boost::scoped_ptr<ScDocument> mpUndoDoc;
- boost::scoped_ptr<ScDocument> mpRedoDoc;
+ std::unique_ptr<ScDocument> mpUndoDoc;
+ std::unique_ptr<ScDocument> mpRedoDoc;
ScRange maRange;
};
diff --git a/sc/source/ui/inc/undocell.hxx b/sc/source/ui/inc/undocell.hxx
index edce6bc1f22b..1f55708cbdfb 100644
--- a/sc/source/ui/inc/undocell.hxx
+++ b/sc/source/ui/inc/undocell.hxx
@@ -25,8 +25,7 @@
#include "cellvalue.hxx"
#include <cellvalues.hxx>
-#include <boost/shared_ptr.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
class ScDocShell;
class ScPatternAttr;
@@ -72,11 +71,11 @@ private:
ScPatternAttr* pOldPattern;
ScPatternAttr* pNewPattern;
ScPatternAttr* pApplyPattern;
- ::boost::shared_ptr<EditTextObject> pOldEditData;
- ::boost::shared_ptr<EditTextObject> pNewEditData;
+ std::shared_ptr<EditTextObject> pOldEditData;
+ std::shared_ptr<EditTextObject> pNewEditData;
bool bIsAutomatic;
- void DoChange( const ScPatternAttr* pWhichPattern, const ::boost::shared_ptr<EditTextObject>& pEditData ) const;
+ void DoChange( const ScPatternAttr* pWhichPattern, const std::shared_ptr<EditTextObject>& pEditData ) const;
};
class ScUndoEnterData: public ScSimpleUndo
@@ -113,7 +112,7 @@ private:
ValuesType maOldValues;
OUString maNewString;
- boost::scoped_ptr<EditTextObject> mpNewEditData;
+ std::unique_ptr<EditTextObject> mpNewEditData;
sal_uLong mnEndChangeAction;
ScAddress maPos;
diff --git a/sc/source/ui/inc/undodat.hxx b/sc/source/ui/inc/undodat.hxx
index c9c3060afb0f..0bfa865a5707 100644
--- a/sc/source/ui/inc/undodat.hxx
+++ b/sc/source/ui/inc/undodat.hxx
@@ -28,7 +28,7 @@
#include "subtotalparam.hxx"
#include "pivot.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
class ScDocShell;
class ScDocument;
@@ -469,7 +469,7 @@ public:
virtual OUString GetComment() const SAL_OVERRIDE;
private:
- boost::scoped_ptr<ScMarkData> mpMarkData;
+ std::unique_ptr<ScMarkData> mpMarkData;
ScDocument* pUndoDoc;
ScDocument* pRedoDoc;
InsertDeleteFlags nFlags;
diff --git a/sc/source/ui/inc/undotab.hxx b/sc/source/ui/inc/undotab.hxx
index fe43d95b16e3..e5234961177e 100644
--- a/sc/source/ui/inc/undotab.hxx
+++ b/sc/source/ui/inc/undotab.hxx
@@ -27,8 +27,7 @@
#include <com/sun/star/uno/Sequence.hxx>
-#include <boost/shared_ptr.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include <memory>
#include <vector>
@@ -171,10 +170,10 @@ public:
virtual OUString GetComment() const SAL_OVERRIDE;
private:
- ::boost::shared_ptr< ::std::vector<SCTAB> > mpOldTabs;
- ::boost::shared_ptr< ::std::vector<SCTAB> > mpNewTabs;
- ::boost::shared_ptr< ::std::vector< OUString> > mpOldNames;
- ::boost::shared_ptr< ::std::vector< OUString> > mpNewNames;
+ std::shared_ptr< ::std::vector<SCTAB> > mpOldTabs;
+ std::shared_ptr< ::std::vector<SCTAB> > mpNewTabs;
+ std::shared_ptr< ::std::vector< OUString> > mpOldNames;
+ std::shared_ptr< ::std::vector< OUString> > mpNewNames;
void DoChange( bool bUndo ) const;
};
@@ -199,9 +198,9 @@ public:
virtual OUString GetComment() const SAL_OVERRIDE;
private:
- ::boost::shared_ptr< ::std::vector<SCTAB> > mpOldTabs;
- ::boost::shared_ptr< ::std::vector<SCTAB> > mpNewTabs;
- ::boost::shared_ptr< ::std::vector< OUString> > mpNewNames;
+ std::shared_ptr< ::std::vector<SCTAB> > mpOldTabs;
+ std::shared_ptr< ::std::vector<SCTAB> > mpNewTabs;
+ std::shared_ptr< ::std::vector< OUString> > mpNewNames;
SdrUndoAction* pDrawUndo;
void DoChange() const;
@@ -254,7 +253,7 @@ public:
virtual OUString GetComment() const SAL_OVERRIDE;
private:
- boost::scoped_ptr<ScMarkData> mpMarkData;
+ std::unique_ptr<ScMarkData> mpMarkData;
SCTAB nSrcTab;
SCTAB nDestTab;
OUString aName;
diff --git a/sc/source/ui/inc/viewdata.hxx b/sc/source/ui/inc/viewdata.hxx
index 39fb5b2e151d..3cecc6eea274 100644
--- a/sc/source/ui/inc/viewdata.hxx
+++ b/sc/source/ui/inc/viewdata.hxx
@@ -25,7 +25,7 @@
#include "viewopti.hxx"
#include "docsh.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#define SC_SIZE_NONE 65535
const SCCOL SC_TABSTART_NONE = SCCOL_MAX;
@@ -157,7 +157,7 @@ private:
double nPPTX, nPPTY; // Scaling factors
::std::vector<ScViewDataTable*> maTabData;
- boost::scoped_ptr<ScMarkData> mpMarkData;
+ std::unique_ptr<ScMarkData> mpMarkData;
ScViewDataTable* pThisTab; // Data of the displayed sheet
ScDocShell* pDocShell;
ScDocument* pDoc;
diff --git a/sc/source/ui/inc/xmlsourcedlg.hxx b/sc/source/ui/inc/xmlsourcedlg.hxx
index 540c5a2ad49c..6c5e4f0aed33 100644
--- a/sc/source/ui/inc/xmlsourcedlg.hxx
+++ b/sc/source/ui/inc/xmlsourcedlg.hxx
@@ -19,8 +19,8 @@
#include "orcusxml.hxx"
#include <set>
+#include <memory>
#include <vector>
-#include <boost/scoped_ptr.hpp>
class ScDocument;
class ScRange;
@@ -47,7 +47,7 @@ class ScXMLSourceDlg : public ScAnyRefDlg
std::set<const SvTreeListEntry*> maRangeLinks;
std::vector<SvTreeListEntry*> maHighlightedEntries;
SvTreeListEntry* mpCurRefEntry;
- boost::scoped_ptr<ScOrcusXMLContext> mpXMLContext;
+ std::unique_ptr<ScOrcusXMLContext> mpXMLContext;
ScDocument* mpDoc;
diff --git a/sc/source/ui/miscdlgs/anyrefdg.cxx b/sc/source/ui/miscdlgs/anyrefdg.cxx
index 28ec44d1b46d..93232fde5e22 100644
--- a/sc/source/ui/miscdlgs/anyrefdg.cxx
+++ b/sc/source/ui/miscdlgs/anyrefdg.cxx
@@ -42,7 +42,7 @@
#include "rangeutl.hxx"
#include "tokenarray.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
ScFormulaReferenceHelper::ScFormulaReferenceHelper(IAnyRefDialog* _pDlg,SfxBindings* _pBindings)
: m_pDlg(_pDlg)
@@ -200,7 +200,7 @@ void ScFormulaReferenceHelper::ShowFormulaReference(const OUString& rStr)
SCTAB nTab = pViewData->GetTabNo();
ScAddress aPos( nCol, nRow, nTab );
- boost::scoped_ptr<ScTokenArray> pScTokA(pRefComp->CompileString(rStr));
+ std::unique_ptr<ScTokenArray> pScTokA(pRefComp->CompileString(rStr));
if (pTabViewShell && pScTokA)
{
diff --git a/sc/source/ui/miscdlgs/scuiautofmt.cxx b/sc/source/ui/miscdlgs/scuiautofmt.cxx
index 13e01eee1988..73ea8a542b18 100644
--- a/sc/source/ui/miscdlgs/scuiautofmt.cxx
+++ b/sc/source/ui/miscdlgs/scuiautofmt.cxx
@@ -47,7 +47,6 @@
#include "scuiautofmt.hxx"
#include "scresid.hxx"
#include "document.hxx"
-#include <boost/scoped_ptr.hpp>
// AutoFormat-Dialog:
diff --git a/sc/source/ui/miscdlgs/tabbgcolordlg.cxx b/sc/source/ui/miscdlgs/tabbgcolordlg.cxx
index fc2373ed8675..60b1d6d9751d 100644
--- a/sc/source/ui/miscdlgs/tabbgcolordlg.cxx
+++ b/sc/source/ui/miscdlgs/tabbgcolordlg.cxx
@@ -33,8 +33,6 @@
#include <editeng/eerdll.hxx>
#include <vcl/builderfactory.hxx>
-#include <boost/scoped_ptr.hpp>
-
#define HDL(hdl) LINK(this,ScTabBgColorDlg,hdl)
ScTabBgColorDlg::ScTabBgColorDlg(vcl::Window* pParent, const OUString& rTitle,
diff --git a/sc/source/ui/pagedlg/scuitphfedit.cxx b/sc/source/ui/pagedlg/scuitphfedit.cxx
index ccd9167799ad..b043dc4ba9cd 100644
--- a/sc/source/ui/pagedlg/scuitphfedit.cxx
+++ b/sc/source/ui/pagedlg/scuitphfedit.cxx
@@ -47,7 +47,7 @@
#include "AccessibleEditObject.hxx"
#include "scuitphfedit.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
// STATIC DATA -----------------------------------------------------------
@@ -327,9 +327,9 @@ void ScHFEditPage::SetSelectDefinedList()
// default to customized
ScHFEntryId eSelectEntry = eEntryCount;
- boost::scoped_ptr< EditTextObject > pLeftObj;
- boost::scoped_ptr< EditTextObject > pCenterObj;
- boost::scoped_ptr< EditTextObject > pRightObj;
+ std::unique_ptr< EditTextObject > pLeftObj;
+ std::unique_ptr< EditTextObject > pCenterObj;
+ std::unique_ptr< EditTextObject > pRightObj;
OUString aLeftEntry;
OUString aCenterEntry;
@@ -524,7 +524,7 @@ bool ScHFEditPage::IsPageEntry(EditEngine*pEngine, EditTextObject* pTextObj)
{
aSel.nStartPos = aSel.nEndPos;
aSel.nEndPos++;
- boost::scoped_ptr< EditTextObject > pPageObj;
+ std::unique_ptr< EditTextObject > pPageObj;
pPageObj.reset(pEngine->CreateTextObject(aSel));
if(pPageObj.get() && pPageObj->IsFieldObject() )
{
@@ -582,7 +582,7 @@ bool ScHFEditPage::IsExtFileNameEntry(EditTextObject* pTextObj)
void ScHFEditPage::ProcessDefinedListSel(ScHFEntryId eSel, bool bTravelling)
{
SvtUserOptions aUserOpt;
- boost::scoped_ptr< EditTextObject > pTextObj;
+ std::unique_ptr< EditTextObject > pTextObj;
switch(eSel)
{
diff --git a/sc/source/ui/pagedlg/tphf.cxx b/sc/source/ui/pagedlg/tphf.cxx
index f629e8bc5bc9..b8bb332aeee4 100644
--- a/sc/source/ui/pagedlg/tphf.cxx
+++ b/sc/source/ui/pagedlg/tphf.cxx
@@ -36,7 +36,7 @@
#include "styledlg.hxx"
#include "scresid.hxx"
#include "scuitphfedit.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
// class ScHFPage
@@ -186,7 +186,7 @@ IMPL_LINK_NOARG_TYPED(ScHFPage, HFEditHdl, void*, void)
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScHFEditDlg(
+ std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScHFEditDlg(
pViewSh->GetViewFrame(), this, aDataSet, aStrPageStyle, nResId));
OSL_ENSURE(pDlg, "Dialog create fail!");
diff --git a/sc/source/ui/pagedlg/tphfedit.cxx b/sc/source/ui/pagedlg/tphfedit.cxx
index 4d907e0c2230..968886e1f1d7 100644
--- a/sc/source/ui/pagedlg/tphfedit.cxx
+++ b/sc/source/ui/pagedlg/tphfedit.cxx
@@ -45,7 +45,7 @@
#include "AccessibleEditObject.hxx"
#include "scabstdlg.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
// STATIC DATA -----------------------------------------------------------
static VclPtr<ScEditWindow> pActiveEdWnd = NULL;
@@ -205,7 +205,7 @@ void ScEditWindow::SetCharAttributes()
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScCharDlg(
+ std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScCharDlg(
GetParent(), &aSet, pDocSh));
OSL_ENSURE(pDlg, "Dialog create fail!");
pDlg->SetText( ScGlobal::GetRscString( STR_TEXTATTRS ) );
diff --git a/sc/source/ui/sidebar/CellAppearancePropertyPanel.hxx b/sc/source/ui/sidebar/CellAppearancePropertyPanel.hxx
index fba7cc26c311..a8ccd98798d7 100644
--- a/sc/source/ui/sidebar/CellAppearancePropertyPanel.hxx
+++ b/sc/source/ui/sidebar/CellAppearancePropertyPanel.hxx
@@ -22,7 +22,7 @@
#include <sfx2/sidebar/ControllerItem.hxx>
#include <sfx2/sidebar/IContextChangeReceiver.hxx>
#include <svx/sidebar/PanelLayout.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
class FixedText;
namespace svx { namespace sidebar {
@@ -83,7 +83,7 @@ private:
VclPtr<ToolBox> mpTBCellBorder;
VclPtr<ToolBox> mpTBLineStyle;
VclPtr<ToolBox> mpTBLineColor;
- ::boost::scoped_ptr< CellBorderUpdater > mpCellBorderUpdater;
+ std::unique_ptr< CellBorderUpdater > mpCellBorderUpdater;
::sfx2::sidebar::ControllerItem maLineStyleControl;
::sfx2::sidebar::ControllerItem maBorderOuterControl;
@@ -133,8 +133,8 @@ private:
bool mbBLTR : 1;
// popups
- ::boost::scoped_ptr< CellLineStylePopup > mpCellLineStylePopup;
- ::boost::scoped_ptr< CellBorderStylePopup > mpCellBorderStylePopup;
+ std::unique_ptr< CellLineStylePopup > mpCellLineStylePopup;
+ std::unique_ptr< CellBorderStylePopup > mpCellBorderStylePopup;
css::uno::Reference<css::frame::XFrame> mxFrame;
::sfx2::sidebar::EnumContext maContext;
diff --git a/sc/source/ui/sidebar/CellBorderStyleControl.cxx b/sc/source/ui/sidebar/CellBorderStyleControl.cxx
index 8a80d4086d3f..7bcb01f535fd 100644
--- a/sc/source/ui/sidebar/CellBorderStyleControl.cxx
+++ b/sc/source/ui/sidebar/CellBorderStyleControl.cxx
@@ -29,7 +29,7 @@
#include <vcl/svapp.hxx>
#include <vcl/settings.hxx>
#include <editeng/lineitem.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
namespace sc { namespace sidebar {
@@ -291,8 +291,8 @@ IMPL_LINK_TYPED(CellBorderStyleControl, TB3SelectHdl, ToolBox *, pToolBox, void)
SvxBoxItem aBorderOuter( SID_ATTR_BORDER_OUTER );
SvxBoxInfoItem aBorderInner( SID_ATTR_BORDER_INNER );
- boost::scoped_ptr<editeng::SvxBorderLine> pTop;
- boost::scoped_ptr<editeng::SvxBorderLine> pBottom;
+ std::unique_ptr<editeng::SvxBorderLine> pTop;
+ std::unique_ptr<editeng::SvxBorderLine> pBottom;
sal_uInt8 nValidFlags = 0;
using namespace ::com::sun::star::table::BorderLineStyle;
diff --git a/sc/source/ui/sidebar/NumberFormatPropertyPanel.hxx b/sc/source/ui/sidebar/NumberFormatPropertyPanel.hxx
index 0a9545936606..efda9627f322 100644
--- a/sc/source/ui/sidebar/NumberFormatPropertyPanel.hxx
+++ b/sc/source/ui/sidebar/NumberFormatPropertyPanel.hxx
@@ -22,7 +22,6 @@
#include <sfx2/sidebar/ControllerItem.hxx>
#include <sfx2/sidebar/IContextChangeReceiver.hxx>
#include <svx/sidebar/PanelLayout.hxx>
-#include <boost/scoped_ptr.hpp>
class FixedText;
class ListBox;
diff --git a/sc/source/ui/undo/undoblk.cxx b/sc/source/ui/undo/undoblk.cxx
index 8748a7b473c5..73346abf6ec2 100644
--- a/sc/source/ui/undo/undoblk.cxx
+++ b/sc/source/ui/undo/undoblk.cxx
@@ -55,8 +55,8 @@
#include <gridwin.hxx>
#include <svl/listener.hxx>
+#include <memory>
#include <set>
-#include <boost/scoped_ptr.hpp>
// STATIC DATA -----------------------------------------------------------
@@ -1360,7 +1360,7 @@ void ScUndoDragDrop::Redo()
BeginRedo();
ScDocument& rDoc = pDocShell->GetDocument();
- boost::scoped_ptr<ScDocument> pClipDoc(new ScDocument( SCDOCMODE_CLIP ));
+ std::unique_ptr<ScDocument> pClipDoc(new ScDocument( SCDOCMODE_CLIP ));
EnableDrawAdjust( &rDoc, false ); //! include in ScBlockUndo?
diff --git a/sc/source/ui/undo/undoblk3.cxx b/sc/source/ui/undo/undoblk3.cxx
index 3d84110e6ed1..b5cc16c67838 100644
--- a/sc/source/ui/undo/undoblk3.cxx
+++ b/sc/source/ui/undo/undoblk3.cxx
@@ -106,7 +106,7 @@ OUString ScUndoDeleteContents::GetComment() const
return ScGlobal::GetRscString( STR_UNDO_DELETECONTENTS ); // "Delete"
}
-void ScUndoDeleteContents::SetDataSpans( const boost::shared_ptr<DataSpansType>& pSpans )
+void ScUndoDeleteContents::SetDataSpans( const std::shared_ptr<DataSpansType>& pSpans )
{
mpDataSpans = pSpans;
}
diff --git a/sc/source/ui/undo/undocell.cxx b/sc/source/ui/undo/undocell.cxx
index 0f260972908c..e90875be756c 100644
--- a/sc/source/ui/undo/undocell.cxx
+++ b/sc/source/ui/undo/undocell.cxx
@@ -45,7 +45,7 @@
#include "docuno.hxx"
#include "stringutil.hxx"
-using ::boost::shared_ptr;
+using std::shared_ptr;
namespace HelperNotifyChanges
{
diff --git a/sc/source/ui/undo/undotab.cxx b/sc/source/ui/undo/undotab.cxx
index f18acd2af3e8..64dd3dd75632 100644
--- a/sc/source/ui/undo/undotab.cxx
+++ b/sc/source/ui/undo/undotab.cxx
@@ -47,9 +47,9 @@
#include "drwlayer.hxx"
#include "scresid.hxx"
+#include <memory>
#include <utility>
#include <vector>
-#include <boost/scoped_ptr.hpp>
extern bool bDrawIsInUndo; // somewhere as member!
@@ -57,7 +57,7 @@ using namespace com::sun::star;
using ::com::sun::star::uno::Sequence;
using ::std::unique_ptr;
using ::std::vector;
-using ::boost::shared_ptr;
+using std::shared_ptr;
TYPEINIT1(ScUndoInsertTab, SfxUndoAction);
TYPEINIT1(ScUndoInsertTables, SfxUndoAction);
@@ -514,7 +514,7 @@ void ScUndoMoveTab::DoChange( bool bUndo ) const
if (bUndo) // UnDo
{
size_t i = mpNewTabs->size();
- boost::scoped_ptr<ScProgress> pProgress(new ScProgress(pDocShell , ScGlobal::GetRscString(STR_UNDO_MOVE_TAB),
+ std::unique_ptr<ScProgress> pProgress(new ScProgress(pDocShell , ScGlobal::GetRscString(STR_UNDO_MOVE_TAB),
i * rDoc.GetCodeCount()));
for (; i > 0; --i)
{
@@ -536,7 +536,7 @@ void ScUndoMoveTab::DoChange( bool bUndo ) const
else
{
size_t n = mpNewTabs->size();
- boost::scoped_ptr<ScProgress> pProgress(new ScProgress(pDocShell , ScGlobal::GetRscString(STR_UNDO_MOVE_TAB),
+ std::unique_ptr<ScProgress> pProgress(new ScProgress(pDocShell , ScGlobal::GetRscString(STR_UNDO_MOVE_TAB),
n * rDoc.GetCodeCount()));
for (size_t i = 0; i < n; ++i)
{
diff --git a/sc/source/ui/unoobj/cellsuno.cxx b/sc/source/ui/unoobj/cellsuno.cxx
index 02638438b5f5..527c7811ed2b 100644
--- a/sc/source/ui/unoobj/cellsuno.cxx
+++ b/sc/source/ui/unoobj/cellsuno.cxx
@@ -131,7 +131,6 @@
#include <list>
#include <memory>
-#include <boost/scoped_ptr.hpp>
using namespace com::sun::star;
@@ -1566,7 +1565,7 @@ void ScCellRangesBase::Notify( SfxBroadcaster&, const SfxHint& rHint )
const ScUpdateRefHint& rRef = static_cast<const ScUpdateRefHint&>(rHint);
ScDocument& rDoc = pDocShell->GetDocument();
- boost::scoped_ptr<ScRangeList> pUndoRanges;
+ std::unique_ptr<ScRangeList> pUndoRanges;
if ( rDoc.HasUnoRefUndo() )
pUndoRanges.reset(new ScRangeList( aRanges ));
@@ -2448,7 +2447,7 @@ void ScCellRangesBase::SetOnePropertyValue( const SfxItemPropertySimpleEntry* pE
formula::FormulaGrammar::GRAM_UNSPECIFIED :
formula::FormulaGrammar::mapAPItoGrammar( bEnglish, bXML));
- boost::scoped_ptr<ScValidationData> pNewData(
+ std::unique_ptr<ScValidationData> pNewData(
pValidObj->CreateValidationData( &rDoc, eGrammar ));
sal_uLong nIndex = rDoc.AddValidationEntry( *pNewData );
pNewData.reset();
@@ -2715,8 +2714,8 @@ void SAL_CALL ScCellRangesBase::setPropertyValues( const uno::Sequence< OUString
}
ScDocument& rDoc = pDocShell->GetDocument();
- boost::scoped_ptr<ScPatternAttr> pOldPattern;
- boost::scoped_ptr<ScPatternAttr> pNewPattern;
+ std::unique_ptr<ScPatternAttr> pOldPattern;
+ std::unique_ptr<ScPatternAttr> pNewPattern;
for(i = 0; i < nCount; i++)
{
@@ -2858,8 +2857,8 @@ uno::Sequence< beans::SetPropertyTolerantFailed > SAL_CALL ScCellRangesBase::set
}
ScDocument& rDoc = pDocShell->GetDocument();
- boost::scoped_ptr<ScPatternAttr> pOldPattern;
- boost::scoped_ptr<ScPatternAttr> pNewPattern;
+ std::unique_ptr<ScPatternAttr> pOldPattern;
+ std::unique_ptr<ScPatternAttr> pNewPattern;
sal_Int32 nFailed(0);
for(i = 0; i < nCount; i++)
@@ -3080,7 +3079,7 @@ uno::Sequence< uno::Sequence<double> > SAL_CALL ScCellRangesBase::getData()
throw(uno::RuntimeException, std::exception)
{
SolarMutexGuard aGuard;
- boost::scoped_ptr<ScMemChart> pMemChart(CreateMemChart_Impl());
+ std::unique_ptr<ScMemChart> pMemChart(CreateMemChart_Impl());
if ( pMemChart )
{
sal_Int32 nColCount = pMemChart->GetColCount();
@@ -3194,7 +3193,7 @@ uno::Sequence<OUString> SAL_CALL ScCellRangesBase::getRowDescriptions()
throw(uno::RuntimeException, std::exception)
{
SolarMutexGuard aGuard;
- boost::scoped_ptr<ScMemChart> pMemChart(CreateMemChart_Impl());
+ std::unique_ptr<ScMemChart> pMemChart(CreateMemChart_Impl());
if ( pMemChart )
{
sal_Int32 nRowCount = static_cast<sal_Int32>(pMemChart->GetRowCount());
@@ -3265,7 +3264,7 @@ uno::Sequence<OUString> SAL_CALL ScCellRangesBase::getColumnDescriptions()
throw(uno::RuntimeException, std::exception)
{
SolarMutexGuard aGuard;
- boost::scoped_ptr<ScMemChart> pMemChart(CreateMemChart_Impl());
+ std::unique_ptr<ScMemChart> pMemChart(CreateMemChart_Impl());
if ( pMemChart )
{
sal_Int32 nColCount = pMemChart->GetColCount();
@@ -4088,7 +4087,7 @@ sal_Int32 SAL_CALL ScCellRangesBase::replaceAll( const uno::Reference<util::XSea
for (; itr != itrEnd && *itr < nTabCount; ++itr)
if ( *itr != nTab && bUndo)
pUndoDoc->AddUndoTab( *itr, *itr );
- boost::scoped_ptr<ScMarkData> pUndoMark;
+ std::unique_ptr<ScMarkData> pUndoMark;
if (bUndo)
pUndoMark.reset(new ScMarkData(aMark));
diff --git a/sc/source/ui/unoobj/chart2uno.cxx b/sc/source/ui/unoobj/chart2uno.cxx
index a2b870c3470f..6335ce6f362a 100644
--- a/sc/source/ui/unoobj/chart2uno.cxx
+++ b/sc/source/ui/unoobj/chart2uno.cxx
@@ -77,7 +77,7 @@ using ::std::vector;
using ::std::list;
using ::std::distance;
using ::std::unary_function;
-using ::boost::shared_ptr;
+using ::std::shared_ptr;
namespace
{
@@ -187,9 +187,9 @@ struct TokenTable : boost::noncopyable
vector<ScTokenRef>* TokenTable::getColRanges(SCCOL nCol) const
{
if (nCol >= mnColCount)
- return NULL;
+ return nullptr;
if( mnRowCount<=0 )
- return NULL;
+ return nullptr;
unique_ptr< vector<ScTokenRef> > pTokens(new vector<ScTokenRef>);
sal_uInt32 nLast = getIndex(nCol, mnRowCount-1);
@@ -208,9 +208,9 @@ vector<ScTokenRef>* TokenTable::getColRanges(SCCOL nCol) const
vector<ScTokenRef>* TokenTable::getRowRanges(SCROW nRow) const
{
if (nRow >= mnRowCount)
- return NULL;
+ return nullptr;
if( mnColCount<=0 )
- return NULL;
+ return nullptr;
unique_ptr< vector<ScTokenRef> > pTokens(new vector<ScTokenRef>);
sal_uInt32 nLast = getIndex(mnColCount-1, nRow);
@@ -367,7 +367,7 @@ Chart2PositionMap::Chart2PositionMap(SCCOL nAllColCount, SCROW nAllRowCount,
FormulaTokenMap::const_iterator it2 = pCol->begin();
for (SCROW nRow = 0; nRow < nAllRowCount; ++nRow)
{
- FormulaToken* pToken = NULL;
+ FormulaToken* pToken = nullptr;
if (it2 != pCol->end())
{
pToken = it2->second;
@@ -448,7 +448,7 @@ class Chart2Positioner : boost::noncopyable
public:
Chart2Positioner(ScDocument* pDoc, const vector<ScTokenRef>& rRefTokens) :
mrRefTokens(rRefTokens),
- mpPositionMap(NULL),
+ mpPositionMap(nullptr),
meGlue(GLUETYPE_NA),
mnStartCol(0),
mnStartRow(0),
@@ -483,7 +483,7 @@ private:
private:
const vector<ScTokenRef>& mrRefTokens;
- boost::scoped_ptr<Chart2PositionMap> mpPositionMap;
+ std::unique_ptr<Chart2PositionMap> mpPositionMap;
GlueType meGlue;
SCCOL mnStartCol;
SCROW mnStartRow;
@@ -714,7 +714,7 @@ void Chart2Positioner::createPositionMap()
bool bNoGlue = (meGlue == GLUETYPE_NONE);
unique_ptr<FormulaTokenMapMap> pCols(new FormulaTokenMapMap);
- FormulaTokenMap* pCol = NULL;
+ FormulaTokenMap* pCol = nullptr;
SCROW nNoGlueRow = 0;
for (vector<ScTokenRef>::const_iterator itr = mrRefTokens.begin(), itrEnd = mrRefTokens.end();
itr != itrEnd; ++itr)
@@ -791,7 +791,7 @@ void Chart2Positioner::createPositionMap()
pCol = pCols->begin()->second;
if (mbDummyUpperLeft)
if (pCol->find(0) == pCol->end())
- (*pCol)[ 0 ] = NULL; // Dummy fuer Beschriftung
+ (*pCol)[ 0 ] = nullptr; // Dummy fuer Beschriftung
nAllRowCount = static_cast<SCSIZE>(pCol->size());
}
@@ -807,7 +807,7 @@ void Chart2Positioner::createPositionMap()
{
pCol = it2->second;
if (pCol->find(nKey) == pCol->end())
- (*pCol)[ nKey ] = NULL;
+ (*pCol)[ nKey ] = nullptr;
}
}
}
@@ -1020,7 +1020,7 @@ void ScChart2DataProvider::Notify( SfxBroadcaster& /*rBC*/, const SfxHint& rHint
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
if ( pSimpleHint && pSimpleHint->GetId() == SFX_HINT_DYING )
{
- m_pDocument = NULL;
+ m_pDocument = nullptr;
}
}
@@ -1521,7 +1521,7 @@ ScChart2DataProvider::createDataSource(
// No chart position map instance. Bail out.
return xResult;
- ScChart2DataSource* pDS = NULL;
+ ScChart2DataSource* pDS = nullptr;
::std::list< Reference< chart2::data::XLabeledDataSequence > > aSeqs;
// Fill Categories
@@ -2415,7 +2415,7 @@ void ScChart2DataSource::Notify( SfxBroadcaster& /*rBC*/, const SfxHint& rHint)
const SfxSimpleHint* pSimpleHint = dynamic_cast<const SfxSimpleHint*>(&rHint);
if ( pSimpleHint && pSimpleHint->GetId() == SFX_HINT_DYING )
{
- m_pDocument = NULL;
+ m_pDocument = nullptr;
}
}
@@ -2475,12 +2475,12 @@ ScChart2DataSequence::ScChart2DataSequence( ScDocument* pDoc,
, m_nObjectId( 0 )
, m_pDocument( pDoc)
, m_pTokens(pTokens)
- , m_pRangeIndices(NULL)
- , m_pExtRefListener(NULL)
+ , m_pRangeIndices(nullptr)
+ , m_pExtRefListener(nullptr)
, m_xDataProvider( xDP)
, m_aPropSet(lcl_GetDataSequencePropertyMap())
- , m_pHiddenListener(NULL)
- , m_pValueListener( NULL )
+ , m_pHiddenListener(nullptr)
+ , m_pValueListener( nullptr )
, m_bGotDataChangedHint(false)
, m_bExtDataRebuildQueued(false)
, mbTimeBased(false)
@@ -2535,7 +2535,7 @@ void ScChart2DataSequence::RefChanged()
if( m_pDocument )
{
- ScChartListenerCollection* pCLC = NULL;
+ ScChartListenerCollection* pCLC = nullptr;
if (m_pHiddenListener.get())
{
pCLC = m_pDocument->GetChartListenerCollection();
@@ -2567,7 +2567,7 @@ void ScChart2DataSequence::BuildDataCache()
if (!m_pTokens.get())
{
- OSL_FAIL("m_pTokens == NULL! Something is wrong.");
+ OSL_FAIL("m_pTokens == nullptr! Something is wrong.");
return;
}
@@ -2598,8 +2598,8 @@ void ScChart2DataSequence::BuildDataCache()
{
for (SCROW nRow = aRange.aStart.Row(); nRow <= aRange.aEnd.Row(); ++nRow)
{
- bool bColHidden = m_pDocument->ColHidden(nCol, nTab, NULL, &nLastCol);
- bool bRowHidden = m_pDocument->RowHidden(nRow, nTab, NULL, &nLastRow);
+ bool bColHidden = m_pDocument->ColHidden(nCol, nTab, nullptr, &nLastCol);
+ bool bRowHidden = m_pDocument->RowHidden(nRow, nTab, nullptr, &nLastRow);
if (bColHidden || bRowHidden)
{
@@ -2686,7 +2686,7 @@ sal_Int32 ScChart2DataSequence::FillCacheFromExternalRef(const ScTokenRef& pToke
sal_uInt16 nFileId = pToken->GetIndex();
OUString aTabName = pToken->GetString().getString();
- ScExternalRefCache::TokenArrayRef pArray = pRefMgr->getDoubleRefTokens(nFileId, aTabName, aRange, NULL);
+ ScExternalRefCache::TokenArrayRef pArray = pRefMgr->getDoubleRefTokens(nFileId, aTabName, aRange, nullptr);
if (!pArray)
// no external data exists for this range.
return 0;
@@ -2696,7 +2696,7 @@ sal_Int32 ScChart2DataSequence::FillCacheFromExternalRef(const ScTokenRef& pToke
pRefMgr->addLinkListener(nFileId, pExtRefListener);
pExtRefListener->addFileId(nFileId);
- ScExternalRefCache::TableTypeRef pTable = pRefMgr->getCacheTable(nFileId, aTabName, false, NULL);
+ ScExternalRefCache::TableTypeRef pTable = pRefMgr->getCacheTable(nFileId, aTabName, false, nullptr);
sal_Int32 nDataCount = 0;
for (FormulaToken* p = pArray->First(); p; p = pArray->Next())
{
@@ -2729,7 +2729,7 @@ sal_Int32 ScChart2DataSequence::FillCacheFromExternalRef(const ScTokenRef& pToke
if (pFormatter)
{
const double fVal = aItem.mfValue;
- Color* pColor = NULL;
+ Color* pColor = nullptr;
sal_uInt32 nFmt = 0;
if (pTable)
{
@@ -2769,7 +2769,7 @@ void ScChart2DataSequence::UpdateTokensFromRanges(const ScRangeList& rRanges)
{
ScTokenRef pToken;
const ScRange* pRange = rRanges[i];
- OSL_ENSURE(pRange, "range object is NULL.");
+ OSL_ENSURE(pRange, "range object is nullptr.");
ScRefTokenHelper::getTokenFromRange(pToken, *pRange);
sal_uInt32 nOrigPos = (*m_pRangeIndices)[i];
@@ -2809,7 +2809,7 @@ void ScChart2DataSequence::CopyData(const ScChart2DataSequence& r)
{
if (!m_pDocument)
{
- OSL_FAIL("document instance is NULL!?");
+ OSL_FAIL("document instance is nullptr!?");
return;
}
@@ -2847,7 +2847,7 @@ void ScChart2DataSequence::Notify( SfxBroadcaster& /*rBC*/, const SfxHint& rHint
sal_uLong nId = pSimpleHint->GetId();
if ( nId ==SFX_HINT_DYING )
{
- m_pDocument = NULL;
+ m_pDocument = nullptr;
}
else if ( nId == SFX_HINT_DATACHANGED )
{
@@ -3179,7 +3179,7 @@ public:
OUString aString = ScGlobal::GetRscString(STR_COLUMN);
aString += " ";
ScAddress aPos( nCol, 0, 0 );
- OUString aColStr(aPos.Format(SCA_VALID_COL, NULL));
+ OUString aColStr(aPos.Format(SCA_VALID_COL, nullptr));
aString += aColStr;
pArr[mnCount] = aString;
}
diff --git a/sc/source/ui/unoobj/condformatuno.cxx b/sc/source/ui/unoobj/condformatuno.cxx
index da35ab69644b..2626c74c52ab 100644
--- a/sc/source/ui/unoobj/condformatuno.cxx
+++ b/sc/source/ui/unoobj/condformatuno.cxx
@@ -748,7 +748,7 @@ void SAL_CALL ScConditionEntryObj::setPropertyValue(
if ((aValue >>= aFormula) && !aFormula.isEmpty())
{
ScCompiler aComp(&mpDocShell->GetDocument(), getCoreObject()->GetSrcPos());
- boost::scoped_ptr<ScTokenArray> pArr(aComp.CompileString(aFormula));
+ std::unique_ptr<ScTokenArray> pArr(aComp.CompileString(aFormula));
getCoreObject()->SetFormula1(*pArr);
}
}
@@ -759,7 +759,7 @@ void SAL_CALL ScConditionEntryObj::setPropertyValue(
if ((aValue >>= aFormula) && !aFormula.isEmpty())
{
ScCompiler aComp(&mpDocShell->GetDocument(), getCoreObject()->GetSrcPos());
- boost::scoped_ptr<ScTokenArray> pArr(aComp.CompileString(aFormula));
+ std::unique_ptr<ScTokenArray> pArr(aComp.CompileString(aFormula));
getCoreObject()->SetFormula2(*pArr);
}
}
diff --git a/sc/source/ui/unoobj/fielduno.cxx b/sc/source/ui/unoobj/fielduno.cxx
index 94c29dcc50dd..a899d101cfc8 100644
--- a/sc/source/ui/unoobj/fielduno.cxx
+++ b/sc/source/ui/unoobj/fielduno.cxx
@@ -192,7 +192,7 @@ ScUnoEditEngine::ScUnoEditEngine(ScEditEngineDefaulter* pSource)
, eMode(SC_UNO_COLLECT_NONE)
, nFieldCount(0)
, mnFieldType(text::textfield::Type::UNSPECIFIED)
- , pFound(NULL)
+ , pFound(nullptr)
, nFieldPar(0)
, nFieldPos(0)
, nFieldIndex(0)
@@ -280,7 +280,7 @@ ScCellFieldsObj::ScCellFieldsObj(
mxContent(xContent),
pDocShell( pDocSh ),
aCellPos( rPos ),
- mpRefreshListeners( NULL )
+ mpRefreshListeners( nullptr )
{
pDocShell->GetDocument().AddUnoObject(*this);
@@ -320,7 +320,7 @@ void ScCellFieldsObj::Notify( SfxBroadcaster&, const SfxHint& rHint )
else if ( dynamic_cast<const SfxSimpleHint*>(&rHint) &&
static_cast<const SfxSimpleHint&>(rHint).GetId() == SFX_HINT_DYING )
{
- pDocShell = NULL; // ungueltig geworden
+ pDocShell = nullptr; // ungueltig geworden
}
// EditSource hat sich selber als Listener angemeldet
@@ -467,7 +467,7 @@ void SAL_CALL ScCellFieldsObj::removeRefreshListener( const uno::Reference<util:
ScHeaderFieldsObj::ScHeaderFieldsObj(ScHeaderFooterTextData& rData) :
mrData(rData),
- mpRefreshListeners( NULL )
+ mpRefreshListeners( nullptr )
{
mpEditSource = new ScHeaderFooterEditSource(rData);
}
@@ -501,7 +501,7 @@ uno::Reference<text::XTextField> ScHeaderFieldsObj::GetObjectByIndex_Impl(sal_In
SvxFieldData* pData = aTempEngine.FindByIndex(static_cast<sal_uInt16>(Index));
if (!pData)
- return NULL;
+ return nullptr;
// Get the parent text range instance.
uno::Reference<text::XTextRange> xTextRange;
@@ -855,7 +855,7 @@ uno::Any ScEditFieldObj::getPropertyValueFile(const OUString& rName)
if (rName == SC_UNONAME_FILEFORM)
{
SvxFileFormat eFormat = SVXFILEFORMAT_NAME_EXT;
- const SvxFieldData* pField = NULL;
+ const SvxFieldData* pField = nullptr;
if (mpEditSource)
{
ScEditEngineDefaulter* pEditEngine = mpEditSource->GetEditEngine();
@@ -1134,10 +1134,10 @@ ScEditFieldObj::ScEditFieldObj(
const uno::Reference<text::XTextRange>& rContent,
ScEditSource* pEditSrc, sal_Int32 eType, const ESelection& rSel) :
OComponentHelper(getMutex()),
- pPropSet(NULL),
+ pPropSet(nullptr),
mpEditSource(pEditSrc),
aSelection(rSel),
- meType(eType), mpData(NULL), mpContent(rContent), mnNumFormat(0), mbIsDate(false), mbIsFixed(false)
+ meType(eType), mpData(nullptr), mpContent(rContent), mnNumFormat(0), mbIsDate(false), mbIsFixed(false)
{
switch (meType)
{
@@ -1205,7 +1205,7 @@ void ScEditFieldObj::DeleteField()
bool ScEditFieldObj::IsInserted() const
{
- return mpEditSource != NULL;
+ return mpEditSource != nullptr;
}
// XTextField
@@ -1411,7 +1411,7 @@ const uno::Sequence<sal_Int8>& ScEditFieldObj::getUnoTunnelId()
ScEditFieldObj* ScEditFieldObj::getImplementation(const uno::Reference<text::XTextContent>& xObj)
{
- ScEditFieldObj* pRet = NULL;
+ ScEditFieldObj* pRet = nullptr;
uno::Reference<lang::XUnoTunnel> xUT( xObj, uno::UNO_QUERY );
if (xUT.is())
pRet = reinterpret_cast<ScEditFieldObj*>(sal::static_int_cast<sal_IntPtr>(xUT->getSomething(getUnoTunnelId())));
diff --git a/sc/source/ui/unoobj/filtuno.cxx b/sc/source/ui/unoobj/filtuno.cxx
index 2246df755328..69336affb287 100644
--- a/sc/source/ui/unoobj/filtuno.cxx
+++ b/sc/source/ui/unoobj/filtuno.cxx
@@ -39,7 +39,7 @@
#include <optutil.hxx>
#include <com/sun/star/uno/Any.hxx>
#include <com/sun/star/uno/Sequence.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace com::sun::star;
using namespace com::sun::star::uno;
@@ -176,11 +176,11 @@ sal_Int16 SAL_CALL ScFilterOptionsObj::execute() throw(uno::RuntimeException, st
INetURLObject aURL( aFileName );
OUString aPrivDatName(aURL.getName());
- boost::scoped_ptr<SvStream> pInStream;
+ std::unique_ptr<SvStream> pInStream;
if ( xInputStream.is() )
pInStream.reset(utl::UcbStreamHelper::CreateStream( xInputStream ));
- boost::scoped_ptr<AbstractScImportAsciiDlg> pDlg(pFact->CreateScImportAsciiDlg( NULL, aPrivDatName, pInStream.get(), SC_IMPORTFILE));
+ std::unique_ptr<AbstractScImportAsciiDlg> pDlg(pFact->CreateScImportAsciiDlg( NULL, aPrivDatName, pInStream.get(), SC_IMPORTFILE));
OSL_ENSURE(pDlg, "Dialog create fail!");
if ( pDlg->Execute() == RET_OK )
{
@@ -198,7 +198,7 @@ sal_Int16 SAL_CALL ScFilterOptionsObj::execute() throw(uno::RuntimeException, st
else
{
// HTML import.
- boost::scoped_ptr<AbstractScTextImportOptionsDlg> pDlg(
+ std::unique_ptr<AbstractScTextImportOptionsDlg> pDlg(
pFact->CreateScTextImportOptionsDlg(NULL));
if (pDlg->Execute() == RET_OK)
@@ -281,7 +281,7 @@ sal_Int16 SAL_CALL ScFilterOptionsObj::execute() throw(uno::RuntimeException, st
ScImportOptions aOptions( cAsciiDel, cStrDel, eEncoding);
- boost::scoped_ptr<AbstractScImportOptionsDlg> pDlg(pFact->CreateScImportOptionsDlg(NULL,
+ std::unique_ptr<AbstractScImportOptionsDlg> pDlg(pFact->CreateScImportOptionsDlg(NULL,
bAscii, &aOptions, &aTitle, bMultiByte, bDBEnc,
!bExport));
OSL_ENSURE(pDlg, "Dialog create fail!");
diff --git a/sc/source/ui/vba/vbaname.cxx b/sc/source/ui/vba/vbaname.cxx
index 4b0531a2e70a..07aff0901ef2 100644
--- a/sc/source/ui/vba/vbaname.cxx
+++ b/sc/source/ui/vba/vbaname.cxx
@@ -34,7 +34,7 @@
#include "compiler.hxx"
#include "tokenarray.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace ::ooo::vba;
using namespace ::com::sun::star;
@@ -130,7 +130,7 @@ void ScVbaName::setContent( const OUString& rContent, const formula::FormulaGra
// Shorter way of doing this ?
ScCompiler aComp( &rDoc, pOldData->GetPos() );
aComp.SetGrammar( eGrammar );
- boost::scoped_ptr<ScTokenArray> pArray(aComp.CompileString(sContent));
+ std::unique_ptr<ScTokenArray> pArray(aComp.CompileString(sContent));
pOldData->SetCode(*pArray);
}
}
diff --git a/sc/source/ui/vba/vbanames.cxx b/sc/source/ui/vba/vbanames.cxx
index 4d64a43bcf55..53faccf0becb 100644
--- a/sc/source/ui/vba/vbanames.cxx
+++ b/sc/source/ui/vba/vbanames.cxx
@@ -34,7 +34,7 @@
#include "tokenarray.hxx"
#include "cellsuno.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace ::ooo::vba;
using namespace ::com::sun::star;
@@ -156,7 +156,7 @@ ScVbaNames::Add( const css::uno::Any& Name ,
ScAddress aBlank;
ScCompiler aComp( getScDocument(), aBlank );
aComp.SetGrammar( eGram );
- boost::scoped_ptr<ScTokenArray> pTokens(aComp.CompileString(sFormula));
+ std::unique_ptr<ScTokenArray> pTokens(aComp.CompileString(sFormula));
if ( pTokens )
{
ScRange aRange;
diff --git a/sc/source/ui/vba/vbarange.cxx b/sc/source/ui/vba/vbarange.cxx
index 004f0286aaab..913de30eb7d9 100644
--- a/sc/source/ui/vba/vbarange.cxx
+++ b/sc/source/ui/vba/vbarange.cxx
@@ -175,7 +175,7 @@
#include "tokenuno.hxx"
#include <columnspanset.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace ::ooo::vba;
using namespace ::com::sun::star;
@@ -894,7 +894,7 @@ protected:
ScCompiler aCompiler( m_pDoc, aCellRanges.front()->aStart );
aCompiler.SetGrammar(m_eGrammar);
// compile the string in the format passed in
- boost::scoped_ptr<ScTokenArray> pArray(aCompiler.CompileString(sFormula));
+ std::unique_ptr<ScTokenArray> pArray(aCompiler.CompileString(sFormula));
// set desired convention to that of the document
aCompiler.SetGrammar( formula::FormulaGrammar::GRAM_PODF_A1 );
OUString sConverted;
@@ -937,7 +937,7 @@ public:
ScRangeList aCellRanges = pUnoRangesBase->GetRangeList();
ScCompiler aCompiler( m_pDoc, aCellRanges.front()->aStart );
aCompiler.SetGrammar(formula::FormulaGrammar::GRAM_DEFAULT);
- boost::scoped_ptr<ScTokenArray> pArray(aCompiler.CompileString(sVal));
+ std::unique_ptr<ScTokenArray> pArray(aCompiler.CompileString(sVal));
// set desired convention
aCompiler.SetGrammar( m_eGrammar );
OUString sConverted;
diff --git a/sc/source/ui/view/cellsh1.cxx b/sc/source/ui/view/cellsh1.cxx
index 64aa830826e3..b0484f9c77c8 100644
--- a/sc/source/ui/view/cellsh1.cxx
+++ b/sc/source/ui/view/cellsh1.cxx
@@ -97,7 +97,7 @@
#include <com/sun/star/i18n/TransliterationModules.hpp>
#include <com/sun/star/i18n/TransliterationModulesExtra.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace ::com::sun::star;
using namespace ::com::sun::star::beans;
@@ -215,12 +215,12 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
else
{
ScDocument* pDoc = GetViewData()->GetDocument();
- bool bTheFlag=(pDoc->GetChangeTrack()!=NULL);
+ bool bTheFlag=(pDoc->GetChangeTrack()!=nullptr);
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScInsertCellDlg> pDlg(pFact->CreateScInsertCellDlg( pTabViewShell->GetDialogParent(), RID_SCDLG_INSCELL, bTheFlag));
+ std::unique_ptr<AbstractScInsertCellDlg> pDlg(pFact->CreateScInsertCellDlg( pTabViewShell->GetDialogParent(), RID_SCDLG_INSCELL, bTheFlag));
OSL_ENSURE(pDlg, "Dialog create fail!");
if (pDlg->Execute() == RET_OK)
eCmd = pDlg->GetInsCellCmd();
@@ -287,12 +287,12 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
ScDocument* pDoc = GetViewData()->GetDocument();
bool bTheFlag=GetViewData()->IsMultiMarked() ||
(GetViewData()->GetSimpleArea(aRange) == SC_MARK_SIMPLE_FILTERED) ||
- (pDoc->GetChangeTrack() != NULL);
+ (pDoc->GetChangeTrack() != nullptr);
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScDeleteCellDlg> pDlg(pFact->CreateScDeleteCellDlg( pTabViewShell->GetDialogParent(), bTheFlag ));
+ std::unique_ptr<AbstractScDeleteCellDlg> pDlg(pFact->CreateScDeleteCellDlg( pTabViewShell->GetDialogParent(), bTheFlag ));
OSL_ENSURE(pDlg, "Dialog create fail!");
if (pDlg->Execute() == RET_OK)
@@ -337,7 +337,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
{
InsertDeleteFlags nFlags = IDF_NONE;
- if ( pReqArgs!=NULL && pTabViewShell->SelectionEditable() )
+ if ( pReqArgs!=nullptr && pTabViewShell->SelectionEditable() )
{
const SfxPoolItem* pItem;
OUString aFlags('A');
@@ -374,7 +374,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScDeleteContentsDlg> pDlg(pFact->CreateScDeleteContentsDlg(pTabViewShell->GetDialogParent()));
+ std::unique_ptr<AbstractScDeleteContentsDlg> pDlg(pFact->CreateScDeleteContentsDlg(pTabViewShell->GetDialogParent()));
OSL_ENSURE(pDlg, "Dialog create fail!");
ScDocument* pDoc = GetViewData()->GetDocument();
SCTAB nTab = GetViewData()->GetTabNo();
@@ -448,7 +448,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
bool bSkipEmpty = false;
bool bAsLink = false;
- if ( pReqArgs!=NULL && pTabViewShell->SelectionEditable() )
+ if ( pReqArgs!=nullptr && pTabViewShell->SelectionEditable() )
{
const SfxPoolItem* pItem;
OUString aFlags('A');
@@ -481,7 +481,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScInsertContentsDlg> pDlg(pFact->CreateScInsertContentsDlg( pTabViewShell->GetDialogParent(),
+ std::unique_ptr<AbstractScInsertContentsDlg> pDlg(pFact->CreateScInsertContentsDlg( pTabViewShell->GetDialogParent(),
IDF_NONE, /* nCheckDefaults */
&ScGlobal::GetRscString(STR_FILL_TAB)));
OSL_ENSURE(pDlg, "Dialog create fail!");
@@ -627,7 +627,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
bDoIt = true;
}
- else // (pReqArgs == NULL) => raise Dialog
+ else // (pReqArgs == nullptr) => raise Dialog
{
sal_uInt32 nPrivFormat;
CellType eCellType;
@@ -711,7 +711,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScFillSeriesDlg> pDlg(pFact->CreateScFillSeriesDlg( pTabViewShell->GetDialogParent(),
+ std::unique_ptr<AbstractScFillSeriesDlg> pDlg(pFact->CreateScFillSeriesDlg( pTabViewShell->GetDialogParent(),
*pDoc,
eFillDir, eFillCmd, eFillDateCmd,
aStartStr, fIncVal, fMaxVal,
@@ -814,7 +814,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
SCROW nFillRow = GetViewData()->GetRefEndY();
ScDocument* pDoc = GetViewData()->GetDocument();
- if( pReqArgs != NULL )
+ if( pReqArgs != nullptr )
{
const SfxPoolItem* pItem;
@@ -1028,7 +1028,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
case SID_SEARCH_RESULTS_DIALOG:
{
- const SfxPoolItem* pItem = NULL;
+ const SfxPoolItem* pItem = nullptr;
if (pReqArgs && pReqArgs->HasItem(SID_SEARCH_RESULTS_DIALOG, &pItem))
{
bool bVisible = static_cast<const SfxBoolItem*>(pItem)->GetValue();
@@ -1132,7 +1132,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
bOk = false;
}
- else if( pReqArgs != NULL )
+ else if( pReqArgs != nullptr )
{
const SfxPoolItem* pItem;
bOk = false;
@@ -1160,7 +1160,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScGroupDlg> pDlg(pFact->CreateAbstractScGroupDlg(pTabViewShell->GetDialogParent(), false));
+ std::unique_ptr<AbstractScGroupDlg> pDlg(pFact->CreateAbstractScGroupDlg(pTabViewShell->GetDialogParent(), false));
OSL_ENSURE(pDlg, "Dialog create fail!");
if ( pDlg->Execute() == RET_OK )
bColumns = pDlg->GetColsChecked();
@@ -1193,7 +1193,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
pTabViewShell->UngroupDataPilot();
bOk = false;
}
- else if( pReqArgs != NULL )
+ else if( pReqArgs != nullptr )
{
const SfxPoolItem* pItem;
bOk = false;
@@ -1219,7 +1219,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScGroupDlg> pDlg(pFact->CreateAbstractScGroupDlg(pTabViewShell->GetDialogParent(), true));
+ std::unique_ptr<AbstractScGroupDlg> pDlg(pFact->CreateAbstractScGroupDlg(pTabViewShell->GetDialogParent(), true));
OSL_ENSURE(pDlg, "Dialog create fail!");
if ( pDlg->Execute() == RET_OK )
bColumns = pDlg->GetColsChecked();
@@ -1252,7 +1252,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
case SID_COPY: // for graphs in DrawShell
{
WaitObject aWait( GetViewData()->GetDialogParent() );
- pTabViewShell->CopyToClip( NULL, false, false, true );
+ pTabViewShell->CopyToClip( nullptr, false, false, true );
rReq.Done();
GetViewData()->SetPasteMode( (ScPasteFlags) (SC_PASTE_MODE | SC_PASTE_BORDER) );
pTabViewShell->ShowCursor();
@@ -1263,7 +1263,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
case SID_CUT: // for graphs in DrawShell
{
WaitObject aWait( GetViewData()->GetDialogParent() );
- pTabViewShell->CutToClip( NULL, true );
+ pTabViewShell->CutToClip( nullptr, true );
rReq.Done();
GetViewData()->SetPasteMode( (ScPasteFlags)(SC_PASTE_MODE | SC_PASTE_BORDER));
pTabViewShell->ShowCursor();
@@ -1294,8 +1294,8 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
if ( nFormat != SotClipboardFormatId::NONE )
{
vcl::Window* pWin = GetViewData()->GetActiveWin();
- bool bCells = ( ScTransferObj::GetOwnClipboard( pWin ) != NULL );
- bool bDraw = ( ScDrawTransferObj::GetOwnClipboard( pWin ) != NULL );
+ bool bCells = ( ScTransferObj::GetOwnClipboard( pWin ) != nullptr );
+ bool bDraw = ( ScDrawTransferObj::GetOwnClipboard( pWin ) != nullptr );
bool bOle = ( nFormat == SotClipboardFormatId::EMBED_SOURCE );
if ( bCells && bOle )
@@ -1331,7 +1331,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
// keep a reference in case the clipboard is changed during dialog or PasteFromClip
uno::Reference<datatransfer::XTransferable> aOwnClipRef( pOwnClip );
- if ( pReqArgs!=NULL && pTabViewShell->SelectionEditable() )
+ if ( pReqArgs!=nullptr && pTabViewShell->SelectionEditable() )
{
const SfxPoolItem* pItem;
OUString aFlags('A');
@@ -1383,11 +1383,11 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScInsertContentsDlg> pDlg(pFact->CreateScInsertContentsDlg(pTabViewShell->GetDialogParent()));
+ std::unique_ptr<AbstractScInsertContentsDlg> pDlg(pFact->CreateScInsertContentsDlg(pTabViewShell->GetDialogParent()));
OSL_ENSURE(pDlg, "Dialog create fail!");
pDlg->SetOtherDoc( bOtherDoc );
// if ChangeTrack MoveMode disable
- pDlg->SetChangeTrack( pDoc->GetChangeTrack() != NULL );
+ pDlg->SetChangeTrack( pDoc->GetChangeTrack() != nullptr );
// fdo#56098 disable shift if necessary
if ( !bOtherDoc && pOwnClip )
{
@@ -1538,7 +1538,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
vcl::Window* pWin = GetViewData()->GetActiveWin();
// Clipboard-ID given as parameter? Basic "PasteSpecial(Format)"
- const SfxPoolItem* pItem=NULL;
+ const SfxPoolItem* pItem=nullptr;
if ( pReqArgs &&
pReqArgs->GetItemState(nSlot, true, &pItem) == SfxItemState::SET &&
pItem->ISA(SfxUInt32Item) )
@@ -1547,7 +1547,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
bool bRet=true;
{
WaitObject aWait( GetViewData()->GetDialogParent() );
- bool bDraw = ( ScDrawTransferObj::GetOwnClipboard( pWin ) != NULL );
+ bool bDraw = ( ScDrawTransferObj::GetOwnClipboard( pWin ) != nullptr );
if ( bDraw && nFormat == SotClipboardFormatId::EMBED_SOURCE )
pTabViewShell->PasteDraw();
else
@@ -1561,7 +1561,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
}
else
// if format is not available -> fallback to request without parameters
- pItem = NULL;
+ pItem = nullptr;
}
if ( !pItem )
@@ -1574,7 +1574,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
}
else // draw objects or external data
{
- bool bDraw = ( ScDrawTransferObj::GetOwnClipboard( pWin ) != NULL );
+ bool bDraw = ( ScDrawTransferObj::GetOwnClipboard( pWin ) != nullptr );
SvxClipboardFormatItem aFormats( SID_CLIPBOARD_FORMAT_ITEMS );
GetPossibleClipboardFormats( aFormats );
@@ -1583,7 +1583,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
if ( nFormatCount )
{
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
- boost::scoped_ptr<SfxAbstractPasteDialog> pDlg(pFact->CreatePasteDialog( pTabViewShell->GetDialogParent() ));
+ std::unique_ptr<SfxAbstractPasteDialog> pDlg(pFact->CreatePasteDialog( pTabViewShell->GetDialogParent() ));
if ( pDlg )
{
for (sal_uInt16 i=0; i<nFormatCount; i++)
@@ -1817,7 +1817,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScNameCreateDlg> pDlg(pFact->CreateScNameCreateDlg(pTabViewShell->GetDialogParent(), nFlags));
+ std::unique_ptr<AbstractScNameCreateDlg> pDlg(pFact->CreateScNameCreateDlg(pTabViewShell->GetDialogParent(), nFlags));
OSL_ENSURE(pDlg, "Dialog create fail!");
if( pDlg->Execute() )
@@ -1865,7 +1865,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
}
else // CANCEL
{
- pScMod->ActivateInputWindow( NULL );
+ pScMod->ActivateInputWindow( nullptr );
}
rReq.Ignore(); // only SID_ENTER_STRING is recorded
}
@@ -1926,11 +1926,11 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
bool bManaged = false;
// Get the pool item stored it by Conditional Format Manager Dialog.
- const SfxPoolItem* pItem = NULL;
+ const SfxPoolItem* pItem = nullptr;
sal_uInt32 nItems(pTabViewShell->GetPool().GetItemCount2( SCITEM_STRING ));
for( sal_uInt32 nIter = 0; nIter < nItems; ++nIter )
{
- if( NULL != (pItem = pTabViewShell->GetPool().GetItem2( SCITEM_STRING, nIter ) ) )
+ if( nullptr != (pItem = pTabViewShell->GetPool().GetItem2( SCITEM_STRING, nIter ) ) )
{
if ( ScCondFormatDlg::ParseXmlString(
static_cast<const SfxStringItem*>(pItem)->GetValue(),
@@ -1969,7 +1969,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
aRangeList.push_back(pRange);
}
- const ScConditionalFormat* pCondFormat = NULL;
+ const ScConditionalFormat* pCondFormat = nullptr;
const ScPatternAttr* pPattern = pDoc->GetPattern(aPos.Col(), aPos.Row(), aPos.Tab());
const std::vector<sal_uInt32>& rCondFormats = static_cast<const ScCondFormatItem&>(pPattern->GetItem(ATTR_CONDITIONAL)).GetCondFormatData();
bool bContainsCondFormat = !rCondFormats.empty();
@@ -2139,7 +2139,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScNamePasteDlg> pDlg(pFact->CreateScNamePasteDlg( pTabViewShell->GetDialogParent(), GetViewData()->GetDocShell() ));
+ std::unique_ptr<AbstractScNamePasteDlg> pDlg(pFact->CreateScNamePasteDlg( pTabViewShell->GetDialogParent(), GetViewData()->GetDocShell() ));
OSL_ENSURE(pDlg, "Dialog create fail!");
switch( pDlg->Execute() )
{
@@ -2300,7 +2300,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
break;
case SID_CHARMAP:
- if( pReqArgs != NULL )
+ if( pReqArgs != nullptr )
{
OUString aChars, aFontName;
const SfxItemSet *pArgs = rReq.GetArgs();
@@ -2312,7 +2312,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
const SfxStringItem* pStringItem = PTR_CAST( SfxStringItem, pItem );
if ( pStringItem )
aChars = pStringItem->GetValue();
- const SfxPoolItem* pFtItem = NULL;
+ const SfxPoolItem* pFtItem = nullptr;
pArgs->GetItemState( GetPool().GetWhich(SID_ATTR_SPECIALCHAR), false, &pFtItem);
const SfxStringItem* pFontItem = PTR_CAST( SfxStringItem, pFtItem );
if ( pFontItem )
@@ -2322,7 +2322,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
if ( !aChars.isEmpty() )
{
vcl::Font aFont;
- pTabViewShell->GetSelectionPattern()->GetFont( aFont, SC_AUTOCOL_BLACK, NULL, NULL, NULL,
+ pTabViewShell->GetSelectionPattern()->GetFont( aFont, SC_AUTOCOL_BLACK, nullptr, nullptr, nullptr,
pTabViewShell->GetSelectionScriptType() );
if ( !aFontName.isEmpty() )
aFont = vcl::Font( aFontName, Size(1,1) );
@@ -2337,14 +2337,14 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
// font color doesn't matter here
vcl::Font aCurFont;
- pTabViewShell->GetSelectionPattern()->GetFont( aCurFont, SC_AUTOCOL_BLACK, NULL, NULL, NULL,
+ pTabViewShell->GetSelectionPattern()->GetFont( aCurFont, SC_AUTOCOL_BLACK, nullptr, nullptr, nullptr,
pTabViewShell->GetSelectionScriptType() );
SfxAllItemSet aSet( GetPool() );
aSet.Put( SfxBoolItem( FN_PARAM_1, false ) );
aSet.Put( SvxFontItem( aCurFont.GetFamily(), aCurFont.GetName(), aCurFont.GetStyleName(), aCurFont.GetPitch(), aCurFont.GetCharSet(), GetPool().GetWhich(SID_ATTR_CHAR_FONT) ) );
- boost::scoped_ptr<SfxAbstractDialog> pDlg(pFact->CreateSfxDialog( pTabViewShell->GetDialogParent(), aSet,
+ std::unique_ptr<SfxAbstractDialog> pDlg(pFact->CreateSfxDialog( pTabViewShell->GetDialogParent(), aSet,
pTabViewShell->GetViewFrame()->GetFrame().GetFrameInterface(), RID_SVXDLG_CHARMAP ));
if ( pDlg->Execute() == RET_OK )
@@ -2384,7 +2384,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
}
else
{
- OSL_FAIL("NULL");
+ OSL_FAIL("nullptr");
}
}
}
@@ -2427,7 +2427,7 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq )
ScAddress aPos(pData->GetCurX(), pData->GetCurY(), pData->GetTabNo());
ScConditionalFormatList* pList = pDoc->GetCondFormList( aPos.Tab() );
- boost::scoped_ptr<AbstractScCondFormatManagerDlg> pDlg(pFact->CreateScCondFormatMgrDlg(
+ std::unique_ptr<AbstractScCondFormatManagerDlg> pDlg(pFact->CreateScCondFormatMgrDlg(
pTabViewShell->GetDialogParent(), pDoc, pList, aPos, RID_SCDLG_COND_FORMAT_MANAGER));
short nRet = pDlg->Execute();
if(nRet == RET_OK && pDlg->CondFormatsChanged())
@@ -2572,7 +2572,7 @@ bool isDPSourceValid(const ScDPObject& rDPObj)
return false;
const ScDPSaveData* pSaveData = rDPObj.GetSaveData();
- const ScDPDimensionSaveData* pDimData = NULL;
+ const ScDPDimensionSaveData* pDimData = nullptr;
if (pSaveData)
pDimData = pSaveData->GetExistingDimensionData();
@@ -2593,7 +2593,7 @@ void ScCellShell::ExecuteDataPilotDialog()
ScViewData* pData = GetViewData();
ScDocument* pDoc = pData->GetDocument();
- ::boost::scoped_ptr<ScDPObject> pNewDPObject(NULL);
+ std::unique_ptr<ScDPObject> pNewDPObject(nullptr);
// ScPivot is no longer used...
ScDPObject* pDPObj = pDoc->GetDPAtCursor(
@@ -2625,7 +2625,7 @@ void ScCellShell::ExecuteDataPilotDialog()
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- ::boost::scoped_ptr<AbstractScDataPilotSourceTypeDlg> pTypeDlg(
+ std::unique_ptr<AbstractScDataPilotSourceTypeDlg> pTypeDlg(
pFact->CreateScDataPilotSourceTypeDlg(
pTabViewShell->GetDialogParent(), bEnableExt));
@@ -2644,7 +2644,7 @@ void ScCellShell::ExecuteDataPilotDialog()
if ( pTypeDlg->IsExternal() )
{
uno::Sequence<OUString> aSources = ScDPObject::GetRegisteredSources();
- ::boost::scoped_ptr<AbstractScDataPilotServiceDlg> pServDlg(
+ std::unique_ptr<AbstractScDataPilotServiceDlg> pServDlg(
pFact->CreateScDataPilotServiceDlg(
pTabViewShell->GetDialogParent(), aSources, RID_SCDLG_DAPISERVICE));
@@ -2665,7 +2665,7 @@ void ScCellShell::ExecuteDataPilotDialog()
{
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- ::boost::scoped_ptr<AbstractScDataPilotDatabaseDlg> pDataDlg(
+ std::unique_ptr<AbstractScDataPilotDatabaseDlg> pDataDlg(
pFact->CreateScDataPilotDatabaseDlg(
pTabViewShell->GetDialogParent()));
@@ -2796,7 +2796,7 @@ void ScCellShell::ExecuteSubtotals(SfxRequest& rReq)
return;
}
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg;
+ std::unique_ptr<SfxAbstractTabDialog> pDlg;
ScSubTotalParam aSubTotalParam;
SfxItemSet aArgSet( GetPool(), SCITEM_SUBTDATA, SCITEM_SUBTDATA );
@@ -2827,7 +2827,7 @@ void ScCellShell::ExecuteSubtotals(SfxRequest& rReq)
if ( (bResult == RET_OK) || (bResult == SCRET_REMOVE) )
{
- const SfxItemSet* pOutSet = NULL;
+ const SfxItemSet* pOutSet = nullptr;
if ( bResult == RET_OK )
{
diff --git a/sc/source/ui/view/cellsh2.cxx b/sc/source/ui/view/cellsh2.cxx
index 2e0f7f2f604a..fb3e6b796292 100644
--- a/sc/source/ui/view/cellsh2.cxx
+++ b/sc/source/ui/view/cellsh2.cxx
@@ -66,7 +66,7 @@
#include <config_orcus.h>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace com::sun::star;
@@ -162,7 +162,7 @@ static bool lcl_GetSortParam( const ScViewData* pData, ScSortParam& rSortParam )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScSortWarningDlg> pWarningDlg(pFact->CreateScSortWarningDlg( pTabViewShell->GetDialogParent(), aExtendStr, aCurrentStr ));
+ std::unique_ptr<AbstractScSortWarningDlg> pWarningDlg(pFact->CreateScSortWarningDlg( pTabViewShell->GetDialogParent(), aExtendStr, aCurrentStr ));
OSL_ENSURE(pWarningDlg, "Dialog create fail!");
short bResult = pWarningDlg->Execute();
if( bResult == BTN_EXTEND_RANGE || bResult == BTN_CURRENT_SELECTION )
@@ -482,7 +482,7 @@ void ScCellShell::ExecuteDB( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
assert(pFact); //ScAbstractFactory create fail!
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScSortDlg(pTabViewShell->GetDialogParent(), &aArgSet));
+ std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScSortDlg(pTabViewShell->GetDialogParent(), &aArgSet));
assert(pDlg); //Dialog create fail!
pDlg->SetCurPageId("criteria"); // 1=sort field tab 2=sort options tab
@@ -723,7 +723,7 @@ void ScCellShell::ExecuteDB( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScSelEntryDlg> pDlg(pFact->CreateScSelEntryDlg( pTabViewShell->GetDialogParent(),
+ std::unique_ptr<AbstractScSelEntryDlg> pDlg(pFact->CreateScSelEntryDlg( pTabViewShell->GetDialogParent(),
aList ));
OSL_ENSURE(pDlg, "Dialog create fail!");
if ( pDlg->Execute() == RET_OK )
@@ -975,7 +975,7 @@ void ScCellShell::ExecuteDB( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE( pFact, "ScCellShell::ExecuteDB: SID_TEXT_TO_COLUMNS - pFact is null!" );
- boost::scoped_ptr<AbstractScImportAsciiDlg> pDlg(pFact->CreateScImportAsciiDlg(
+ std::unique_ptr<AbstractScImportAsciiDlg> pDlg(pFact->CreateScImportAsciiDlg(
NULL, OUString(), &aStream, SC_TEXTTOCOLUMNS));
OSL_ENSURE( pDlg, "ScCellShell::ExecuteDB: SID_TEXT_TO_COLUMNS - pDlg is null!" );
diff --git a/sc/source/ui/view/cellsh3.cxx b/sc/source/ui/view/cellsh3.cxx
index 0df3ad943b1f..b5667e6ac3d9 100644
--- a/sc/source/ui/view/cellsh3.cxx
+++ b/sc/source/ui/view/cellsh3.cxx
@@ -48,7 +48,7 @@
#include "sccollaboration.hxx"
#endif
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#define IS_EDITMODE() GetViewData()->HasEditView( GetViewData()->GetActivePart() )
@@ -321,12 +321,12 @@ void ScCellShell::Execute( SfxRequest& rReq )
// set cell attribute without dialog:
- boost::scoped_ptr<SfxItemSet> pEmptySet(
+ std::unique_ptr<SfxItemSet> pEmptySet(
new SfxItemSet( *pReqArgs->GetPool(),
ATTR_PATTERN_START,
ATTR_PATTERN_END ));
- boost::scoped_ptr<SfxItemSet> pNewSet(
+ std::unique_ptr<SfxItemSet> pNewSet(
new SfxItemSet( *pReqArgs->GetPool(),
ATTR_PATTERN_START,
ATTR_PATTERN_END ));
@@ -489,7 +489,7 @@ void ScCellShell::Execute( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScNewScenarioDlg> pNewDlg(pFact->CreateScNewScenarioDlg(pTabViewShell->GetDialogParent(), aName, false, bSheetProtected));
+ std::unique_ptr<AbstractScNewScenarioDlg> pNewDlg(pFact->CreateScNewScenarioDlg(pTabViewShell->GetDialogParent(), aName, false, bSheetProtected));
OSL_ENSURE(pNewDlg, "Dialog create fail!");
if ( pNewDlg->Execute() == RET_OK )
{
@@ -539,7 +539,7 @@ void ScCellShell::Execute( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
assert(pFact); //ScAbstractFactory create fail!
- boost::scoped_ptr<AbstractScMetricInputDlg> pDlg(pFact->CreateScMetricInputDlg(
+ std::unique_ptr<AbstractScMetricInputDlg> pDlg(pFact->CreateScMetricInputDlg(
pTabViewShell->GetDialogParent(), "RowHeightDialog",
nCurHeight, ScGlobal::nStdRowHeight,
eMetric, 2, MAX_ROW_HEIGHT));
@@ -580,7 +580,7 @@ void ScCellShell::Execute( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
assert(pFact); //ScAbstractFactory create fail!
- boost::scoped_ptr<AbstractScMetricInputDlg> pDlg(pFact->CreateScMetricInputDlg(
+ std::unique_ptr<AbstractScMetricInputDlg> pDlg(pFact->CreateScMetricInputDlg(
pTabViewShell->GetDialogParent(), "OptimalRowHeightDialog",
ScGlobal::nLastRowHeightExtra, 0, eMetric, 1, MAX_EXTRA_HEIGHT));
assert(pDlg); //Dialog create fail!
@@ -622,7 +622,7 @@ void ScCellShell::Execute( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
assert(pFact); //ScAbstractFactory create fail!
- boost::scoped_ptr<AbstractScMetricInputDlg> pDlg(pFact->CreateScMetricInputDlg(
+ std::unique_ptr<AbstractScMetricInputDlg> pDlg(pFact->CreateScMetricInputDlg(
pTabViewShell->GetDialogParent(), "ColWidthDialog", nCurHeight,
STD_COL_WIDTH, eMetric, 2, MAX_COL_WIDTH));
assert(pDlg); //Dialog create fail!
@@ -662,7 +662,7 @@ void ScCellShell::Execute( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
assert(pFact); //ScAbstractFactory create fail!
- boost::scoped_ptr<AbstractScMetricInputDlg> pDlg(pFact->CreateScMetricInputDlg(
+ std::unique_ptr<AbstractScMetricInputDlg> pDlg(pFact->CreateScMetricInputDlg(
pTabViewShell->GetDialogParent(), "OptimalColWidthDialog",
ScGlobal::nLastColWidthExtra, STD_EXTRA_WIDTH, eMetric, 1, MAX_EXTRA_WIDTH));
assert(pDlg); //Dialog create fail!
@@ -809,11 +809,11 @@ void ScCellShell::Execute( SfxRequest& rReq )
else
{
ScGlobal::ClearAutoFormat();
- boost::scoped_ptr<ScAutoFormatData> pNewEntry(pTabViewShell->CreateAutoFormatData());
+ std::unique_ptr<ScAutoFormatData> pNewEntry(pTabViewShell->CreateAutoFormatData());
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScAutoFormatDlg> pDlg(pFact->CreateScAutoFormatDlg(pDlgParent, ScGlobal::GetOrCreateAutoFormat(), pNewEntry.get(), GetViewData()));
+ std::unique_ptr<AbstractScAutoFormatDlg> pDlg(pFact->CreateScAutoFormatDlg(pDlgParent, ScGlobal::GetOrCreateAutoFormat(), pNewEntry.get(), GetViewData()));
OSL_ENSURE(pDlg, "Dialog create fail!");
if ( pDlg->Execute() == RET_OK )
diff --git a/sc/source/ui/view/dbfunc3.cxx b/sc/source/ui/view/dbfunc3.cxx
index 367b5caf668b..268c2168413e 100644
--- a/sc/source/ui/view/dbfunc3.cxx
+++ b/sc/source/ui/view/dbfunc3.cxx
@@ -67,8 +67,8 @@
#include "markdata.hxx"
#include "stringutil.hxx"
-#include <boost/scoped_ptr.hpp>
#include <list>
+#include <memory>
#include <unordered_set>
#include <unordered_map>
#include <vector>
@@ -1744,7 +1744,7 @@ bool ScDBFunc::DataPilotSort( const ScAddress& rPos, bool bAscending, sal_uInt16
// Update the datapilot with the newly sorted field members.
- boost::scoped_ptr<ScDPObject> pNewObj(new ScDPObject(*pDPObj));
+ std::unique_ptr<ScDPObject> pNewObj(new ScDPObject(*pDPObj));
pNewObj->SetSaveData(aNewSaveData);
ScDBDocFunc aFunc(*GetViewData().GetDocShell());
@@ -1832,7 +1832,7 @@ bool ScDBFunc::DataPilotMove( const ScRange& rSource, const ScAddress& rDest )
// apply changes
ScDBDocFunc aFunc( *GetViewData().GetDocShell() );
- boost::scoped_ptr<ScDPObject> pNewObj(new ScDPObject( *pDPObj ));
+ std::unique_ptr<ScDPObject> pNewObj(new ScDPObject( *pDPObj ));
pNewObj->SetSaveData( aData );
aFunc.DataPilotUpdate( pDPObj, pNewObj.get(), true, false ); //! bApi for drag&drop?
pNewObj.reset();
@@ -1961,7 +1961,7 @@ void ScDBFunc::SetDataPilotDetails(bool bShow, const OUString* pNewDimensionName
// apply changes
ScDBDocFunc aFunc( *GetViewData().GetDocShell() );
- boost::scoped_ptr<ScDPObject> pNewObj(new ScDPObject( *pDPObj ));
+ std::unique_ptr<ScDPObject> pNewObj(new ScDPObject( *pDPObj ));
pNewObj->SetSaveData( aData );
aFunc.DataPilotUpdate( pDPObj, pNewObj.get(), true, false );
pNewObj.reset();
@@ -1998,7 +1998,7 @@ void ScDBFunc::ShowDataPilotSourceData( ScDPObject& rDPObj, const Sequence<sheet
SCTAB nNewTab = GetViewData().GetTabNo();
- boost::scoped_ptr<ScDocument> pInsDoc(new ScDocument(SCDOCMODE_CLIP));
+ std::unique_ptr<ScDocument> pInsDoc(new ScDocument(SCDOCMODE_CLIP));
pInsDoc->ResetClip( pDoc, nNewTab );
for (SCROW nRow = 0; nRow < nRowSize; ++nRow)
{
diff --git a/sc/source/ui/view/editsh.cxx b/sc/source/ui/view/editsh.cxx
index c95251e0d115..9b1d2b0aaa5c 100644
--- a/sc/source/ui/view/editsh.cxx
+++ b/sc/source/ui/view/editsh.cxx
@@ -78,7 +78,7 @@
#include "scui_def.hxx"
#include "scabstdlg.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace ::com::sun::star;
@@ -274,7 +274,7 @@ void ScEditShell::Execute( SfxRequest& rReq )
case SID_PASTE_SPECIAL:
{
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
- boost::scoped_ptr<SfxAbstractPasteDialog> pDlg(pFact->CreatePasteDialog( pViewData->GetDialogParent() ));
+ std::unique_ptr<SfxAbstractPasteDialog> pDlg(pFact->CreatePasteDialog( pViewData->GetDialogParent() ));
SotClipboardFormatId nFormat = SotClipboardFormatId::NONE;
if ( pDlg )
{
@@ -455,7 +455,7 @@ void ScEditShell::Execute( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScNamePasteDlg> pDlg(pFact->CreateScNamePasteDlg( pViewData->GetDialogParent(), pViewData->GetDocShell(), false ));
+ std::unique_ptr<AbstractScNamePasteDlg> pDlg(pFact->CreateScNamePasteDlg( pViewData->GetDialogParent(), pViewData->GetDocShell(), false ));
OSL_ENSURE(pDlg, "Dialog create fail!");
short nRet = pDlg->Execute();
// pDlg is needed below
@@ -497,7 +497,7 @@ void ScEditShell::Execute( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScCharDlg(
+ std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateScCharDlg(
pViewData->GetDialogParent(), &aAttrs, pObjSh));
OSL_ENSURE(pDlg, "Dialog create fail!");
if (nSlot == SID_CHAR_DLG_EFFECT)
diff --git a/sc/source/ui/view/formatsh.cxx b/sc/source/ui/view/formatsh.cxx
index 3fdbf69520d8..f3f735127da9 100644
--- a/sc/source/ui/view/formatsh.cxx
+++ b/sc/source/ui/view/formatsh.cxx
@@ -82,7 +82,7 @@
#include "scabstdlg.hxx"
#include <editeng/fontitem.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace ::com::sun::star;
@@ -779,7 +779,7 @@ void ScFormatShell::ExecuteStyle( SfxRequest& rReq )
if ( pStyleSheet )
{
SfxStyleFamily eFam = pStyleSheet->GetFamily();
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg;
+ std::unique_ptr<SfxAbstractTabDialog> pDlg;
sal_uInt16 nRsc = 0;
// Store old Items from the style
@@ -819,7 +819,7 @@ void ScFormatShell::ExecuteStyle( SfxRequest& rReq )
}
}
- boost::scoped_ptr<SvxNumberInfoItem> pNumberInfoItem(
+ std::unique_ptr<SvxNumberInfoItem> pNumberInfoItem(
ScTabViewShell::MakeNumberInfoItem(&rDoc, GetViewData()));
pDocSh->PutItem( *pNumberInfoItem );
@@ -1792,12 +1792,12 @@ void ScFormatShell::ExecuteAttr( SfxRequest& rReq )
{
::editeng::SvxBorderLine* pDefLine = pTabViewShell->GetDefaultFrameLine();
const ScPatternAttr* pOldAttrs = pTabViewShell->GetSelectionPattern();
- boost::scoped_ptr<SfxItemSet> pOldSet(
+ std::unique_ptr<SfxItemSet> pOldSet(
new SfxItemSet(
*(pDoc->GetPool()),
ATTR_PATTERN_START,
ATTR_PATTERN_END ));
- boost::scoped_ptr<SfxItemSet> pNewSet(
+ std::unique_ptr<SfxItemSet> pNewSet(
new SfxItemSet(
*(pDoc->GetPool()),
ATTR_PATTERN_START,
@@ -1858,8 +1858,8 @@ void ScFormatShell::ExecuteAttr( SfxRequest& rReq )
case SID_ATTR_BORDER_DIAG_BLTR:
{
const ScPatternAttr* pOldAttrs = pTabViewShell->GetSelectionPattern();
- boost::scoped_ptr<SfxItemSet> pOldSet(new SfxItemSet(pOldAttrs->GetItemSet()));
- boost::scoped_ptr<SfxItemSet> pNewSet(new SfxItemSet(pOldAttrs->GetItemSet()));
+ std::unique_ptr<SfxItemSet> pOldSet(new SfxItemSet(pOldAttrs->GetItemSet()));
+ std::unique_ptr<SfxItemSet> pNewSet(new SfxItemSet(pOldAttrs->GetItemSet()));
const SfxPoolItem* pItem = 0;
if(SID_ATTR_BORDER_DIAG_TLBR == nSlot)
diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx
index 006c00c2a385..5200b85eb0be 100644
--- a/sc/source/ui/view/gridwin.cxx
+++ b/sc/source/ui/view/gridwin.cxx
@@ -138,8 +138,8 @@
#define LOK_USE_UNSTABLE_API
#include <LibreOfficeKit/LibreOfficeKitEnums.h>
+#include <memory>
#include <vector>
-#include <boost/shared_ptr.hpp>
using namespace css;
using namespace css::uno;
@@ -5292,11 +5292,11 @@ SvxAdjust toSvxAdjust( const ScPatternAttr& rPat )
return eSvxAdjust;
}
-boost::shared_ptr<ScFieldEditEngine> createEditEngine( ScDocShell* pDocSh, const ScPatternAttr& rPat )
+std::shared_ptr<ScFieldEditEngine> createEditEngine( ScDocShell* pDocSh, const ScPatternAttr& rPat )
{
ScDocument& rDoc = pDocSh->GetDocument();
- boost::shared_ptr<ScFieldEditEngine> pEngine(new ScFieldEditEngine(&rDoc, rDoc.GetEditPool()));
+ std::shared_ptr<ScFieldEditEngine> pEngine(new ScFieldEditEngine(&rDoc, rDoc.GetEditPool()));
ScSizeDeviceProvider aProv(pDocSh);
pEngine->SetRefDevice(aProv.GetDevice());
pEngine->SetRefMapMode(MAP_100TH_MM);
@@ -5375,7 +5375,7 @@ bool ScGridWindow::GetEditUrl( const Point& rPos,
// EditEngine
- boost::shared_ptr<ScFieldEditEngine> pEngine = createEditEngine(pDocSh, *pPattern);
+ std::shared_ptr<ScFieldEditEngine> pEngine = createEditEngine(pDocSh, *pPattern);
MapMode aEditMode = pViewData->GetLogicMode(eWhich); // without draw scaleing
Rectangle aLogicEdit = PixelToLogic( aEditRect, aEditMode );
@@ -5481,7 +5481,7 @@ bool ScGridWindow::IsSpellErrorAtPos( const Point& rPos, SCCOL nCol1, SCROW nRow
if (rPos.Y() < aEditRect.Top())
return false;
- boost::shared_ptr<ScFieldEditEngine> pEngine = createEditEngine(pDocSh, *pPattern);
+ std::shared_ptr<ScFieldEditEngine> pEngine = createEditEngine(pDocSh, *pPattern);
Size aPaperSize = Size(1000000, 1000000);
pEngine->SetPaperSize(aPaperSize);
diff --git a/sc/source/ui/view/gridwin4.cxx b/sc/source/ui/view/gridwin4.cxx
index f82668a4058d..6faf516234ff 100644
--- a/sc/source/ui/view/gridwin4.cxx
+++ b/sc/source/ui/view/gridwin4.cxx
@@ -983,7 +983,7 @@ void ScGridWindow::PaintTile( VirtualDevice& rDevice,
// setup the SdrPage so that drawinglayer works correctly
ScDrawLayer* pModel = pDoc->GetDrawLayer();
- boost::scoped_ptr<FmFormView> pDrawView;
+ std::unique_ptr<FmFormView> pDrawView;
if (pModel)
{
pDrawView.reset(new FmFormView(pModel, &rDevice));
diff --git a/sc/source/ui/view/output.cxx b/sc/source/ui/view/output.cxx
index f1432c4fdf0e..0668a5f1cf65 100644
--- a/sc/source/ui/view/output.cxx
+++ b/sc/source/ui/view/output.cxx
@@ -66,10 +66,10 @@
#include "colorscale.hxx"
#include <math.h>
+#include <iostream>
#include <map>
+#include <memory>
#include <utility>
-#include <iostream>
-#include <boost/scoped_ptr.hpp>
using namespace com::sun::star;
@@ -1424,7 +1424,7 @@ void ScOutputData::DrawFrame(vcl::RenderContext& rRenderContext)
// draw only rows with set RowInfo::bChanged flag
size_t nRow1 = nFirstRow;
- boost::scoped_ptr<drawinglayer::processor2d::BaseProcessor2D> pProcessor(CreateProcessor2D());
+ std::unique_ptr<drawinglayer::processor2d::BaseProcessor2D> pProcessor(CreateProcessor2D());
if (!pProcessor)
return;
@@ -1546,7 +1546,7 @@ void ScOutputData::DrawRotatedFrame(vcl::RenderContext& rRenderContext, const Co
rRenderContext.SetClipRegion( vcl::Region( aClipRect ) );
svx::frame::Array& rArray = mrTabInfo.maArray;
- boost::scoped_ptr<drawinglayer::processor2d::BaseProcessor2D> pProcessor(CreateProcessor2D( ));
+ std::unique_ptr<drawinglayer::processor2d::BaseProcessor2D> pProcessor(CreateProcessor2D( ));
long nPosY = nScrY;
for (SCSIZE nArrY=1; nArrY<nArrCount; nArrY++)
diff --git a/sc/source/ui/view/output2.cxx b/sc/source/ui/view/output2.cxx
index bbdd147350ab..b2e04d01f53e 100644
--- a/sc/source/ui/view/output2.cxx
+++ b/sc/source/ui/view/output2.cxx
@@ -67,7 +67,7 @@
#include <comphelper/string.hxx>
#include <boost/ptr_container/ptr_vector.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include <math.h>
@@ -4442,7 +4442,7 @@ void ScOutputData::DrawEditAsianVertical(DrawEditParam& rParam)
void ScOutputData::DrawEdit(bool bPixelToLogic)
{
- boost::scoped_ptr<ScFieldEditEngine> pEngine;
+ std::unique_ptr<ScFieldEditEngine> pEngine;
bool bHyphenatorSet = false;
const ScPatternAttr* pOldPattern = NULL;
const SfxItemSet* pOldCondSet = NULL;
@@ -4474,7 +4474,7 @@ void ScOutputData::DrawEdit(bool bPixelToLogic)
long nPosX = 0;
for (SCCOL nX=0; nX<=nX2; nX++) // due to overflow
{
- boost::scoped_ptr< ScPatternAttr > pPreviewPattr;
+ std::unique_ptr< ScPatternAttr > pPreviewPattr;
if (nX==nX1) nPosX = nInitPosX; // positions before nX1 are calculated individually
CellInfo* pInfo = &pThisRowInfo->pCellInfo[nX+1];
@@ -4644,7 +4644,7 @@ void ScOutputData::DrawRotated(bool bPixelToLogic)
bool bCellContrast = mbUseStyleColor &&
Application::GetSettings().GetStyleSettings().GetHighContrastMode();
- boost::scoped_ptr<ScFieldEditEngine> pEngine;
+ std::unique_ptr<ScFieldEditEngine> pEngine;
bool bHyphenatorSet = false;
const ScPatternAttr* pPattern;
const SfxItemSet* pCondSet;
diff --git a/sc/source/ui/view/pivotsh.cxx b/sc/source/ui/view/pivotsh.cxx
index 613484adea69..55ade8b614ab 100644
--- a/sc/source/ui/view/pivotsh.cxx
+++ b/sc/source/ui/view/pivotsh.cxx
@@ -41,7 +41,7 @@
#define ScPivotShell
#include "scslots.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
TYPEINIT1( ScPivotShell, SfxShell );
@@ -108,7 +108,7 @@ void ScPivotShell::Execute( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScPivotFilterDlg> pDlg(pFact->CreateScPivotFilterDlg(
+ std::unique_ptr<AbstractScPivotFilterDlg> pDlg(pFact->CreateScPivotFilterDlg(
pViewShell->GetDialogParent(), aArgSet, nSrcTab));
OSL_ENSURE(pDlg, "Dialog create fail!");
diff --git a/sc/source/ui/view/preview.cxx b/sc/source/ui/view/preview.cxx
index 9d4b150ffd2a..6bf5469e81a4 100644
--- a/sc/source/ui/view/preview.cxx
+++ b/sc/source/ui/view/preview.cxx
@@ -64,7 +64,7 @@
#include <docpool.hxx>
#include <patattr.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
// STATIC DATA -----------------------------------------------------------
@@ -507,7 +507,7 @@ void ScPreview::DoPrint( ScPreviewLocationData* pFillLocation )
static_cast<const ScPatternAttr&>(
rDoc.GetPool()->GetDefaultItem(ATTR_PATTERN));
- boost::scoped_ptr<ScEditEngineDefaulter> pEditEng(
+ std::unique_ptr<ScEditEngineDefaulter> pEditEng(
new ScEditEngineDefaulter(EditEngine::CreatePool(), true));
pEditEng->SetRefMapMode(aMMMode);
diff --git a/sc/source/ui/view/prevwsh.cxx b/sc/source/ui/view/prevwsh.cxx
index 47abf1b8740e..f9a0c9b3f80c 100644
--- a/sc/source/ui/view/prevwsh.cxx
+++ b/sc/source/ui/view/prevwsh.cxx
@@ -81,7 +81,7 @@ using namespace com::sun::star;
#define ScPreviewShell
#include "scslots.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
TYPEINIT1( ScPreviewShell, SfxViewShell );
@@ -645,7 +645,7 @@ void ScPreviewShell::Execute( SfxRequest& rReq )
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
if(pFact)
{
- boost::scoped_ptr<AbstractSvxZoomDialog> pDlg(pFact->CreateSvxZoomDialog(NULL, aSet));
+ std::unique_ptr<AbstractSvxZoomDialog> pDlg(pFact->CreateSvxZoomDialog(NULL, aSet));
OSL_ENSURE(pDlg, "Dialog creation failed!");
pDlg->SetLimits( 20, 400 );
pDlg->HideButton( ZoomButtonId::OPTIMAL );
diff --git a/sc/source/ui/view/printfun.cxx b/sc/source/ui/view/printfun.cxx
index e6e6f7b3160c..02a9d5d2351f 100644
--- a/sc/source/ui/view/printfun.cxx
+++ b/sc/source/ui/view/printfun.cxx
@@ -70,7 +70,7 @@
#include <vcl/lineinfo.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include <com/sun/star/document/XDocumentProperties.hpp>
#define ZOOM_MIN 10
@@ -517,7 +517,7 @@ void ScPrintFunc::DrawToDev( ScDocument* pDoc, OutputDevice* pDev, double /* nPr
// #114135#
ScDrawLayer* pModel = pDoc->GetDrawLayer();
- boost::scoped_ptr<FmFormView> pDrawView;
+ std::unique_ptr<FmFormView> pDrawView;
if( pModel )
{
@@ -1330,7 +1330,7 @@ void ScPrintFunc::DrawBorder( long nScrX, long nScrY, long nScrW, long nScrH,
if (pBorderData)
{
- boost::scoped_ptr<ScDocument> pBorderDoc(new ScDocument( SCDOCMODE_UNDO ));
+ std::unique_ptr<ScDocument> pBorderDoc(new ScDocument( SCDOCMODE_UNDO ));
pBorderDoc->InitUndo( pDoc, 0,0, true,true );
if (pBorderData)
pBorderDoc->ApplyAttr( 0,0,0, *pBorderData );
@@ -3028,7 +3028,7 @@ void ScPrintFunc::CalcPages() // calculates aPageRect and pages fr
SCROW nPageStartRow = nStartRow;
SCROW nLastVisibleRow = -1;
- ::boost::scoped_ptr<ScRowBreakIterator> pRowBreakIter(pDoc->GetRowBreakIterator(nPrintTab));
+ std::unique_ptr<ScRowBreakIterator> pRowBreakIter(pDoc->GetRowBreakIterator(nPrintTab));
SCROW nNextPageBreak = pRowBreakIter->first();
while (nNextPageBreak != ScRowBreakIterator::NOT_FOUND && nNextPageBreak < nStartRow)
// Skip until the page break position is at the start row or greater.
diff --git a/sc/source/ui/view/scextopt.cxx b/sc/source/ui/view/scextopt.cxx
index 47be2d29991a..dea6e14a6d1b 100644
--- a/sc/source/ui/view/scextopt.cxx
+++ b/sc/source/ui/view/scextopt.cxx
@@ -21,9 +21,9 @@
#include <osl/diagnose.h>
-#include <vector>
#include <map>
-#include <boost/shared_ptr.hpp>
+#include <memory>
+#include <vector>
ScExtDocSettings::ScExtDocSettings() :
mfTabBarWidth( -1.0 ),
@@ -67,7 +67,7 @@ public:
SCTAB GetLastTab() const;
private:
- typedef ::boost::shared_ptr< ScExtTabSettings > ScExtTabSettingsRef;
+ typedef std::shared_ptr< ScExtTabSettings > ScExtTabSettingsRef;
typedef ::std::map< SCTAB, ScExtTabSettingsRef > ScExtTabSettingsMap;
/** Makes a deep copy of all objects in the passed map. */
diff --git a/sc/source/ui/view/spelleng.cxx b/sc/source/ui/view/spelleng.cxx
index 4621b6984deb..dc838e234db5 100644
--- a/sc/source/ui/view/spelleng.cxx
+++ b/sc/source/ui/view/spelleng.cxx
@@ -40,7 +40,7 @@
#include "globstr.hrc"
#include "markdata.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace ::com::sun::star;
@@ -82,7 +82,7 @@ bool ScConversionEngineBase::FindNextConversionCell()
const ScPatternAttr* pPattern = NULL;
const ScPatternAttr* pLastPattern = NULL;
- boost::scoped_ptr<SfxItemSet> pEditDefaults(new SfxItemSet(GetEmptyItemSet()));
+ std::unique_ptr<SfxItemSet> pEditDefaults(new SfxItemSet(GetEmptyItemSet()));
if( IsModified() )
{
@@ -112,7 +112,7 @@ bool ScConversionEngineBase::FindNextConversionCell()
if (eCellType == CELLTYPE_EDIT)
{
- boost::scoped_ptr<EditTextObject> pEditObj(CreateTextObject());
+ std::unique_ptr<EditTextObject> pEditObj(CreateTextObject());
mrDoc.SetEditText(aPos, *pEditObj, GetEditTextObjectPool());
}
else
diff --git a/sc/source/ui/view/tabvwsh3.cxx b/sc/source/ui/view/tabvwsh3.cxx
index 436f569414ed..569f578cbdb9 100644
--- a/sc/source/ui/view/tabvwsh3.cxx
+++ b/sc/source/ui/view/tabvwsh3.cxx
@@ -67,7 +67,7 @@
#include <comphelper/string.hxx>
#include "scabstdlg.hxx"
-#include <boost/scoped_ptr.hpp>
+#include <memory>
static sal_uInt16 lcl_ParseRange(ScRange& rScRange, const OUString& aAddress, ScDocument* pDoc, sal_uInt16 /* nSlot */)
{
@@ -659,7 +659,7 @@ void ScTabViewShell::Execute( SfxRequest& rReq )
{
SfxItemSet aSet ( GetPool(), SID_ATTR_ZOOM, SID_ATTR_ZOOM );
SvxZoomItem aZoomItem( eOldZoomType, nOldZoom, SID_ATTR_ZOOM );
- boost::scoped_ptr<AbstractSvxZoomDialog> pDlg;
+ std::unique_ptr<AbstractSvxZoomDialog> pDlg;
ScMarkData& rMark = GetViewData().GetMarkData();
SvxZoomEnableFlags nBtnFlags = SvxZoomEnableFlags::N50
| SvxZoomEnableFlags::N75
@@ -802,7 +802,7 @@ void ScTabViewShell::Execute( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScShowTabDlg> pDlg(pFact->CreateScShowTabDlg(GetDialogParent()));
+ std::unique_ptr<AbstractScShowTabDlg> pDlg(pFact->CreateScShowTabDlg(GetDialogParent()));
OSL_ENSURE(pDlg, "Dialog create fail!");
pDlg->SetDescription(
OUString( ScResId( STR_DLG_SELECTTABLES_TITLE ) ),
diff --git a/sc/source/ui/view/tabvwsha.cxx b/sc/source/ui/view/tabvwsha.cxx
index e8e7ca5d2587..f6ac626e1679 100644
--- a/sc/source/ui/view/tabvwsha.cxx
+++ b/sc/source/ui/view/tabvwsha.cxx
@@ -57,7 +57,7 @@
#include <com/sun/star/table/BorderLineStyle.hpp>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace com::sun::star;
@@ -457,9 +457,9 @@ void ScTabViewShell::ExecuteCellFormatDlg(SfxRequest& rReq, const OString &rName
const ScPatternAttr* pOldAttrs = GetSelectionPattern();
- boost::scoped_ptr<SfxAbstractTabDialog> pDlg;
- boost::scoped_ptr<SfxItemSet> pOldSet(new SfxItemSet(pOldAttrs->GetItemSet()));
- boost::scoped_ptr<SvxNumberInfoItem> pNumberInfoItem;
+ std::unique_ptr<SfxAbstractTabDialog> pDlg;
+ std::unique_ptr<SfxItemSet> pOldSet(new SfxItemSet(pOldAttrs->GetItemSet()));
+ std::unique_ptr<SvxNumberInfoItem> pNumberInfoItem;
pOldSet->MergeRange(SID_ATTR_BORDER_STYLES, SID_ATTR_BORDER_DEFAULT_WIDTH);
@@ -565,7 +565,7 @@ bool ScTabViewShell::IsRefInputMode() const
ScCompiler aComp( pDoc, aPos );
aComp.SetGrammar(pDoc->GetGrammar());
aComp.SetCloseBrackets( false );
- boost::scoped_ptr<ScTokenArray> pArr(aComp.CompileString(aString));
+ std::unique_ptr<ScTokenArray> pArr(aComp.CompileString(aString));
if ( pArr && pArr->MayReferenceFollow() )
{
return true;
diff --git a/sc/source/ui/view/tabvwshf.cxx b/sc/source/ui/view/tabvwshf.cxx
index 337531d58077..c3959c606434 100644
--- a/sc/source/ui/view/tabvwshf.cxx
+++ b/sc/source/ui/view/tabvwshf.cxx
@@ -19,7 +19,7 @@
#include <config_features.h>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
#include "scitems.hxx"
#include <sfx2/request.hxx>
@@ -53,7 +53,7 @@
#include <vector>
-using ::boost::scoped_ptr;
+using std::unique_ptr;
using namespace com::sun::star;
void ScTabViewShell::ExecuteTable( SfxRequest& rReq )
@@ -132,7 +132,7 @@ void ScTabViewShell::ExecuteTable( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScShowTabDlg> pDlg(pFact->CreateScShowTabDlg(GetDialogParent()));
+ std::unique_ptr<AbstractScShowTabDlg> pDlg(pFact->CreateScShowTabDlg(GetDialogParent()));
OSL_ENSURE(pDlg, "Dialog create fail!");
OUString aTabName;
@@ -200,7 +200,7 @@ void ScTabViewShell::ExecuteTable( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScInsertTableDlg> pDlg(pFact->CreateScInsertTableDlg(GetDialogParent(), rViewData,
+ std::unique_ptr<AbstractScInsertTableDlg> pDlg(pFact->CreateScInsertTableDlg(GetDialogParent(), rViewData,
nTabSelCount, nSlot == FID_INS_TABLE_EXT));
OSL_ENSURE(pDlg, "Dialog create fail!");
if ( RET_OK == pDlg->Execute() )
@@ -372,7 +372,7 @@ void ScTabViewShell::ExecuteTable( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScStringInputDlg> pDlg(pFact->CreateScStringInputDlg(
+ std::unique_ptr<AbstractScStringInputDlg> pDlg(pFact->CreateScStringInputDlg(
GetDialogParent(), aDlgTitle, OUString(ScResId(SCSTR_NAME)),
aName, GetStaticInterface()->GetSlot(nSlot)->GetCommand(),
pHelpId));
@@ -497,7 +497,7 @@ void ScTabViewShell::ExecuteTable( SfxRequest& rReq )
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScMoveTableDlg> pDlg(pFact->CreateScMoveTableDlg(GetDialogParent(),
+ std::unique_ptr<AbstractScMoveTableDlg> pDlg(pFact->CreateScMoveTableDlg(GetDialogParent(),
aDefaultName));
OSL_ENSURE(pDlg, "Dialog create fail!");
@@ -664,7 +664,7 @@ void ScTabViewShell::ExecuteTable( SfxRequest& rReq )
if ( nTabSelCount > 1 )
{
- scoped_ptr<ScUndoTabColorInfo::List>
+ std::unique_ptr<ScUndoTabColorInfo::List>
pTabColorList(new ScUndoTabColorInfo::List);
ScMarkData::iterator itr = rMark.begin(), itrEnd = rMark.end();
for (; itr != itrEnd; ++itr)
@@ -696,7 +696,7 @@ void ScTabViewShell::ExecuteTable( SfxRequest& rReq )
aTabBgColor = pDoc->GetTabBgColor( nCurrentTab );
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
OSL_ENSURE(pFact, "ScAbstractFactory create fail!");
- boost::scoped_ptr<AbstractScTabBgColorDlg> pDlg(pFact->CreateScTabBgColorDlg(
+ std::unique_ptr<AbstractScTabBgColorDlg> pDlg(pFact->CreateScTabBgColorDlg(
GetDialogParent(),
OUString(ScResId(SCSTR_SET_TAB_BG_COLOR)),
OUString(ScResId(SCSTR_NO_TAB_BG_COLOR)),
@@ -709,7 +709,7 @@ void ScTabViewShell::ExecuteTable( SfxRequest& rReq )
{
Color aSelectedColor;
pDlg->GetSelectedColor(aSelectedColor);
- scoped_ptr<ScUndoTabColorInfo::List>
+ std::unique_ptr<ScUndoTabColorInfo::List>
pTabColorList(new ScUndoTabColorInfo::List);
if ( nTabSelCount > 1 )
{
@@ -757,7 +757,7 @@ void ScTabViewShell::ExecuteTable( SfxRequest& rReq )
SvxAbstractDialogFactory* pDlgFactory = SvxAbstractDialogFactory::Create();
if (pDlgFactory)
{
- boost::scoped_ptr<VclAbstractDialog> pDialog( pDlgFactory->CreateSvxMacroAssignDlg(
+ std::unique_ptr<VclAbstractDialog> pDialog( pDlgFactory->CreateSvxMacroAssignDlg(
GetDialogParent(), xFrame, false, xEvents, 0 ) );
if ( pDialog.get() && pDialog->Execute() == RET_OK )
{
diff --git a/sc/source/ui/view/tabvwshh.cxx b/sc/source/ui/view/tabvwshh.cxx
index 4d32414b5db1..a2ca96ec6883 100644
--- a/sc/source/ui/view/tabvwshh.cxx
+++ b/sc/source/ui/view/tabvwshh.cxx
@@ -38,8 +38,6 @@
#include "retypepassdlg.hxx"
#include "tabprotection.hxx"
-#include <boost/scoped_ptr.hpp>
-
using namespace com::sun::star;
void ScTabViewShell::ExecuteSbx( SfxRequest& /* rReq */ )
diff --git a/sc/source/ui/view/viewfun2.cxx b/sc/source/ui/view/viewfun2.cxx
index 8aa822e0a3d4..bc1488f8aed2 100644
--- a/sc/source/ui/view/viewfun2.cxx
+++ b/sc/source/ui/view/viewfun2.cxx
@@ -86,7 +86,6 @@
#include <rowheightcontext.hxx>
#include <LibreOfficeKit/LibreOfficeKitEnums.h>
-#include <boost/scoped_ptr.hpp>
#include <vector>
#include <memory>
@@ -689,7 +688,7 @@ OUString ScViewFunc::GetAutoSumFormula( const ScRangeList& rRangeList, bool bSub
{
ScViewData& rViewData = GetViewData();
ScDocument* pDoc = rViewData.GetDocument();
- ::boost::scoped_ptr<ScTokenArray> pArray(new ScTokenArray);
+ std::unique_ptr<ScTokenArray> pArray(new ScTokenArray);
pArray->AddOpCode(bSubTotal ? ocSubTotal : ocSum);
pArray->AddOpCode(ocOpen);
@@ -774,7 +773,7 @@ void ScViewFunc::EnterBlock( const OUString& rString, const EditTextObject* pDat
ScAddress aPos( nCol, nRow, nTab );
- boost::scoped_ptr<ScDocument> pInsDoc(new ScDocument( SCDOCMODE_CLIP ));
+ std::unique_ptr<ScDocument> pInsDoc(new ScDocument( SCDOCMODE_CLIP ));
pInsDoc->ResetClip( pDoc, nTab );
if (aNewStr[0] == '=') // Formula ?
@@ -802,7 +801,7 @@ void ScViewFunc::EnterBlock( const OUString& rString, const EditTextObject* pDat
// MarkData was already MarkToSimple'ed in PasteFromClip
ScRange aRange;
rMark.GetMarkArea( aRange );
- boost::scoped_ptr<ScPatternAttr> pPattern(new ScPatternAttr( pDoc->GetPool() ));
+ std::unique_ptr<ScPatternAttr> pPattern(new ScPatternAttr( pDoc->GetPool() ));
pPattern->GetItemSet().Put( *pItem );
short nNewType = pDoc->GetFormatTable()->GetType( pItem->GetValue() );
pDoc->ApplyPatternIfNumberformatIncompatible( aRange, rMark,
@@ -3044,11 +3043,11 @@ void ScViewFunc::SetSelectionFrameLines( const SvxBorderLine* pLine,
// none of the lines don't care?
if( (eItemState != SfxItemState::DONTCARE) && (eTLBRState != SfxItemState::DONTCARE) && (eBLTRState != SfxItemState::DONTCARE) )
{
- boost::scoped_ptr<SfxItemSet> pOldSet(new SfxItemSet(
+ std::unique_ptr<SfxItemSet> pOldSet(new SfxItemSet(
*(pDoc->GetPool()),
ATTR_PATTERN_START,
ATTR_PATTERN_END ));
- boost::scoped_ptr<SfxItemSet> pNewSet(new SfxItemSet(
+ std::unique_ptr<SfxItemSet> pNewSet(new SfxItemSet(
*(pDoc->GetPool()),
ATTR_PATTERN_START,
ATTR_PATTERN_END ));
diff --git a/sc/source/ui/view/viewfun3.cxx b/sc/source/ui/view/viewfun3.cxx
index e6227831651b..1ffe6ca227e6 100644
--- a/sc/source/ui/view/viewfun3.cxx
+++ b/sc/source/ui/view/viewfun3.cxx
@@ -67,7 +67,7 @@
#include "drawview.hxx"
#include "cliputil.hxx"
#include <gridwin.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace com::sun::star;
@@ -1246,7 +1246,7 @@ bool ScViewFunc::PasteFromClip( InsertDeleteFlags nFlags, ScDocument* pClipDoc,
// copy from clipboard
// save original data in case of calculation
- boost::scoped_ptr<ScDocument> pMixDoc;
+ std::unique_ptr<ScDocument> pMixDoc;
if (nFunction)
{
bSkipEmpty = false;
@@ -1666,7 +1666,7 @@ bool ScViewFunc::PasteFromClipToMultiRanges(
}
}
- boost::scoped_ptr<ScDocument> pMixDoc;
+ std::unique_ptr<ScDocument> pMixDoc;
if (bSkipEmpty || nFunction)
{
if (nFlags & IDF_CONTENTS)
@@ -1886,7 +1886,7 @@ bool ScViewFunc::LinkBlock( const ScRange& rSource, const ScAddress& rDestPos, b
// run with paste
ScDocument* pDoc = GetViewData().GetDocument();
- boost::scoped_ptr<ScDocument> pClipDoc(new ScDocument( SCDOCMODE_CLIP ));
+ std::unique_ptr<ScDocument> pClipDoc(new ScDocument( SCDOCMODE_CLIP ));
pDoc->CopyTabToClip( rSource.aStart.Col(), rSource.aStart.Row(),
rSource.aEnd.Col(), rSource.aEnd.Row(),
rSource.aStart.Tab(), pClipDoc.get() );
diff --git a/sc/source/ui/view/viewfun4.cxx b/sc/source/ui/view/viewfun4.cxx
index c071a8c2c0a1..31c17f968a61 100644
--- a/sc/source/ui/view/viewfun4.cxx
+++ b/sc/source/ui/view/viewfun4.cxx
@@ -70,8 +70,6 @@
#include <refupdatecontext.hxx>
#include <gridwin.hxx>
-#include <boost/scoped_ptr.hpp>
-
using namespace com::sun::star;
// STATIC DATA -----------------------------------------------------------
@@ -93,7 +91,7 @@ void ScViewFunc::PasteRTF( SCCOL nStartCol, SCROW nStartRow,
const bool bRecord (rDoc.IsUndoEnabled());
const ScPatternAttr* pPattern = rDoc.GetPattern( nStartCol, nStartRow, nTab );
- boost::scoped_ptr<ScTabEditEngine> pEngine(new ScTabEditEngine( *pPattern, rDoc.GetEnginePool() ));
+ std::unique_ptr<ScTabEditEngine> pEngine(new ScTabEditEngine( *pPattern, rDoc.GetEnginePool() ));
pEngine->EnableUndo( false );
vcl::Window* pActWin = GetActiveWin();
@@ -131,7 +129,7 @@ void ScViewFunc::PasteRTF( SCCOL nStartCol, SCROW nStartRow,
rDoc.EnableUndo( false );
for( sal_Int32 n = 0; n < nParCnt; n++ )
{
- boost::scoped_ptr<EditTextObject> pObject(pEngine->CreateTextObject(n));
+ std::unique_ptr<EditTextObject> pObject(pEngine->CreateTextObject(n));
EnterData(nStartCol, nRow, nTab, *pObject, true);
if( ++nRow > MAXROW )
break;
@@ -259,7 +257,7 @@ void ScViewFunc::DoRefConversion( bool bRecord )
OUString aNew = aFinder.GetText();
ScCompiler aComp( pDoc, aPos);
aComp.SetGrammar(pDoc->GetGrammar());
- boost::scoped_ptr<ScTokenArray> pArr(aComp.CompileString(aNew));
+ std::unique_ptr<ScTokenArray> pArr(aComp.CompileString(aNew));
ScFormulaCell* pNewCell =
new ScFormulaCell(
pDoc, aPos, *pArr, formula::FormulaGrammar::GRAM_DEFAULT, MM_NONE);
@@ -313,8 +311,8 @@ void ScViewFunc::DoThesaurus( bool bRecord )
ScSplitPos eWhich = GetViewData().GetActivePart();
EESpellState eState;
EditView* pEditView = NULL;
- boost::scoped_ptr<ESelection> pEditSel;
- boost::scoped_ptr<ScEditEngineDefaulter> pThesaurusEngine;
+ std::unique_ptr<ESelection> pEditSel;
+ std::unique_ptr<ScEditEngineDefaulter> pThesaurusEngine;
bool bIsEditMode = GetViewData().HasEditView(eWhich);
if (bRecord && !rDoc.IsUndoEnabled())
bRecord = false;
@@ -356,7 +354,7 @@ void ScViewFunc::DoThesaurus( bool bRecord )
pThesaurusEngine->SetSpeller(xSpeller);
MakeEditView(pThesaurusEngine.get(), nCol, nRow );
const ScPatternAttr* pPattern = NULL;
- boost::scoped_ptr<SfxItemSet> pEditDefaults(
+ std::unique_ptr<SfxItemSet> pEditDefaults(
new SfxItemSet(pThesaurusEngine->GetEmptyItemSet()));
pPattern = rDoc.GetPattern(nCol, nRow, nTab);
if (pPattern)
@@ -496,7 +494,7 @@ void ScViewFunc::DoSheetConversion( const ScConversionParam& rConvParam, bool bR
// *** create and init the edit engine *** --------------------------------
- boost::scoped_ptr<ScConversionEngineBase> pEngine;
+ std::unique_ptr<ScConversionEngineBase> pEngine;
switch( rConvParam.GetType() )
{
case SC_CONVERSION_SPELLCHECK:
@@ -739,7 +737,7 @@ void ScViewFunc::InsertBookmark( const OUString& rDescription, const OUString& r
aField.SetTargetFrame(*pTarget);
aEngine.QuickInsertField( SvxFieldItem( aField, EE_FEATURE_FIELD ), aInsSel );
- boost::scoped_ptr<EditTextObject> pData(aEngine.CreateTextObject());
+ std::unique_ptr<EditTextObject> pData(aEngine.CreateTextObject());
EnterData(nPosX, nPosY, nTab, *pData);
}
diff --git a/sc/source/ui/view/viewfun5.cxx b/sc/source/ui/view/viewfun5.cxx
index cfd2dc0ae653..edd2dd67adae 100644
--- a/sc/source/ui/view/viewfun5.cxx
+++ b/sc/source/ui/view/viewfun5.cxx
@@ -67,7 +67,7 @@
#include <vcl/msgbox.hxx>
#include <sfx2/viewfrm.hxx>
#include <svx/dbaexchange.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
using namespace com::sun::star;
@@ -140,7 +140,7 @@ bool ScViewFunc::PasteDataFormat( SotClipboardFormatId nFormatId,
ScMarkData aSrcMark;
aSrcMark.SelectOneTable( nSrcTab ); // for CopyToClip
- boost::scoped_ptr<ScDocument> pClipDoc(new ScDocument( SCDOCMODE_CLIP ));
+ std::unique_ptr<ScDocument> pClipDoc(new ScDocument( SCDOCMODE_CLIP ));
SCCOL nFirstCol, nLastCol;
SCROW nFirstRow, nLastRow;
@@ -306,7 +306,7 @@ bool ScViewFunc::PasteDataFormat( SotClipboardFormatId nFormatId,
// this for html pasting only, but in the future it may
// make sense to do it for other data types too.
ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create();
- boost::scoped_ptr<AbstractScTextImportOptionsDlg> pDlg(
+ std::unique_ptr<AbstractScTextImportOptionsDlg> pDlg(
pFact->CreateScTextImportOptionsDlg(NULL));
if (pDlg->Execute() == RET_OK)
@@ -335,7 +335,7 @@ bool ScViewFunc::PasteDataFormat( SotClipboardFormatId nFormatId,
ScImportStringStream aStrm( aStr);
ScAbstractDialogFactory* pFact =
ScAbstractDialogFactory::Create();
- boost::scoped_ptr<AbstractScImportAsciiDlg> pDlg(
+ std::unique_ptr<AbstractScImportAsciiDlg> pDlg(
pFact->CreateScImportAsciiDlg( NULL, OUString(), &aStrm,
SC_PASTETEXT));
@@ -492,7 +492,7 @@ bool ScViewFunc::PasteDataFormat( SotClipboardFormatId nFormatId,
ScDocShellRef aDragShellRef( new ScDocShell );
aDragShellRef->DoInitNew(NULL);
- boost::scoped_ptr<FmFormModel> pModel(new FmFormModel( aPath, NULL, aDragShellRef ));
+ std::unique_ptr<FmFormModel> pModel(new FmFormModel( aPath, NULL, aDragShellRef ));
pModel->GetItemPool().FreezeIdRanges();
xStm->Seek(0);
diff --git a/sc/source/ui/view/viewfunc.cxx b/sc/source/ui/view/viewfunc.cxx
index 7375f184e4a3..1dd1cb45b0dc 100644
--- a/sc/source/ui/view/viewfunc.cxx
+++ b/sc/source/ui/view/viewfunc.cxx
@@ -78,7 +78,7 @@
#include <rowheightcontext.hxx>
#include <docfuncutil.hxx>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
static void lcl_PostRepaintCondFormat( const ScConditionalFormat *pCondFmt, ScDocShell *pDocSh )
{
@@ -626,7 +626,7 @@ void ScViewFunc::EnterData( SCCOL nCol, SCROW nRow, SCTAB nTab,
bool bSimple = false;
bool bCommon = false;
- boost::scoped_ptr<ScPatternAttr> pCellAttrs;
+ std::unique_ptr<ScPatternAttr> pCellAttrs;
OUString aString;
const ScPatternAttr* pOldPattern = rDoc.GetPattern( nCol, nRow, nTab );
@@ -1201,7 +1201,7 @@ void ScViewFunc::ApplySelectionPattern( const ScPatternAttr& rAttr,
}
aChangeRanges.Append(aPos);
- boost::scoped_ptr<ScPatternAttr> pOldPat(new ScPatternAttr(*rDoc.GetPattern( nCol, nRow, nTab )));
+ std::unique_ptr<ScPatternAttr> pOldPat(new ScPatternAttr(*rDoc.GetPattern( nCol, nRow, nTab )));
rDoc.ApplyPattern( nCol, nRow, nTab, rAttr );
diff --git a/sc/source/ui/view/viewutil.cxx b/sc/source/ui/view/viewutil.cxx
index b70211e40395..5747d0592e13 100644
--- a/sc/source/ui/view/viewutil.cxx
+++ b/sc/source/ui/view/viewutil.cxx
@@ -49,7 +49,7 @@
#include <svx/svxdlg.hxx>
#include <svx/dialogs.hrc>
-#include <boost/scoped_ptr.hpp>
+#include <memory>
void ScViewUtil::PutItemScript( SfxItemSet& rShellSet, const SfxItemSet& rCoreSet,
sal_uInt16 nWhichId, SvtScriptType nScript )
@@ -350,7 +350,7 @@ bool ScViewUtil::ExecuteCharMap( const SvxFontItem& rOldFont,
SfxAllItemSet aSet( rFrame.GetObjectShell()->GetPool() );
aSet.Put( SfxBoolItem( FN_PARAM_1, false ) );
aSet.Put( SvxFontItem( rOldFont.GetFamily(), rOldFont.GetFamilyName(), rOldFont.GetStyleName(), rOldFont.GetPitch(), rOldFont.GetCharSet(), aSet.GetPool()->GetWhich( SID_ATTR_CHAR_FONT ) ) );
- boost::scoped_ptr<SfxAbstractDialog> pDlg(pFact->CreateSfxDialog( &rFrame.GetWindow(), aSet, rFrame.GetFrame().GetFrameInterface(), RID_SVXDLG_CHARMAP ));
+ std::unique_ptr<SfxAbstractDialog> pDlg(pFact->CreateSfxDialog( &rFrame.GetWindow(), aSet, rFrame.GetFrame().GetFrameInterface(), RID_SVXDLG_CHARMAP ));
if ( pDlg->Execute() == RET_OK )
{
SFX_ITEMSET_ARG( pDlg->GetOutputItemSet(), pItem, SfxStringItem, SID_CHARMAP, false );