From 4639ca2f878b04ffc50d9c20d92e90464d2d67a7 Mon Sep 17 00:00:00 2001 From: Mike Kaganski Date: Fri, 13 Aug 2021 16:44:15 +0300 Subject: Rename setX/setY to SetPosX/SetPosY, to align with SetPos Change-Id: I856194f26fefad993f416d7b92b57a9417a3c0a3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120546 Tested-by: Jenkins Reviewed-by: Mike Kaganski --- tools/qa/cppunit/test_rectangle.cxx | 4 ++-- tools/source/generic/gen.cxx | 14 -------------- 2 files changed, 2 insertions(+), 16 deletions(-) (limited to 'tools') diff --git a/tools/qa/cppunit/test_rectangle.cxx b/tools/qa/cppunit/test_rectangle.cxx index 23bfaf61ec7a..e4992f3f44f9 100644 --- a/tools/qa/cppunit/test_rectangle.cxx +++ b/tools/qa/cppunit/test_rectangle.cxx @@ -52,9 +52,9 @@ void Test::test_rectangle() CPPUNIT_ASSERT_EQUAL(tools::Long(0), aRect.getWidth()); CPPUNIT_ASSERT_EQUAL(tools::Long(0), aRect.getHeight()); - aRect.setX(12); + aRect.SetPosX(12); CPPUNIT_ASSERT_EQUAL(tools::Long(1), aRect.GetHeight()); - aRect.setY(12); + aRect.SetPosY(12); CPPUNIT_ASSERT_EQUAL(tools::Long(1), aRect.GetWidth()); } } diff --git a/tools/source/generic/gen.cxx b/tools/source/generic/gen.cxx index abd32a208d70..4d365a575808 100644 --- a/tools/source/generic/gen.cxx +++ b/tools/source/generic/gen.cxx @@ -232,18 +232,4 @@ tools::Long tools::Rectangle::AdjustBottom( tools::Long nVertMoveDelta ) return nBottom; } -void tools::Rectangle::setX( tools::Long x ) -{ - if (!IsWidthEmpty()) - nRight += x - nLeft; - nLeft = x; -} - -void tools::Rectangle::setY( tools::Long y ) -{ - if (!IsHeightEmpty()) - nBottom += y - nTop; - nTop = y; -} - /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ -- cgit