summaryrefslogtreecommitdiff
path: root/svx/source/engine3d/polygn3d.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'svx/source/engine3d/polygn3d.cxx')
-rw-r--r--svx/source/engine3d/polygn3d.cxx29
1 files changed, 21 insertions, 8 deletions
diff --git a/svx/source/engine3d/polygn3d.cxx b/svx/source/engine3d/polygn3d.cxx
index 190c0ca89ee5..bcb9ba81b9eb 100644
--- a/svx/source/engine3d/polygn3d.cxx
+++ b/svx/source/engine3d/polygn3d.cxx
@@ -25,17 +25,16 @@
#include <basegfx/polygon/b3dpolygon.hxx>
#include <basegfx/polygon/b3dpolygontools.hxx>
-
// DrawContact section
-
sdr::contact::ViewContact* E3dPolygonObj::CreateObjectSpecificViewContact()
{
return new sdr::contact::ViewContactOfE3dPolygon(*this);
}
E3dPolygonObj::E3dPolygonObj(
+ SdrModel& rSdrModel,
const basegfx::B3DPolyPolygon& rPolyPoly3D)
-: E3dCompoundObject(),
+: E3dCompoundObject(rSdrModel),
bLineOnly(true)
{
// Set geometry
@@ -48,9 +47,9 @@ E3dPolygonObj::E3dPolygonObj(
CreateDefaultTexture();
}
-E3dPolygonObj::E3dPolygonObj()
-: E3dCompoundObject(),
- bLineOnly(false) // added missing initialisation
+E3dPolygonObj::E3dPolygonObj(SdrModel& rSdrModel)
+: E3dCompoundObject(rSdrModel),
+ bLineOnly(false)
{
// Create no geometry
}
@@ -219,9 +218,23 @@ SdrObject *E3dPolygonObj::DoConvertToPolyObj(bool /*bBezier*/, bool /*bAddText*/
return nullptr;
}
-E3dPolygonObj* E3dPolygonObj::Clone() const
+E3dPolygonObj* E3dPolygonObj::Clone(SdrModel* pTargetModel) const
{
- return CloneHelper< E3dPolygonObj >();
+ return CloneHelper< E3dPolygonObj >(pTargetModel);
+}
+
+E3dPolygonObj& E3dPolygonObj::operator=(const E3dPolygonObj& rObj)
+{
+ if( this == &rObj )
+ return *this;
+ E3dCompoundObject::operator=(rObj);
+
+ aPolyPoly3D = rObj.aPolyPoly3D;
+ aPolyNormals3D = rObj.aPolyNormals3D;
+ aPolyTexture2D = rObj.aPolyTexture2D;
+ bLineOnly = rObj.bLineOnly;
+
+ return *this;
}
void E3dPolygonObj::SetLineOnly(bool bNew)