summaryrefslogtreecommitdiff
path: root/vcl/opengl
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2020-01-24 13:22:32 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2020-01-24 19:31:14 +0100
commit3bbc0cf67cd5aa0ec5a1997794d21a87830bc618 (patch)
treebd912f9c91d8f96969377168fab9e5c5cc59a895 /vcl/opengl
parent7589e8413411aa4e0bf437ec0a7080c577a9c1d9 (diff)
loplugin:makeshared in svgio..writerperfect
Change-Id: I0f8de0f78c7a8fb78d47ee5dfed09019b4eb5288 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87357 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl/opengl')
-rw-r--r--vcl/opengl/FixedTextureAtlas.cxx2
-rw-r--r--vcl/opengl/PackedTextureAtlas.cxx2
-rw-r--r--vcl/opengl/texture.cxx6
3 files changed, 5 insertions, 5 deletions
diff --git a/vcl/opengl/FixedTextureAtlas.cxx b/vcl/opengl/FixedTextureAtlas.cxx
index 77c659f2bec6..7425942d127d 100644
--- a/vcl/opengl/FixedTextureAtlas.cxx
+++ b/vcl/opengl/FixedTextureAtlas.cxx
@@ -25,7 +25,7 @@ struct FixedTexture
std::vector<bool> maAllocatedSlots;
FixedTexture(int nTextureWidth, int nTextureHeight, int nNumberOfSlots)
- : mpTexture(new ImplOpenGLTexture(nTextureWidth, nTextureHeight, true))
+ : mpTexture(std::make_shared<ImplOpenGLTexture>(nTextureWidth, nTextureHeight, true))
, mnFreeSlots(nNumberOfSlots)
, maAllocatedSlots(nNumberOfSlots, false)
{
diff --git a/vcl/opengl/PackedTextureAtlas.cxx b/vcl/opengl/PackedTextureAtlas.cxx
index f881afe60f16..e56e7207bfa2 100644
--- a/vcl/opengl/PackedTextureAtlas.cxx
+++ b/vcl/opengl/PackedTextureAtlas.cxx
@@ -114,7 +114,7 @@ struct PackedTexture
std::unique_ptr<Node> mpRootNode;
PackedTexture(int nWidth, int nHeight)
- : mpTexture(new ImplOpenGLTexture(nWidth, nHeight, true))
+ : mpTexture(std::make_shared<ImplOpenGLTexture>(nWidth, nHeight, true))
, mpRootNode(new Node(nWidth, nHeight))
{}
};
diff --git a/vcl/opengl/texture.cxx b/vcl/opengl/texture.cxx
index 3b575e9bfcfe..d33cd2453832 100644
--- a/vcl/opengl/texture.cxx
+++ b/vcl/opengl/texture.cxx
@@ -278,21 +278,21 @@ OpenGLTexture::OpenGLTexture(const std::shared_ptr<ImplOpenGLTexture>& rpImpl, t
OpenGLTexture::OpenGLTexture( int nWidth, int nHeight, bool bAllocate )
: maRect( Point( 0, 0 ), Size( nWidth, nHeight ) )
- , mpImpl(new ImplOpenGLTexture(nWidth, nHeight, bAllocate))
+ , mpImpl(std::make_shared<ImplOpenGLTexture>(nWidth, nHeight, bAllocate))
, mnSlotNumber(-1)
{
}
OpenGLTexture::OpenGLTexture( int nX, int nY, int nWidth, int nHeight )
: maRect( Point( 0, 0 ), Size( nWidth, nHeight ) )
- , mpImpl(new ImplOpenGLTexture(nX, nY, nWidth, nHeight))
+ , mpImpl(std::make_shared<ImplOpenGLTexture>(nX, nY, nWidth, nHeight))
, mnSlotNumber(-1)
{
}
OpenGLTexture::OpenGLTexture( int nWidth, int nHeight, int nFormat, int nType, void const * pData )
: maRect( Point( 0, 0 ), Size( nWidth, nHeight ) )
- , mpImpl(new ImplOpenGLTexture(nWidth, nHeight, nFormat, nType, pData))
+ , mpImpl(std::make_shared<ImplOpenGLTexture>(nWidth, nHeight, nFormat, nType, pData))
, mnSlotNumber(-1)
{