From d96c114171dada05caffd9a50f870809ebd0c450 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Tue, 17 May 2016 13:09:11 +0200 Subject: clang-tidy modernize-make-shared Change-Id: I3fa866bfb3093fc876474a9d9db29fe05dc2af3a Reviewed-on: https://gerrit.libreoffice.org/25056 Tested-by: Jenkins Reviewed-by: Noel Grandin --- sw/source/uibase/frmdlg/colex.cxx | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) (limited to 'sw/source/uibase/frmdlg') diff --git a/sw/source/uibase/frmdlg/colex.cxx b/sw/source/uibase/frmdlg/colex.cxx index 0da911b0ae84..4a42b146c3ad 100644 --- a/sw/source/uibase/frmdlg/colex.cxx +++ b/sw/source/uibase/frmdlg/colex.cxx @@ -135,9 +135,8 @@ void SwPageExample::UpdateExample( const SfxItemSet& rSet ) setSvxBrushItemAsFillAttributesToTargetSet(rItem, aTempSet); setHeaderFillAttributes( - drawinglayer::attribute::SdrAllFillAttributesHelperPtr( - new drawinglayer::attribute::SdrAllFillAttributesHelper( - aTempSet))); + std::make_shared( + aTempSet)); } if ( rHeaderSet.GetItemState( RES_BOX ) == SfxItemState::SET ) @@ -182,9 +181,8 @@ void SwPageExample::UpdateExample( const SfxItemSet& rSet ) setSvxBrushItemAsFillAttributesToTargetSet(rItem, aTempSet); setFooterFillAttributes( - drawinglayer::attribute::SdrAllFillAttributesHelperPtr( - new drawinglayer::attribute::SdrAllFillAttributesHelper( - aTempSet))); + std::make_shared( + aTempSet)); } if( rFooterSet.GetItemState( RES_BOX ) == SfxItemState::SET ) @@ -206,9 +204,8 @@ void SwPageExample::UpdateExample( const SfxItemSet& rSet ) setSvxBrushItemAsFillAttributesToTargetSet(rItem, aTempSet); setPageFillAttributes( - drawinglayer::attribute::SdrAllFillAttributesHelperPtr( - new drawinglayer::attribute::SdrAllFillAttributesHelper( - aTempSet))); + std::make_shared( + aTempSet)); } Invalidate(); @@ -255,8 +252,8 @@ void SwColExample::DrawPage(vcl::RenderContext& rRenderContext, const Point& rOr const Color& rFieldColor = rStyleSettings.GetFieldColor(); setPageFillAttributes( - drawinglayer::attribute::SdrAllFillAttributesHelperPtr( - new drawinglayer::attribute::SdrAllFillAttributesHelper(rFieldColor))); + std::make_shared( + rFieldColor)); } // #97495# make sure that the automatic column width's are always equal -- cgit