diff options
author | Noel Grandin <noel@peralex.com> | 2016-08-25 15:27:26 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2016-08-29 09:23:46 +0200 |
commit | e2c309adf59e21b187e050a5fe17df91d7d57f8f (patch) | |
tree | e1f4534668e84b12ff15cc4b906a1d1d6c15bd14 | |
parent | c455eb45aa2ff3cfd882c928f04d679fd68f073d (diff) |
cid#1371176 Missing move assignment operator
Change-Id: I57df53df6933e1945fabc0e4a7f0e1c5815aeaca
-rw-r--r-- | include/vcl/lineinfo.hxx | 2 | ||||
-rw-r--r-- | vcl/source/gdi/lineinfo.cxx | 10 |
2 files changed, 12 insertions, 0 deletions
diff --git a/include/vcl/lineinfo.hxx b/include/vcl/lineinfo.hxx index e5d8fc9855ec..e36c1c0b4747 100644 --- a/include/vcl/lineinfo.hxx +++ b/include/vcl/lineinfo.hxx @@ -55,9 +55,11 @@ class VCL_DLLPUBLIC LineInfo public: LineInfo( LineStyle eLineStyle = LINE_SOLID, long nWidth = 0L ); LineInfo( const LineInfo& rLineInfo ); + LineInfo( LineInfo&& rLineInfo ); ~LineInfo(); LineInfo& operator=( const LineInfo& rLineInfo ); + LineInfo& operator=( LineInfo&& rLineInfo ); bool operator==( const LineInfo& rLineInfo ) const; bool operator!=( const LineInfo& rLineInfo ) const { return !(LineInfo::operator==( rLineInfo ) ); } diff --git a/vcl/source/gdi/lineinfo.cxx b/vcl/source/gdi/lineinfo.cxx index 2b71a285e294..608ce4d7b995 100644 --- a/vcl/source/gdi/lineinfo.cxx +++ b/vcl/source/gdi/lineinfo.cxx @@ -77,6 +77,10 @@ LineInfo::LineInfo( const LineInfo& rLineInfo ) : mpImplLineInfo(rLineInfo.mpImp { } +LineInfo::LineInfo( LineInfo&& rLineInfo ) : mpImplLineInfo(std::move(rLineInfo.mpImplLineInfo)) +{ +} + LineInfo::~LineInfo() { } @@ -87,6 +91,12 @@ LineInfo& LineInfo::operator=( const LineInfo& rLineInfo ) return *this; } +LineInfo& LineInfo::operator=( LineInfo&& rLineInfo ) +{ + mpImplLineInfo = std::move(rLineInfo.mpImplLineInfo); + return *this; +} + bool LineInfo::operator==( const LineInfo& rLineInfo ) const { return mpImplLineInfo == rLineInfo.mpImplLineInfo; |