diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2023-07-06 19:00:50 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2023-07-06 20:28:05 +0200 |
commit | 13d71843510964a98d3c480d1e42533bdd34deab (patch) | |
tree | dd9bb2745c787d1afe04b88d3fe4f3e7fce652b8 /include/tools/poly.hxx | |
parent | 11419c34eb38b1d15bd83ca8c511346a7bc30537 (diff) |
make tools::Poly*gon single-arg constructors explicit
which will help avoid ambiguity in method calls in an upcoming patch
Change-Id: Ic7607ac7d95559e0942a84fb3226cfdd6ade22bc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154146
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include/tools/poly.hxx')
-rw-r--r-- | include/tools/poly.hxx | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/include/tools/poly.hxx b/include/tools/poly.hxx index d9f2a4544901..77653d23bda7 100644 --- a/include/tools/poly.hxx +++ b/include/tools/poly.hxx @@ -83,10 +83,10 @@ public: public: Polygon(); - Polygon( sal_uInt16 nSize ); + explicit Polygon( sal_uInt16 nSize ); Polygon( sal_uInt16 nPoints, const Point* pPtAry, const PolyFlags* pFlagAry = nullptr ); - Polygon( const tools::Rectangle& rRect ); + explicit Polygon( const tools::Rectangle& rRect ); Polygon( const tools::Rectangle& rRect, sal_uInt32 nHorzRound, sal_uInt32 nVertRound ); Polygon( const Point& rCenter, @@ -196,8 +196,9 @@ private: TOOLS_DLLPRIVATE void ImplDoOperation( const tools::PolyPolygon& rPolyPoly, tools::PolyPolygon& rResult, PolyClipOp nOperation ) const; public: - PolyPolygon( sal_uInt16 nInitSize = 16 ); - PolyPolygon( const tools::Polygon& rPoly ); + explicit PolyPolygon( sal_uInt16 nInitSize = 16 ); + explicit PolyPolygon( const tools::Polygon& rPoly ); + explicit PolyPolygon( const tools::Rectangle& ); PolyPolygon( const tools::PolyPolygon& rPolyPoly ); PolyPolygon( tools::PolyPolygon&& rPolyPoly ) noexcept; ~PolyPolygon(); |