summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--basegfx/source/matrix/b2dhommatrix.cxx11
-rw-r--r--basegfx/source/polygon/b2dpolygon.cxx10
-rw-r--r--basegfx/source/polygon/b2dpolypolygon.cxx11
-rw-r--r--include/basegfx/matrix/b2dhommatrix.hxx2
-rw-r--r--include/basegfx/polygon/b2dpolygon.hxx2
-rw-r--r--include/basegfx/polygon/b2dpolypolygon.hxx2
6 files changed, 38 insertions, 0 deletions
diff --git a/basegfx/source/matrix/b2dhommatrix.cxx b/basegfx/source/matrix/b2dhommatrix.cxx
index 07d10e6bebff..2dce96fb2379 100644
--- a/basegfx/source/matrix/b2dhommatrix.cxx
+++ b/basegfx/source/matrix/b2dhommatrix.cxx
@@ -45,6 +45,11 @@ namespace basegfx
{
}
+ B2DHomMatrix::B2DHomMatrix(B2DHomMatrix&& rMat) :
+ mpImpl(std::move(rMat.mpImpl))
+ {
+ }
+
B2DHomMatrix::~B2DHomMatrix()
{
}
@@ -66,6 +71,12 @@ namespace basegfx
return *this;
}
+ B2DHomMatrix& B2DHomMatrix::operator=(B2DHomMatrix&& rMat)
+ {
+ mpImpl = std::move(rMat.mpImpl);
+ return *this;
+ }
+
double B2DHomMatrix::get(sal_uInt16 nRow, sal_uInt16 nColumn) const
{
return mpImpl->get(nRow, nColumn);
diff --git a/basegfx/source/polygon/b2dpolygon.cxx b/basegfx/source/polygon/b2dpolygon.cxx
index 4274e629581b..2cf40a12175c 100644
--- a/basegfx/source/polygon/b2dpolygon.cxx
+++ b/basegfx/source/polygon/b2dpolygon.cxx
@@ -1118,6 +1118,10 @@ namespace basegfx
: mpPolygon(rPolygon.mpPolygon)
{}
+ B2DPolygon::B2DPolygon(B2DPolygon&& rPolygon)
+ : mpPolygon(std::move(rPolygon.mpPolygon))
+ {}
+
B2DPolygon::B2DPolygon(const B2DPolygon& rPolygon, sal_uInt32 nIndex, sal_uInt32 nCount)
: mpPolygon(ImplB2DPolygon(*rPolygon.mpPolygon, nIndex, nCount))
{
@@ -1136,6 +1140,12 @@ namespace basegfx
return *this;
}
+ B2DPolygon& B2DPolygon::operator=(B2DPolygon&& rPolygon)
+ {
+ mpPolygon = std::move(rPolygon.mpPolygon);
+ return *this;
+ }
+
void B2DPolygon::makeUnique()
{
mpPolygon.make_unique();
diff --git a/basegfx/source/polygon/b2dpolypolygon.cxx b/basegfx/source/polygon/b2dpolypolygon.cxx
index bfaaedec6f6e..f1032f108a86 100644
--- a/basegfx/source/polygon/b2dpolypolygon.cxx
+++ b/basegfx/source/polygon/b2dpolypolygon.cxx
@@ -183,6 +183,11 @@ namespace basegfx
{
}
+ B2DPolyPolygon::B2DPolyPolygon(B2DPolyPolygon&& rPolyPolygon) :
+ mpPolyPolygon(std::move(rPolyPolygon.mpPolyPolygon))
+ {
+ }
+
B2DPolyPolygon::B2DPolyPolygon(const B2DPolygon& rPolygon) :
mpPolyPolygon( ImplB2DPolyPolygon(rPolygon) )
{
@@ -198,6 +203,12 @@ namespace basegfx
return *this;
}
+ B2DPolyPolygon& B2DPolyPolygon::operator=(B2DPolyPolygon&& rPolyPolygon)
+ {
+ mpPolyPolygon = std::move(rPolyPolygon.mpPolyPolygon);
+ return *this;
+ }
+
void B2DPolyPolygon::makeUnique()
{
mpPolyPolygon.make_unique();
diff --git a/include/basegfx/matrix/b2dhommatrix.hxx b/include/basegfx/matrix/b2dhommatrix.hxx
index a3e6fcde97cf..51479aa01999 100644
--- a/include/basegfx/matrix/b2dhommatrix.hxx
+++ b/include/basegfx/matrix/b2dhommatrix.hxx
@@ -40,6 +40,7 @@ namespace basegfx
public:
B2DHomMatrix();
B2DHomMatrix(const B2DHomMatrix& rMat);
+ B2DHomMatrix(B2DHomMatrix&& rMat);
~B2DHomMatrix();
/** constructor to allow setting all needed values for a 3x2 matrix at once. The
@@ -90,6 +91,7 @@ namespace basegfx
// assignment operator
B2DHomMatrix& operator=(const B2DHomMatrix& rMat);
+ B2DHomMatrix& operator=(B2DHomMatrix&& rMat);
// Help routine to decompose given homogen 3x3 matrix to components. A correction of
// the components is done to avoid inaccuracies.
diff --git a/include/basegfx/polygon/b2dpolygon.hxx b/include/basegfx/polygon/b2dpolygon.hxx
index 7bdf771915f3..4e868c103c6d 100644
--- a/include/basegfx/polygon/b2dpolygon.hxx
+++ b/include/basegfx/polygon/b2dpolygon.hxx
@@ -54,6 +54,7 @@ namespace basegfx
/// diverse constructors
B2DPolygon();
B2DPolygon(const B2DPolygon& rPolygon);
+ B2DPolygon(B2DPolygon&& rPolygon);
B2DPolygon(const B2DPolygon& rPolygon, sal_uInt32 nIndex, sal_uInt32 nCount);
B2DPolygon(std::initializer_list<basegfx::B2DPoint> rPoints);
@@ -61,6 +62,7 @@ namespace basegfx
/// assignment operator
B2DPolygon& operator=(const B2DPolygon& rPolygon);
+ B2DPolygon& operator=(B2DPolygon&& rPolygon);
/// unshare this polygon with all internally shared instances
void makeUnique();
diff --git a/include/basegfx/polygon/b2dpolypolygon.hxx b/include/basegfx/polygon/b2dpolypolygon.hxx
index 3527c84da811..c033989a722b 100644
--- a/include/basegfx/polygon/b2dpolypolygon.hxx
+++ b/include/basegfx/polygon/b2dpolypolygon.hxx
@@ -49,11 +49,13 @@ namespace basegfx
public:
B2DPolyPolygon();
B2DPolyPolygon(const B2DPolyPolygon& rPolyPolygon);
+ B2DPolyPolygon(B2DPolyPolygon&& rPolyPolygon);
explicit B2DPolyPolygon(const B2DPolygon& rPolygon);
~B2DPolyPolygon();
// assignment operator
B2DPolyPolygon& operator=(const B2DPolyPolygon& rPolyPolygon);
+ B2DPolyPolygon& operator=(B2DPolyPolygon&& rPolyPolygon);
/// unshare this poly-polygon (and all included polygons) with all internally shared instances
void makeUnique();