diff options
author | Noel <noel.grandin@collabora.co.uk> | 2021-02-09 13:42:22 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-02-10 07:35:41 +0100 |
commit | 09cb778b6eb7d3a5b9029965a1320b49c90e7295 (patch) | |
tree | 63d75bc66ddbe4af5f6a52f4a0d65e9b199dbae7 /include/svx/svdocirc.hxx | |
parent | ccdee8eebaa56619248e35001017226eecfe4e83 (diff) |
clean up SdrObject cloning
using operator= implies that overwriting an SdrObject is a
useful operation, but that is not at all true - they are typically
linked into and referred to by many other things.
So rather use a copy-constructor.
Also clean up a couple of weird "do some stuff after the clone"
code into the main copy constructor.
Change-Id: Iefc1481b527602748b5f3abed06e7cca66c0581c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110633
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include/svx/svdocirc.hxx')
-rw-r--r-- | include/svx/svdocirc.hxx | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/include/svx/svdocirc.hxx b/include/svx/svdocirc.hxx index cd573323a94d..81687cc0bfe2 100644 --- a/include/svx/svdocirc.hxx +++ b/include/svx/svdocirc.hxx @@ -77,6 +77,8 @@ public: SdrModel& rSdrModel, SdrCircKind eNewKind, const tools::Rectangle& rRect); + // Copy constructor + SdrCircObj(SdrModel& rSdrModel, SdrCircObj const & rSource); // 0=0.00Deg=3h 9000=90.00Deg=12h 18000=180.00Deg=9h 27000=270.00Deg=6h // The circle is build up from StartAngle to EndWink anti-clockwise. @@ -100,9 +102,6 @@ public: virtual SdrCircObj* CloneSdrObject(SdrModel& rTargetModel) const override; - // implemented mainly for the purposes of Clone() - SdrCircObj& operator=(const SdrCircObj& rObj); - virtual void RecalcSnapRect() override; virtual void NbcSetSnapRect(const tools::Rectangle& rRect) override; virtual basegfx::B2DPolyPolygon TakeXorPoly() const override; |