cppcanvas/source/mtfrenderer/implrenderer.cxx | 5 +--- cppcanvas/source/mtfrenderer/transparencygroupaction.cxx | 16 +++++++-------- cppcanvas/source/mtfrenderer/transparencygroupaction.hxx | 7 +----- 3 files changed, 12 insertions(+), 16 deletions(-)
New commits: commit c7dfec21b44b23c4e52b938721f356f75046f37b Author: Noel Grandin <noel.gran...@collabora.co.uk> AuthorDate: Thu Jun 15 14:51:52 2023 +0200 Commit: Noel Grandin <noel.gran...@collabora.co.uk> CommitDate: Thu Jun 15 18:14:39 2023 +0200 remove some misleading typedefs Change-Id: I8016c42c3ff8d1cf03c276ebbb68ae7872cd43fd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153119 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk> diff --git a/cppcanvas/source/mtfrenderer/implrenderer.cxx b/cppcanvas/source/mtfrenderer/implrenderer.cxx index 226e62d7eec4..10ccaf1ccdbb 100644 --- a/cppcanvas/source/mtfrenderer/implrenderer.cxx +++ b/cppcanvas/source/mtfrenderer/implrenderer.cxx @@ -2404,12 +2404,11 @@ namespace cppcanvas::internal { MetaFloatTransparentAction* pAct = static_cast<MetaFloatTransparentAction*>(pCurrAct); - internal::MtfAutoPtr pMtf( + std::unique_ptr< GDIMetaFile > pMtf( new ::GDIMetaFile( pAct->GetGDIMetaFile() ) ); // TODO(P2): Use native canvas gradients here (saves a lot of UNO calls) - internal::GradientAutoPtr pGradient( - pAct->GetGradient() ); + std::optional< Gradient > pGradient( pAct->GetGradient() ); DBG_TESTSOLARMUTEX(); diff --git a/cppcanvas/source/mtfrenderer/transparencygroupaction.cxx b/cppcanvas/source/mtfrenderer/transparencygroupaction.cxx index b1dff7cb404f..35a2b45fd7bd 100644 --- a/cppcanvas/source/mtfrenderer/transparencygroupaction.cxx +++ b/cppcanvas/source/mtfrenderer/transparencygroupaction.cxx @@ -83,8 +83,8 @@ namespace cppcanvas::internal Size of the transparency group object, in current state coordinate system. */ - TransparencyGroupAction( MtfAutoPtr&& rGroupMtf, - GradientAutoPtr&& rAlphaGradient, + TransparencyGroupAction( std::unique_ptr< GDIMetaFile >&& rGroupMtf, + std::optional< Gradient >&& rAlphaGradient, const ::basegfx::B2DPoint& rDstPoint, const ::basegfx::B2DVector& rDstSize, const CanvasSharedPtr& rCanvas, @@ -104,8 +104,8 @@ namespace cppcanvas::internal virtual sal_Int32 getActionCount() const override; private: - MtfAutoPtr mpGroupMtf; - GradientAutoPtr mpAlphaGradient; + std::unique_ptr< GDIMetaFile > mpGroupMtf; + std::optional< Gradient > mpAlphaGradient; const ::basegfx::B2DSize maDstSize; @@ -135,8 +135,8 @@ namespace cppcanvas::internal aLocalTransformation ); } - TransparencyGroupAction::TransparencyGroupAction( MtfAutoPtr&& rGroupMtf, - GradientAutoPtr&& rAlphaGradient, + TransparencyGroupAction::TransparencyGroupAction( std::unique_ptr< GDIMetaFile >&& rGroupMtf, + std::optional< Gradient >&& rAlphaGradient, const ::basegfx::B2DPoint& rDstPoint, const ::basegfx::B2DVector& rDstSize, const CanvasSharedPtr& rCanvas, @@ -453,8 +453,8 @@ namespace cppcanvas::internal } - std::shared_ptr<Action> TransparencyGroupActionFactory::createTransparencyGroupAction( MtfAutoPtr&& rGroupMtf, - GradientAutoPtr&& rAlphaGradient, + std::shared_ptr<Action> TransparencyGroupActionFactory::createTransparencyGroupAction( std::unique_ptr< GDIMetaFile >&& rGroupMtf, + std::optional< Gradient >&& rAlphaGradient, const ::basegfx::B2DPoint& rDstPoint, const ::basegfx::B2DVector& rDstSize, const CanvasSharedPtr& rCanvas, diff --git a/cppcanvas/source/mtfrenderer/transparencygroupaction.hxx b/cppcanvas/source/mtfrenderer/transparencygroupaction.hxx index eb2419bbf53f..ddf01ca00934 100644 --- a/cppcanvas/source/mtfrenderer/transparencygroupaction.hxx +++ b/cppcanvas/source/mtfrenderer/transparencygroupaction.hxx @@ -39,9 +39,6 @@ namespace cppcanvas::internal { struct OutDevState; - typedef std::unique_ptr< GDIMetaFile > MtfAutoPtr; - typedef std::optional< Gradient > GradientAutoPtr; - /** Transparency group action. This action groups a bunch of other actions, to be @@ -75,8 +72,8 @@ namespace cppcanvas::internal Size of the transparency group object, in current state coordinate system. */ - std::shared_ptr<Action> createTransparencyGroupAction( MtfAutoPtr&& rGroupMtf, - GradientAutoPtr&& rAlphaGradient, + std::shared_ptr<Action> createTransparencyGroupAction( std::unique_ptr< GDIMetaFile >&& rGroupMtf, + std::optional< Gradient >&& rAlphaGradient, const ::basegfx::B2DPoint& rDstPoint, const ::basegfx::B2DVector& rDstSize, const CanvasSharedPtr& rCanvas,