From 8fd9020b2b5ae1024dbf866cd84cf28258aba232 Mon Sep 17 00:00:00 2001 From: Miklos Vajna Date: Mon, 11 Jan 2016 09:09:14 +0100 Subject: svx: SdrDragStat::GetPointAnz() -> GetPointCount() Change-Id: Ib8728408a81c655c36b46a8483970c38e9a40bc4 --- svx/source/engine3d/scene3d.cxx | 2 +- svx/source/svdraw/svdcrtv.cxx | 6 +++--- svx/source/svdraw/svddrag.cxx | 2 +- svx/source/svdraw/svdoashp.cxx | 2 +- svx/source/svdraw/svdobj.cxx | 2 +- svx/source/svdraw/svdocapt.cxx | 2 +- svx/source/svdraw/svdocirc.cxx | 26 +++++++++++++------------- svx/source/svdraw/svdoedge.cxx | 2 +- svx/source/svdraw/svdomeas.cxx | 2 +- svx/source/svdraw/svdopath.cxx | 4 ++-- svx/source/svdraw/svdotxdr.cxx | 2 +- svx/source/table/svdotable.cxx | 2 +- 12 files changed, 27 insertions(+), 27 deletions(-) (limited to 'svx') diff --git a/svx/source/engine3d/scene3d.cxx b/svx/source/engine3d/scene3d.cxx index 2d077494383e..53d35acf95fb 100644 --- a/svx/source/engine3d/scene3d.cxx +++ b/svx/source/engine3d/scene3d.cxx @@ -702,7 +702,7 @@ bool E3dScene::EndCreate(SdrDragStat& rStat, SdrCreateCmd eCmd) aRect1.Justify(); NbcSetSnapRect(aRect1); SetRectsDirty(); - return (eCmd==SDRCREATE_FORCEEND || rStat.GetPointAnz()>=2); + return (eCmd==SDRCREATE_FORCEEND || rStat.GetPointCount()>=2); } bool E3dScene::BckCreate(SdrDragStat& /*rStat*/) diff --git a/svx/source/svdraw/svdcrtv.cxx b/svx/source/svdraw/svdcrtv.cxx index d9140bf7a8b6..0e4719f83807 100644 --- a/svx/source/svdraw/svdcrtv.cxx +++ b/svx/source/svdraw/svdcrtv.cxx @@ -601,7 +601,7 @@ bool SdrCreateView::EndCreateObj(SdrCreateCmd eCmd) if (pAktCreate!=nullptr) { - sal_uIntPtr nCount=maDragStat.GetPointAnz(); + sal_uIntPtr nCount=maDragStat.GetPointCount(); if (nCount<=1 && eCmd==SDRCREATE_FORCEEND) { @@ -710,7 +710,7 @@ void SdrCreateView::BckCreateObj() { if (pAktCreate!=nullptr) { - if (maDragStat.GetPointAnz()<=2 ) + if (maDragStat.GetPointCount()<=2 ) { BrkCreateObj(); } @@ -791,7 +791,7 @@ void SdrCreateView::ShowCreateObj(/*OutputDevice* pOut, sal_Bool bFull*/) if(pCircObj && OBJ_CIRC != pCircObj->GetObjIdentifier()) { // #i103058# Allow SolidDragging with four points - if(maDragStat.GetPointAnz() < 4) + if(maDragStat.GetPointCount() < 4) { bUseSolidDragging = false; } diff --git a/svx/source/svdraw/svddrag.cxx b/svx/source/svdraw/svddrag.cxx index 91cd2d145072..411cc9127cf6 100644 --- a/svx/source/svdraw/svddrag.cxx +++ b/svx/source/svdraw/svddrag.cxx @@ -127,7 +127,7 @@ Fraction SdrDragStat::GetYFact() const void SdrDragStat::TakeCreateRect(Rectangle& rRect) const { rRect=Rectangle(GetStart(),GetNow()); - if (GetPointAnz()>=2) { + if (GetPointCount()>=2) { Point aBtmRgt(GetPoint(1)); rRect.Right()=aBtmRgt.X(); rRect.Bottom()=aBtmRgt.Y(); diff --git a/svx/source/svdraw/svdoashp.cxx b/svx/source/svdraw/svdoashp.cxx index 6304c471dd5d..e69eaa4854a5 100644 --- a/svx/source/svdraw/svdoashp.cxx +++ b/svx/source/svdraw/svdoashp.cxx @@ -2211,7 +2211,7 @@ bool SdrObjCustomShape::EndCreate( SdrDragStat& rStat, SdrCreateCmd eCmd ) AdaptTextMinSize(); SetRectsDirty(); - return ( eCmd == SDRCREATE_FORCEEND || rStat.GetPointAnz() >= 2 ); + return ( eCmd == SDRCREATE_FORCEEND || rStat.GetPointCount() >= 2 ); } basegfx::B2DPolyPolygon SdrObjCustomShape::TakeCreatePoly(const SdrDragStat& /*rDrag*/) const diff --git a/svx/source/svdraw/svdobj.cxx b/svx/source/svdraw/svdobj.cxx index b48665dd8197..8f8429568027 100644 --- a/svx/source/svdraw/svdobj.cxx +++ b/svx/source/svdraw/svdobj.cxx @@ -1372,7 +1372,7 @@ bool SdrObject::EndCreate(SdrDragStat& rStat, SdrCreateCmd eCmd) rStat.TakeCreateRect(aOutRect); aOutRect.Justify(); - return (eCmd==SDRCREATE_FORCEEND || rStat.GetPointAnz()>=2); + return (eCmd==SDRCREATE_FORCEEND || rStat.GetPointCount()>=2); } void SdrObject::BrkCreate(SdrDragStat& /*rStat*/) diff --git a/svx/source/svdraw/svdocapt.cxx b/svx/source/svdraw/svdocapt.cxx index fc3b0f03ebd1..b23d0e9159b9 100644 --- a/svx/source/svdraw/svdocapt.cxx +++ b/svx/source/svdraw/svdocapt.cxx @@ -577,7 +577,7 @@ bool SdrCaptionObj::EndCreate(SdrDragStat& rStat, SdrCreateCmd eCmd) maRect.SetPos(rStat.GetNow()); ImpCalcTail(aPara,aTailPoly,maRect); SetRectsDirty(); - return (eCmd==SDRCREATE_FORCEEND || rStat.GetPointAnz()>=2); + return (eCmd==SDRCREATE_FORCEEND || rStat.GetPointCount()>=2); } bool SdrCaptionObj::BckCreate(SdrDragStat& /*rStat*/) diff --git a/svx/source/svdraw/svdocirc.cxx b/svx/source/svdraw/svdocirc.cxx index 318d140e89a5..9db693604359 100644 --- a/svx/source/svdraw/svdocirc.cxx +++ b/svx/source/svdraw/svdocirc.cxx @@ -563,7 +563,7 @@ OUString SdrCircObj::getSpecialDragComment(const SdrDragStat& rDrag) const OUString aStr; ImpTakeDescriptionStr(STR_ViewCreateObj, aStr); OUStringBuffer aBuf(aStr); - const sal_uInt32 nPointCount(rDrag.GetPointAnz()); + const sal_uInt32 nPointCount(rDrag.GetPointCount()); if(OBJ_CIRC != meCircleKind && nPointCount > 2) { @@ -623,7 +623,7 @@ void ImpCircUser::SetCreateParams(SdrDragStat& rStat) nMaxRad=((nWdt>nHgt ? nWdt : nHgt)+1) /2; nStart=0; nEnd=36000; - if (rStat.GetPointAnz()>2) { + if (rStat.GetPointCount()>2) { Point aP(rStat.GetPoint(2)-aCenter); if (nWdt==0) aP.X()=0; if (nHgt==0) aP.Y()=0; @@ -646,7 +646,7 @@ void ImpCircUser::SetCreateParams(SdrDragStat& rStat) nEnd=nStart; aP2=aP1; } else aP1=aCenter; - if (rStat.GetPointAnz()>3) { + if (rStat.GetPointCount()>3) { Point aP(rStat.GetPoint(3)-aCenter); if (nWdt>=nHgt) { aP.Y()=BigMulDiv(aP.Y(),nWdt,nHgt); @@ -703,7 +703,7 @@ bool SdrCircObj::MovCreate(SdrDragStat& rStat) // #i103058# push current angle settings to ItemSet to // allow FullDrag visualisation - if(rStat.GetPointAnz() >= 4) + if(rStat.GetPointCount() >= 4) { ImpSetCircInfoToAttr(); } @@ -716,17 +716,17 @@ bool SdrCircObj::EndCreate(SdrDragStat& rStat, SdrCreateCmd eCmd) ImpSetCreateParams(rStat); ImpCircUser* pU=static_cast(rStat.GetUser()); bool bRet = false; - if (eCmd==SDRCREATE_FORCEEND && rStat.GetPointAnz()<4) meCircleKind=OBJ_CIRC; + if (eCmd==SDRCREATE_FORCEEND && rStat.GetPointCount()<4) meCircleKind=OBJ_CIRC; if (meCircleKind==OBJ_CIRC) { - bRet=rStat.GetPointAnz()>=2; + bRet=rStat.GetPointCount()>=2; if (bRet) { maRect = pU->aR; ImpJustifyRect(maRect); } } else { - rStat.SetNoSnap(rStat.GetPointAnz()>=2); - rStat.SetOrtho4Possible(rStat.GetPointAnz()<2); - bRet=rStat.GetPointAnz()>=4; + rStat.SetNoSnap(rStat.GetPointCount()>=2); + rStat.SetOrtho4Possible(rStat.GetPointCount()<2); + bRet=rStat.GetPointCount()>=4; if (bRet) { maRect = pU->aR; ImpJustifyRect(maRect); @@ -754,8 +754,8 @@ void SdrCircObj::BrkCreate(SdrDragStat& rStat) bool SdrCircObj::BckCreate(SdrDragStat& rStat) { - rStat.SetNoSnap(rStat.GetPointAnz()>=3); - rStat.SetOrtho4Possible(rStat.GetPointAnz()<3); + rStat.SetNoSnap(rStat.GetPointCount()>=3); + rStat.SetOrtho4Possible(rStat.GetPointCount()<3); return meCircleKind!=OBJ_CIRC; } @@ -763,12 +763,12 @@ basegfx::B2DPolyPolygon SdrCircObj::TakeCreatePoly(const SdrDragStat& rDrag) con { const ImpCircUser* pU = static_cast(rDrag.GetUser()); - if(rDrag.GetPointAnz() < 4L) + if(rDrag.GetPointCount() < 4L) { // force to OBJ_CIRC to get full visualisation basegfx::B2DPolyPolygon aRetval(ImpCalcXPolyCirc(OBJ_CIRC, pU->aR, pU->nStart, pU->nEnd)); - if(3L == rDrag.GetPointAnz()) + if(3L == rDrag.GetPointCount()) { // add edge to first point on ellipse basegfx::B2DPolygon aNew; diff --git a/svx/source/svdraw/svdoedge.cxx b/svx/source/svdraw/svdoedge.cxx index b2865b684bbc..c2e0e71dd6b7 100644 --- a/svx/source/svdraw/svdoedge.cxx +++ b/svx/source/svdraw/svdoedge.cxx @@ -2054,7 +2054,7 @@ bool SdrEdgeObj::MovCreate(SdrDragStat& rDragStat) bool SdrEdgeObj::EndCreate(SdrDragStat& rDragStat, SdrCreateCmd eCmd) { - bool bOk=(eCmd==SDRCREATE_FORCEEND || rDragStat.GetPointAnz()>=2); + bool bOk=(eCmd==SDRCREATE_FORCEEND || rDragStat.GetPointCount()>=2); if (bOk) { ConnectToNode(true,aCon1.pObj); ConnectToNode(false,aCon2.pObj); diff --git a/svx/source/svdraw/svdomeas.cxx b/svx/source/svdraw/svdomeas.cxx index 4fdeeef1c31c..9b2fbd29645f 100644 --- a/svx/source/svdraw/svdomeas.cxx +++ b/svx/source/svdraw/svdomeas.cxx @@ -996,7 +996,7 @@ bool SdrMeasureObj::EndCreate(SdrDragStat& rStat, SdrCreateCmd eCmd) { SetTextDirty(); SetRectsDirty(); - return (eCmd==SDRCREATE_FORCEEND || rStat.GetPointAnz()>=2); + return (eCmd==SDRCREATE_FORCEEND || rStat.GetPointCount()>=2); } bool SdrMeasureObj::BckCreate(SdrDragStat& /*rStat*/) diff --git a/svx/source/svdraw/svdopath.cxx b/svx/source/svdraw/svdopath.cxx index 42a0edba9ca1..88e8eed822d6 100644 --- a/svx/source/svdraw/svdopath.cxx +++ b/svx/source/svdraw/svdopath.cxx @@ -1411,7 +1411,7 @@ bool ImpPathForDragAndCreate::EndCreate(SdrDragStat& rStat, SdrCreateCmd eCmd) sal_uInt16 nActPoint=rXPoly.GetPointCount()-1; rXPoly[nActPoint]=rStat.Now(); if (!pU->bMixedCreate && pU->eStartKind==OBJ_LINE) { - if (rStat.GetPointAnz()>=2) eCmd=SDRCREATE_FORCEEND; + if (rStat.GetPointCount()>=2) eCmd=SDRCREATE_FORCEEND; bRet = eCmd==SDRCREATE_FORCEEND; if (bRet) { mbCreating = false; @@ -1422,7 +1422,7 @@ bool ImpPathForDragAndCreate::EndCreate(SdrDragStat& rStat, SdrCreateCmd eCmd) } if (!pU->bMixedCreate && IsFreeHand(pU->eStartKind)) { - if (rStat.GetPointAnz()>=2) eCmd=SDRCREATE_FORCEEND; + if (rStat.GetPointCount()>=2) eCmd=SDRCREATE_FORCEEND; bRet=eCmd==SDRCREATE_FORCEEND; if (bRet) { mbCreating=false; diff --git a/svx/source/svdraw/svdotxdr.cxx b/svx/source/svdraw/svdotxdr.cxx index 004453006a86..70993e660b3f 100644 --- a/svx/source/svdraw/svdotxdr.cxx +++ b/svx/source/svdraw/svdotxdr.cxx @@ -217,7 +217,7 @@ bool SdrTextObj::EndCreate(SdrDragStat& rStat, SdrCreateCmd eCmd) if (dynamic_cast(this) != nullptr) { static_cast(this)->SetXPolyDirty(); } - return (eCmd==SDRCREATE_FORCEEND || rStat.GetPointAnz()>=2); + return (eCmd==SDRCREATE_FORCEEND || rStat.GetPointCount()>=2); } void SdrTextObj::BrkCreate(SdrDragStat& /*rStat*/) diff --git a/svx/source/table/svdotable.cxx b/svx/source/table/svdotable.cxx index 15bbb7f640c3..4f575d75a40c 100644 --- a/svx/source/table/svdotable.cxx +++ b/svx/source/table/svdotable.cxx @@ -2402,7 +2402,7 @@ bool SdrTableObj::EndCreate(SdrDragStat& rStat, SdrCreateCmd eCmd) { rStat.TakeCreateRect(maRect); ImpJustifyRect(maRect); - return (eCmd==SDRCREATE_FORCEEND || rStat.GetPointAnz()>=2); + return (eCmd==SDRCREATE_FORCEEND || rStat.GetPointCount()>=2); } void SdrTableObj::BrkCreate(SdrDragStat& /*rStat*/) -- cgit