summaryrefslogtreecommitdiff
path: root/include/basegfx/vector
diff options
context:
space:
mode:
authorTomaž Vajngerl <tomaz.vajngerl@collabora.co.uk>2022-09-06 19:37:20 +0200
committerTomaž Vajngerl <quikee@gmail.com>2022-09-10 08:45:51 +0200
commitc2d3f4be406b3bef8e89b17b781cb7e827a0fe3d (patch)
treeda92ca1958f556804d3a73183dc2a904ca4bc416 /include/basegfx/vector
parent0252b7bdec3693096bb52c67d335c0e9e662e185 (diff)
basegfx: simplify Tuple2D, B2DPoint, B2DVector, B2DTuple
Change-Id: I97e41fc62288ec4ee5805747fd3a3a6e019cfb57 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139681 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'include/basegfx/vector')
-rw-r--r--include/basegfx/vector/b2dvector.hxx11
1 files changed, 8 insertions, 3 deletions
diff --git a/include/basegfx/vector/b2dvector.hxx b/include/basegfx/vector/b2dvector.hxx
index 17a9c60b0f71..c7d8bc08a867 100644
--- a/include/basegfx/vector/b2dvector.hxx
+++ b/include/basegfx/vector/b2dvector.hxx
@@ -72,8 +72,8 @@ namespace basegfx
/** constructor with tuple to allow copy-constructing
from B2DTuple-based classes
*/
- B2DVector(const ::basegfx::B2DTuple& rTuple)
- : B2DTuple(rTuple)
+ B2DVector(Tuple2D<double> const& rTuple)
+ : B2DTuple(rTuple)
{}
/** *=operator to allow usage from B2DVector, too
@@ -97,7 +97,12 @@ namespace basegfx
/** assignment operator to allow assigning the results
of B2DTuple calculations
*/
- B2DVector& operator=( const ::basegfx::B2DTuple& rVec );
+ B2DVector& operator=(Tuple2D<double> const& rVector)
+ {
+ mfX = rVector.getX();
+ mfY = rVector.getY();
+ return *this;
+ }
/** Calculate the length of this 2D Vector