From b2247f86e42c05991165834ff5d63731b0da2b3b Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Fri, 12 Nov 2021 11:46:21 +0200 Subject: improve mergeToSinglePolyPolygon MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit spotted by llunak. No need to take param by &&, since mergeToSinglePol does not actually need to modify it. Also flatten it a little. Change-Id: I2f5ade347db756e21ecb0a88c3935805268f5072 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125086 Reviewed-by: Luboš Luňák Tested-by: Jenkins --- svgio/source/svgreader/svgclippathnode.cxx | 2 +- svgio/source/svgreader/svgstyleattributes.cxx | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'svgio') diff --git a/svgio/source/svgreader/svgclippathnode.cxx b/svgio/source/svgreader/svgclippathnode.cxx index 7f4b4beae8ec..31ac632d33dc 100644 --- a/svgio/source/svgreader/svgclippathnode.cxx +++ b/svgio/source/svgreader/svgclippathnode.cxx @@ -148,7 +148,7 @@ namespace svgio::svgreader if(nSize > 1) { // merge to single clipPolyPolygon - aClipPolyPolygon = basegfx::utils::mergeToSinglePolyPolygon(std::vector(rResult)); + aClipPolyPolygon = basegfx::utils::mergeToSinglePolyPolygon(rResult); } else { diff --git a/svgio/source/svgreader/svgstyleattributes.cxx b/svgio/source/svgreader/svgstyleattributes.cxx index e7a0d90b7efc..21ef7cebf5cf 100644 --- a/svgio/source/svgreader/svgstyleattributes.cxx +++ b/svgio/source/svgreader/svgstyleattributes.cxx @@ -304,7 +304,7 @@ namespace svgio::svgreader if(!aTextFillVector.empty()) { - aMergedArea = basegfx::utils::mergeToSinglePolyPolygon(std::move(aTextFillVector)); + aMergedArea = basegfx::utils::mergeToSinglePolyPolygon(aTextFillVector); } } @@ -763,7 +763,7 @@ namespace svgio::svgreader { const basegfx::B2DPolyPolygon aMergedArea( basegfx::utils::mergeToSinglePolyPolygon( - std::vector(rLineFillVector))); + rLineFillVector)); if(aMergedArea.count()) { -- cgit