diff options
author | Caolán McNamara <caolanm@redhat.com> | 2019-12-02 10:32:10 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2019-12-02 17:31:15 +0100 |
commit | 0a616e7e6cbeed4a689cacb6d6d8c6ed6779abd5 (patch) | |
tree | d0017b0c0fe443f9610953171f790499760355e2 /sc | |
parent | 2eb9957483be2af8ab7f12c997f82871fc7115ae (diff) |
cid#1456145 Missing move assignment operator
Change-Id: I638278ff61499206f479cba18448c8fa5a5c28a8
Reviewed-on: https://gerrit.libreoffice.org/84203
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sc')
-rw-r--r-- | sc/inc/markdata.hxx | 12 | ||||
-rw-r--r-- | sc/source/core/data/markdata.cxx | 42 |
2 files changed, 6 insertions, 48 deletions
diff --git a/sc/inc/markdata.hxx b/sc/inc/markdata.hxx index 52fed46bb07a..10403066e5e8 100644 --- a/sc/inc/markdata.hxx +++ b/sc/inc/markdata.hxx @@ -63,12 +63,12 @@ private: bool bMarkIsNeg:1; // cancel if multi selection public: - ScMarkData(SCROW nMaxRow, SCCOL nMaxCol); - ScMarkData(const ScMarkData& rData); - ScMarkData(SCROW nMaxRow, SCCOL nMaxCol, const ScRangeList& rList); - ~ScMarkData(); - - ScMarkData& operator=(const ScMarkData& rData); + ScMarkData(SCROW nMaxRow, SCCOL nMaxCol); + ScMarkData(SCROW nMaxRow, SCCOL nMaxCol, const ScRangeList& rList); + ScMarkData(const ScMarkData& rData) = default; + ScMarkData(ScMarkData&& rData) = default; + ScMarkData& operator=(const ScMarkData& rData) = default; + ~ScMarkData(); void ResetMark(); void SetMarkArea( const ScRange& rRange ); diff --git a/sc/source/core/data/markdata.cxx b/sc/source/core/data/markdata.cxx index 047fe7002ff2..b698183ac0a0 100644 --- a/sc/source/core/data/markdata.cxx +++ b/sc/source/core/data/markdata.cxx @@ -41,48 +41,6 @@ ScMarkData::ScMarkData(SCROW nMaxRow, SCCOL nMaxCol) : ResetMark(); } -ScMarkData::ScMarkData(const ScMarkData& rData) : - maTabMarked( rData.maTabMarked ), - aMarkRange( rData.aMarkRange ), - aMultiRange( rData.aMultiRange ), - aMultiSel( rData.aMultiSel ), - aTopEnvelope( rData.aTopEnvelope ), - aBottomEnvelope( rData.aBottomEnvelope ), - aLeftEnvelope( rData.aLeftEnvelope ), - aRightEnvelope( rData.aRightEnvelope ), - mnMaxRow( rData.mnMaxRow ), - mnMaxCol( rData.mnMaxCol ), - bMarked( rData.bMarked ), - bMultiMarked( rData.bMultiMarked ), - bMarking( rData.bMarking ), - bMarkIsNeg( rData.bMarkIsNeg ) -{ -} - -ScMarkData& ScMarkData::operator=(const ScMarkData& rData) -{ - if ( &rData == this ) - return *this; - - aMarkRange = rData.aMarkRange; - aMultiRange = rData.aMultiRange; - bMarked = rData.bMarked; - bMultiMarked = rData.bMultiMarked; - bMarking = rData.bMarking; - bMarkIsNeg = rData.bMarkIsNeg; - aTopEnvelope = rData.aTopEnvelope; - aBottomEnvelope = rData.aBottomEnvelope; - aLeftEnvelope = rData.aLeftEnvelope; - aRightEnvelope = rData.aRightEnvelope; - - maTabMarked = rData.maTabMarked; - aMultiSel = rData.aMultiSel; - mnMaxRow = rData.mnMaxRow; - mnMaxCol = rData.mnMaxCol; - - return *this; -} - ScMarkData::~ScMarkData() { } |