diff options
author | Caolán McNamara <caolanm@redhat.com> | 2016-11-04 11:38:06 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2016-11-04 16:01:15 +0000 |
commit | 54dc3dd96bf720a81eef81864848e58c5db860f8 (patch) | |
tree | 9155a37b73fcda1dbfb057858fedf6c125403b50 | |
parent | dec5931ede57e1910d3f0ec62f575b027208320f (diff) |
use default copy and assignment operators
Change-Id: Ic784b3951fcf2f614b62d93d925eec134feb7364
Reviewed-on: https://gerrit.libreoffice.org/30567
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r-- | include/vcl/image.hxx | 9 | ||||
-rw-r--r-- | vcl/source/image/Image.cxx | 21 | ||||
-rw-r--r-- | vcl/source/image/ImageList.cxx | 28 |
3 files changed, 0 insertions, 58 deletions
diff --git a/include/vcl/image.hxx b/include/vcl/image.hxx index 0ad2f0ca4504..7c4bd09bfab0 100644 --- a/include/vcl/image.hxx +++ b/include/vcl/image.hxx @@ -46,14 +46,12 @@ class VCL_DLLPUBLIC Image public: Image(); explicit Image( const ResId& rResId ); - Image( const Image& rImage ); explicit Image( const BitmapEx& rBitmapEx ); explicit Image( const Bitmap& rBitmap ); Image( const Bitmap& rBitmap, const Bitmap& rMaskBitmap ); Image( const Bitmap& rBitmap, const Color& rColor ); explicit Image( const css::uno::Reference< css::graphic::XGraphic >& rxGraphic ); explicit Image( const OUString &rPNGFileUrl ); - ~Image(); Size GetSizePixel() const; @@ -61,8 +59,6 @@ public: css::uno::Reference< css::graphic::XGraphic > GetXGraphic() const; bool operator!() const { return !mpImplData; } - Image& operator=( const Image& rImage ); - Image& operator=( Image&& rImage ); bool operator==( const Image& rImage ) const; bool operator!=( const Image& rImage ) const { return !(Image::operator==( rImage )); } @@ -82,9 +78,6 @@ public: explicit ImageList( const ResId& rResId ); ImageList( const std::vector<OUString>& rNameVector, const OUString& rPrefix); - ImageList( const ImageList& rImageList ); - ImageList( ImageList&& rImageList ); - ~ImageList(); void InsertFromHorizontalStrip( const BitmapEx &rBitmapEx, const std::vector< OUString > &rNameVector ); @@ -116,8 +109,6 @@ public: OUString GetImageName( sal_uInt16 nPos ) const; void GetImageNames( ::std::vector< OUString >& rNames ) const; - ImageList& operator=( const ImageList& rImageList ); - ImageList& operator=( ImageList&& rImageList ); bool operator==( const ImageList& rImageList ) const; bool operator!=( const ImageList& rImageList ) const { return !(ImageList::operator==( rImageList )); } diff --git a/vcl/source/image/Image.cxx b/vcl/source/image/Image.cxx index bc767ce9c497..22b6fbc451de 100644 --- a/vcl/source/image/Image.cxx +++ b/vcl/source/image/Image.cxx @@ -67,11 +67,6 @@ Image::Image( const ResId& rResId ) } } -Image::Image(const Image& rImage) - : mpImplData(rImage.mpImplData) -{ -} - Image::Image(const BitmapEx& rBitmapEx) { ImplInit(rBitmapEx); @@ -112,10 +107,6 @@ Image::Image(const OUString & rFileUrl) } } -Image::~Image() -{ -} - void Image::ImplInit(const BitmapEx& rBitmapEx) { if (!rBitmapEx.IsEmpty()) @@ -156,18 +147,6 @@ css::uno::Reference< css::graphic::XGraphic > Image::GetXGraphic() const return aGraphic.GetXGraphic(); } -Image& Image::operator=(const Image& rImage) -{ - mpImplData = rImage.mpImplData; - return *this; -} - -Image& Image::operator=(Image&& rImage) -{ - std::swap(mpImplData, rImage.mpImplData); - return *this; -} - bool Image::operator==(const Image& rImage) const { bool bRet = false; diff --git a/vcl/source/image/ImageList.cxx b/vcl/source/image/ImageList.cxx index 42def4e05efc..29bdbc00a4a8 100644 --- a/vcl/source/image/ImageList.cxx +++ b/vcl/source/image/ImageList.cxx @@ -88,21 +88,6 @@ ImageList::ImageList(const std::vector< OUString >& rNameVector, } } -ImageList::ImageList( const ImageList& rImageList ) - : mpImplData(rImageList.mpImplData) -{ -} - -ImageList::ImageList( ImageList&& rImageList ) - : mpImplData(rImageList.mpImplData) -{ - rImageList.mpImplData.reset(); -} - -ImageList::~ImageList() -{ -} - void ImageList::ImplInit( sal_uInt16 nItems, const Size &rSize ) { mpImplData.reset(new ImplImageList); @@ -373,19 +358,6 @@ Size ImageList::GetImageSize() const return aRet; } -ImageList& ImageList::operator=( const ImageList& rImageList ) -{ - mpImplData = rImageList.mpImplData; - return *this; -} - -ImageList& ImageList::operator=( ImageList&& rImageList ) -{ - mpImplData = rImageList.mpImplData; - rImageList.mpImplData = nullptr; - return *this; -} - bool ImageList::operator==( const ImageList& rImageList ) const { bool bRet = false; |