From 8c7ad3231435e3b11467cfc9f28d88157caf3f4b Mon Sep 17 00:00:00 2001 From: Miklos Vajna Date: Mon, 9 Dec 2024 08:47:20 +0100 Subject: [PATCH] svx: prefix members of SdrDragResize See tdf#94879 for motivation. Change-Id: I90f3a09e5dee630ead50954b1d8c5848b9319949 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/178123 Reviewed-by: Miklos Vajna Tested-by: Jenkins --- include/svx/svddrgmt.hxx | 4 ++-- sd/source/ui/animations/motionpathtag.cxx | 2 +- svx/source/svdraw/svddrgmt.cxx | 28 +++++++++++------------ 3 files changed, 17 insertions(+), 17 deletions(-) diff --git a/include/svx/svddrgmt.hxx b/include/svx/svddrgmt.hxx index 3352f09196b3..291d1c8d6c40 100644 --- a/include/svx/svddrgmt.hxx +++ b/include/svx/svddrgmt.hxx @@ -257,8 +257,8 @@ public: class SVXCORE_DLLPUBLIC SdrDragResize : public SdrDragMethod { protected: - Fraction aXFact; - Fraction aYFact; + Fraction m_aXFact; + Fraction m_aYFact; public: SdrDragResize(SdrDragView& rNewView); diff --git a/sd/source/ui/animations/motionpathtag.cxx b/sd/source/ui/animations/motionpathtag.cxx index 7a43fe07f54a..bffecd48cd89 100644 --- a/sd/source/ui/animations/motionpathtag.cxx +++ b/sd/source/ui/animations/motionpathtag.cxx @@ -186,7 +186,7 @@ bool PathDragResize::EndSdrDrag(bool /*bCopy*/) { const Point aRef( DragStat().GetRef1() ); basegfx::B2DHomMatrix aTrans(basegfx::utils::createTranslateB2DHomMatrix(-aRef.X(), -aRef.Y())); - aTrans.scale(double(aXFact), double(aYFact)); + aTrans.scale(double(m_aXFact), double(m_aYFact)); aTrans.translate(aRef.X(), aRef.Y()); basegfx::B2DPolyPolygon aDragPoly(pPathObj->GetPathPoly()); aDragPoly.transform(aTrans); diff --git a/svx/source/svdraw/svddrgmt.cxx b/svx/source/svdraw/svddrgmt.cxx index 7e2a812e430e..80b3b0bf6b3b 100644 --- a/svx/source/svdraw/svddrgmt.cxx +++ b/svx/source/svdraw/svddrgmt.cxx @@ -1723,8 +1723,8 @@ PointerStyle SdrDragMove::GetSdrDragPointer() const SdrDragResize::SdrDragResize(SdrDragView& rNewView) : SdrDragMethod(rNewView), - aXFact(1,1), - aYFact(1,1) + m_aXFact(1,1), + m_aYFact(1,1) { } @@ -1744,20 +1744,20 @@ OUString SdrDragResize::GetSdrDragComment() const if(!nYDiv) nYDiv = 1; - bool bX(aXFact != aFact1 && std::abs(nXDiv) > 1); - bool bY(aYFact != aFact1 && std::abs(nYDiv) > 1); + bool bX(m_aXFact != aFact1 && std::abs(nXDiv) > 1); + bool bY(m_aYFact != aFact1 && std::abs(nYDiv) > 1); if(bX || bY) { aStr += " ("; - bool bEqual(aXFact == aYFact); + bool bEqual(m_aXFact == m_aYFact); if(bX) { if(!bEqual) aStr += "x="; - aStr += SdrModel::GetPercentString(aXFact); + aStr += SdrModel::GetPercentString(m_aXFact); } if(bY && !bEqual) @@ -1765,7 +1765,7 @@ OUString SdrDragResize::GetSdrDragComment() const if(bX) aStr += " "; - aStr += "y=" + SdrModel::GetPercentString(aYFact); + aStr += "y=" + SdrModel::GetPercentString(m_aYFact); } aStr += ")"; @@ -1825,7 +1825,7 @@ basegfx::B2DHomMatrix SdrDragResize::getCurrentTransformation() const { basegfx::B2DHomMatrix aRetval(basegfx::utils::createTranslateB2DHomMatrix( -DragStat().GetRef1().X(), -DragStat().GetRef1().Y())); - aRetval.scale(double(aXFact), double(aYFact)); + aRetval.scale(double(m_aXFact), double(m_aYFact)); aRetval.translate(DragStat().GetRef1().X(), DragStat().GetRef1().Y()); return aRetval; @@ -2005,8 +2005,8 @@ void SdrDragResize::MoveSdrDrag(const Point& rNoSnapPnt) { Hide(); DragStat().NextMove(aPnt); - aXFact=aNewXFact; - aYFact=aNewYFact; + m_aXFact=aNewXFact; + m_aYFact=aNewYFact; aNewXFact = double(aNewXFact) > 0 ? aNewXFact : Fraction(1, 1); aNewYFact = double(aNewYFact) > 0 ? aNewYFact : Fraction(1, 1); @@ -2020,7 +2020,7 @@ void SdrDragResize::MoveSdrDrag(const Point& rNoSnapPnt) void SdrDragResize::applyCurrentTransformationToSdrObject(SdrObject& rTarget) { - rTarget.Resize(DragStat().GetRef1(),aXFact,aYFact); + rTarget.Resize(DragStat().GetRef1(),m_aXFact,m_aYFact); } bool SdrDragResize::EndSdrDrag(bool bCopy) @@ -2029,15 +2029,15 @@ bool SdrDragResize::EndSdrDrag(bool bCopy) if (IsDraggingPoints()) { - getSdrDragView().ResizeMarkedPoints(DragStat().GetRef1(),aXFact,aYFact); + getSdrDragView().ResizeMarkedPoints(DragStat().GetRef1(),m_aXFact,m_aYFact); } else if (IsDraggingGluePoints()) { - getSdrDragView().ResizeMarkedGluePoints(DragStat().GetRef1(),aXFact,aYFact,bCopy); + getSdrDragView().ResizeMarkedGluePoints(DragStat().GetRef1(),m_aXFact,m_aYFact,bCopy); } else { - getSdrDragView().ResizeMarkedObj(DragStat().GetRef1(),aXFact,aYFact,bCopy); + getSdrDragView().ResizeMarkedObj(DragStat().GetRef1(),m_aXFact,m_aYFact,bCopy); } return true;