summaryrefslogtreecommitdiff
path: root/vcl/source
diff options
context:
space:
mode:
Diffstat (limited to 'vcl/source')
-rw-r--r--vcl/source/app/salvtables.cxx2
-rw-r--r--vcl/source/app/settings.cxx4
-rw-r--r--vcl/source/app/svmain.cxx4
-rw-r--r--vcl/source/control/button.cxx2
-rw-r--r--vcl/source/filter/graphicfilter.cxx10
-rw-r--r--vcl/source/filter/wmf/wmf.cxx6
-rw-r--r--vcl/source/gdi/graph.cxx2
-rw-r--r--vcl/source/gdi/impgraph.cxx2
-rw-r--r--vcl/source/gdi/print.cxx4
-rw-r--r--vcl/source/gdi/print3.cxx2
-rw-r--r--vcl/source/gdi/region.cxx14
-rw-r--r--vcl/source/gdi/virdev.cxx2
-rw-r--r--vcl/source/outdev/font.cxx2
-rw-r--r--vcl/source/outdev/nativecontrols.cxx2
-rw-r--r--vcl/source/window/builder.cxx2
15 files changed, 30 insertions, 30 deletions
diff --git a/vcl/source/app/salvtables.cxx b/vcl/source/app/salvtables.cxx
index a8f90b24afdd..687c0d63723a 100644
--- a/vcl/source/app/salvtables.cxx
+++ b/vcl/source/app/salvtables.cxx
@@ -1235,7 +1235,7 @@ private:
std::shared_ptr<VclSizeGroup> m_xGroup;
public:
SalInstanceSizeGroup()
- : m_xGroup(new VclSizeGroup)
+ : m_xGroup(std::make_shared<VclSizeGroup>())
{
}
virtual void add_widget(weld::Widget* pWidget) override
diff --git a/vcl/source/app/settings.cxx b/vcl/source/app/settings.cxx
index 30e9616740a3..59962b2bdd30 100644
--- a/vcl/source/app/settings.cxx
+++ b/vcl/source/app/settings.cxx
@@ -466,7 +466,7 @@ ImplStyleData::ImplStyleData() :
mbAutoMnemonic(true),
meUseImagesInMenus(TRISTATE_INDET),
mnMinThumbSize(16),
- mIconThemeSelector(new vcl::IconThemeSelector()),
+ mIconThemeSelector(std::make_shared<vcl::IconThemeSelector>()),
meContextMenuShortcuts(TRISTATE_INDET),
mnEdgeBlending(35),
maEdgeBlendingTopLeftColor(Color(0xC0, 0xC0, 0xC0)),
@@ -579,7 +579,7 @@ ImplStyleData::ImplStyleData( const ImplStyleData& rData ) :
mbPreferredUseImagesInMenus(rData.mbPreferredUseImagesInMenus),
mnMinThumbSize(rData.mnMinThumbSize),
mIconThemeScanner(rData.mIconThemeScanner?new vcl::IconThemeScanner(*rData.mIconThemeScanner):nullptr),
- mIconThemeSelector(new vcl::IconThemeSelector(*rData.mIconThemeSelector)),
+ mIconThemeSelector(std::make_shared<vcl::IconThemeSelector>(*rData.mIconThemeSelector)),
mIconTheme(rData.mIconTheme),
mbSkipDisabledInMenus(rData.mbSkipDisabledInMenus),
mbHideDisabledMenuItems(rData.mbHideDisabledMenuItems),
diff --git a/vcl/source/app/svmain.cxx b/vcl/source/app/svmain.cxx
index 998ece19dc21..23663c56ad9d 100644
--- a/vcl/source/app/svmain.cxx
+++ b/vcl/source/app/svmain.cxx
@@ -355,8 +355,8 @@ bool InitVCL()
pSVData->maAppData.mxAppFileName = aNativeFileName;
// Initialize global data
- pSVData->maGDIData.mxScreenFontList.reset(new PhysicalFontCollection);
- pSVData->maGDIData.mxScreenFontCache.reset(new ImplFontCache);
+ pSVData->maGDIData.mxScreenFontList = std::make_shared<PhysicalFontCollection>();
+ pSVData->maGDIData.mxScreenFontCache = std::make_shared<ImplFontCache>();
pSVData->maGDIData.mpGrfConverter = new GraphicConverter;
g_bIsLeanException = getenv("LO_LEAN_EXCEPTION") != nullptr;
diff --git a/vcl/source/control/button.cxx b/vcl/source/control/button.cxx
index e35ab9de4ef6..7aebb0d1397f 100644
--- a/vcl/source/control/button.cxx
+++ b/vcl/source/control/button.cxx
@@ -2082,7 +2082,7 @@ void RadioButton::group(RadioButton &rOther)
if (!m_xGroup)
{
- m_xGroup.reset(new std::vector<VclPtr<RadioButton> >);
+ m_xGroup = std::make_shared<std::vector<VclPtr<RadioButton> >>();
m_xGroup->push_back(this);
}
diff --git a/vcl/source/filter/graphicfilter.cxx b/vcl/source/filter/graphicfilter.cxx
index 20dd734bb30c..4a2dae41dd20 100644
--- a/vcl/source/filter/graphicfilter.cxx
+++ b/vcl/source/filter/graphicfilter.cxx
@@ -1661,7 +1661,7 @@ ErrCode GraphicFilter::ImportGraphic( Graphic& rGraphic, const OUString& rPath,
if(!aMemStream.GetError() )
{
- VectorGraphicDataPtr aVectorGraphicDataPtr(new VectorGraphicData(aNewData, rPath, VectorGraphicDataType::Svg));
+ VectorGraphicDataPtr aVectorGraphicDataPtr = std::make_shared<VectorGraphicData>(aNewData, rPath, VectorGraphicDataType::Svg);
rGraphic = Graphic(aVectorGraphicDataPtr);
bOkay = true;
}
@@ -1674,7 +1674,7 @@ ErrCode GraphicFilter::ImportGraphic( Graphic& rGraphic, const OUString& rPath,
if(!rIStream.GetError())
{
- VectorGraphicDataPtr aVectorGraphicDataPtr(new VectorGraphicData(aNewData, rPath, VectorGraphicDataType::Svg));
+ VectorGraphicDataPtr aVectorGraphicDataPtr = std::make_shared<VectorGraphicData>(aNewData, rPath, VectorGraphicDataType::Svg);
rGraphic = Graphic(aVectorGraphicDataPtr);
bOkay = true;
}
@@ -1744,11 +1744,11 @@ ErrCode GraphicFilter::ImportGraphic( Graphic& rGraphic, const OUString& rPath,
{
const bool bIsWmf(aFilterName.equalsIgnoreAsciiCase(IMP_WMF));
const VectorGraphicDataType aDataType(bIsWmf ? VectorGraphicDataType::Wmf : VectorGraphicDataType::Emf);
- VectorGraphicDataPtr aVectorGraphicDataPtr(
- new VectorGraphicData(
+ VectorGraphicDataPtr aVectorGraphicDataPtr =
+ std::make_shared<VectorGraphicData>(
aNewData,
rPath,
- aDataType));
+ aDataType);
if (pExtHeader)
{
diff --git a/vcl/source/filter/wmf/wmf.cxx b/vcl/source/filter/wmf/wmf.cxx
index d0fe5fa0ce22..3b9156ac84a1 100644
--- a/vcl/source/filter/wmf/wmf.cxx
+++ b/vcl/source/filter/wmf/wmf.cxx
@@ -49,11 +49,11 @@ bool ReadWindowMetafile( SvStream& rStream, GDIMetaFile& rMTF )
// Throw into VectorGraphicData to get the import. Do not care
// too much for type, this will be checked there. Also no path
// needed, it is a temporary object
- VectorGraphicDataPtr aVectorGraphicDataPtr(
- new VectorGraphicData(
+ VectorGraphicDataPtr aVectorGraphicDataPtr =
+ std::make_shared<VectorGraphicData>(
aNewData,
OUString(),
- VectorGraphicDataType::Emf));
+ VectorGraphicDataType::Emf);
// create a Graphic and grep Metafile from it
const Graphic aGraphic(aVectorGraphicDataPtr);
diff --git a/vcl/source/gdi/graph.cxx b/vcl/source/gdi/graph.cxx
index ec2de64a74fe..01e99662ff88 100644
--- a/vcl/source/gdi/graph.cxx
+++ b/vcl/source/gdi/graph.cxx
@@ -215,7 +215,7 @@ Graphic::Graphic(const BitmapEx& rBmpEx)
// and we need to be able to see and preserve 'stock' images too.
Graphic::Graphic(const Image& rImage)
// FIXME: should really defer the BitmapEx load.
- : mxImpGraphic(new ImpGraphic(rImage.GetBitmapEx()))
+ : mxImpGraphic(std::make_shared<ImpGraphic>(rImage.GetBitmapEx()))
{
OUString aStock = rImage.GetStock();
if (aStock.getLength())
diff --git a/vcl/source/gdi/impgraph.cxx b/vcl/source/gdi/impgraph.cxx
index 067497301e02..f8292b30fd05 100644
--- a/vcl/source/gdi/impgraph.cxx
+++ b/vcl/source/gdi/impgraph.cxx
@@ -1906,7 +1906,7 @@ void ReadImpGraphic( SvStream& rIStm, ImpGraphic& rImpGraphic )
aDataType = VectorGraphicDataType::Emf;
}
- VectorGraphicDataPtr aVectorGraphicDataPtr(new VectorGraphicData(aNewData, aPath, aDataType));
+ VectorGraphicDataPtr aVectorGraphicDataPtr = std::make_shared<VectorGraphicData>(aNewData, aPath, aDataType);
rImpGraphic = aVectorGraphicDataPtr;
}
}
diff --git a/vcl/source/gdi/print.cxx b/vcl/source/gdi/print.cxx
index e80fc25d777b..364f0af35587 100644
--- a/vcl/source/gdi/print.cxx
+++ b/vcl/source/gdi/print.cxx
@@ -661,8 +661,8 @@ void Printer::ImplInit( SalPrinterQueueInfo* pInfo )
// Init data
ImplUpdatePageData();
- mxFontCollection.reset(new PhysicalFontCollection);
- mxFontCache.reset(new ImplFontCache);
+ mxFontCollection = std::make_shared<PhysicalFontCollection>();
+ mxFontCache = std::make_shared<ImplFontCache>();
mpGraphics->GetDevFontList(mxFontCollection.get());
}
diff --git a/vcl/source/gdi/print3.cxx b/vcl/source/gdi/print3.cxx
index 0b2721b718cf..8a96ec81e5c5 100644
--- a/vcl/source/gdi/print3.cxx
+++ b/vcl/source/gdi/print3.cxx
@@ -1699,7 +1699,7 @@ void PrinterController::createProgressDialog()
if( bShow && ! Application::IsHeadlessModeEnabled() )
{
- mpImplData->mxProgress.reset(new PrintProgressDialog(getWindow(), getPageCountProtected()));
+ mpImplData->mxProgress = std::make_shared<PrintProgressDialog>(getWindow(), getPageCountProtected());
weld::DialogController::runAsync(mpImplData->mxProgress, [](sal_Int32 /*nResult*/){});
}
}
diff --git a/vcl/source/gdi/region.cxx b/vcl/source/gdi/region.cxx
index 4f830a2195e8..42fc0c0b1c4a 100644
--- a/vcl/source/gdi/region.cxx
+++ b/vcl/source/gdi/region.cxx
@@ -390,11 +390,11 @@ void vcl::Region::ImplCreatePolyPolyRegion( const tools::PolyPolygon& rPolyPoly
// width OR height == 1 ? => Rectangular region
if((1 == aRect.GetWidth()) || (1 == aRect.GetHeight()) || rPolyPoly.IsRect())
{
- mpRegionBand.reset(new RegionBand(aRect));
+ mpRegionBand = std::make_shared<RegionBand>(aRect);
}
else
{
- mpPolyPolygon.reset(new tools::PolyPolygon(rPolyPoly));
+ mpPolyPolygon = std::make_shared<tools::PolyPolygon>(rPolyPoly);
}
mbIsNull = false;
@@ -406,7 +406,7 @@ void vcl::Region::ImplCreatePolyPolyRegion( const basegfx::B2DPolyPolygon& rPoly
{
if(rPolyPoly.count() && !rPolyPoly.getB2DRange().isEmpty())
{
- mpB2DPolyPolygon.reset(new basegfx::B2DPolyPolygon(rPolyPoly));
+ mpB2DPolyPolygon = std::make_shared<basegfx::B2DPolyPolygon>(rPolyPoly);
mbIsNull = false;
}
}
@@ -1269,7 +1269,7 @@ tools::PolyPolygon vcl::Region::GetAsPolyPolygon() const
{
// the polygon needs to be converted, buffer the down conversion
const tools::PolyPolygon aPolyPolgon(*getB2DPolyPolygon());
- const_cast< vcl::Region* >(this)->mpPolyPolygon.reset(new tools::PolyPolygon(aPolyPolgon));
+ const_cast< vcl::Region* >(this)->mpPolyPolygon = std::make_shared<tools::PolyPolygon>(aPolyPolgon);
return *getPolyPolygon();
}
@@ -1278,7 +1278,7 @@ tools::PolyPolygon vcl::Region::GetAsPolyPolygon() const
{
// the BandRegion needs to be converted, buffer the conversion
const tools::PolyPolygon aPolyPolgon(ImplCreatePolyPolygonFromRegionBand());
- const_cast< vcl::Region* >(this)->mpPolyPolygon.reset(new tools::PolyPolygon(aPolyPolgon));
+ const_cast< vcl::Region* >(this)->mpPolyPolygon = std::make_shared<tools::PolyPolygon>(aPolyPolgon);
return *getPolyPolygon();
}
@@ -1297,7 +1297,7 @@ basegfx::B2DPolyPolygon vcl::Region::GetAsB2DPolyPolygon() const
{
// the polygon needs to be converted, buffer the up conversion. This will be preferred from now.
const basegfx::B2DPolyPolygon aB2DPolyPolygon(getPolyPolygon()->getB2DPolyPolygon());
- const_cast< vcl::Region* >(this)->mpB2DPolyPolygon.reset(new basegfx::B2DPolyPolygon(aB2DPolyPolygon));
+ const_cast< vcl::Region* >(this)->mpB2DPolyPolygon = std::make_shared<basegfx::B2DPolyPolygon>(aB2DPolyPolygon);
return *getB2DPolyPolygon();
}
@@ -1306,7 +1306,7 @@ basegfx::B2DPolyPolygon vcl::Region::GetAsB2DPolyPolygon() const
{
// the BandRegion needs to be converted, buffer the conversion
const basegfx::B2DPolyPolygon aB2DPolyPolygon(ImplCreateB2DPolyPolygonFromRegionBand());
- const_cast< vcl::Region* >(this)->mpB2DPolyPolygon.reset(new basegfx::B2DPolyPolygon(aB2DPolyPolygon));
+ const_cast< vcl::Region* >(this)->mpB2DPolyPolygon = std::make_shared<basegfx::B2DPolyPolygon>(aB2DPolyPolygon);
return *getB2DPolyPolygon();
}
diff --git a/vcl/source/gdi/virdev.cxx b/vcl/source/gdi/virdev.cxx
index a2bbcdff8f03..0eeab8b8dd44 100644
--- a/vcl/source/gdi/virdev.cxx
+++ b/vcl/source/gdi/virdev.cxx
@@ -482,7 +482,7 @@ void VirtualDevice::ImplSetReferenceDevice( RefDevMode i_eRefDevMode, sal_Int32
mxFontCollection = pSVData->maGDIData.mxScreenFontList->Clone();
// prepare to use new font lists
- mxFontCache.reset(new ImplFontCache);
+ mxFontCache = std::make_shared<ImplFontCache>();
}
sal_uInt16 VirtualDevice::GetBitCount() const
diff --git a/vcl/source/outdev/font.cxx b/vcl/source/outdev/font.cxx
index 91c52398c7ec..d7e0ecaf50af 100644
--- a/vcl/source/outdev/font.cxx
+++ b/vcl/source/outdev/font.cxx
@@ -1476,7 +1476,7 @@ void OutputDevice::SetFontCollectionFromSVData()
void OutputDevice::ResetNewFontCache()
{
- mxFontCache.reset(new ImplFontCache{});
+ mxFontCache = std::make_shared<ImplFontCache>();
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vcl/source/outdev/nativecontrols.cxx b/vcl/source/outdev/nativecontrols.cxx
index 51d4f2882ccc..847cbeb39aa9 100644
--- a/vcl/source/outdev/nativecontrols.cxx
+++ b/vcl/source/outdev/nativecontrols.cxx
@@ -268,7 +268,7 @@ static std::shared_ptr< ImplControlValue > TransformControlValue( const ImplCont
}
break;
case ControlType::Generic:
- aResult.reset( new ImplControlValue( rVal ) );
+ aResult = std::make_shared<ImplControlValue>( rVal );
break;
case ControlType::MenuPopup:
{
diff --git a/vcl/source/window/builder.cxx b/vcl/source/window/builder.cxx
index 63cbe782d435..5017c52cb000 100644
--- a/vcl/source/window/builder.cxx
+++ b/vcl/source/window/builder.cxx
@@ -1688,7 +1688,7 @@ VclBuilder::customMakeWidget GetCustomMakeWidget(const OString& name)
#endif
if (!pFunction)
{
- pModule.reset(new NoAutoUnloadModule);
+ pModule = std::make_shared<NoAutoUnloadModule>();
bool ok = pModule->loadRelative(&thisModule, sModule);
if (!ok)
{