summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-10-04 14:03:45 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-10-04 19:47:15 +0200
commitcc633cee77e938a1da7252bb90d5b013487dc81a (patch)
treec02f160729359e22fe449d7dae8c0065ec59f34a /svx
parentcc354c104e09a2f35faf06a3df9d044ced94d6a9 (diff)
tdf#120291 Attaching a connector makes draw Draw busy-loop
regression from commit ffe84f49270e0a8818365ca7d1fd5242abff5562 remove SdrObject::GetHdl in favour of AddToHdlList Change-Id: Idb15b976f6e1fcb6ffeda933ffbec96d59e6f155 Reviewed-on: https://gerrit.libreoffice.org/61370 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svx')
-rw-r--r--svx/source/svdraw/svdoedge.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/svx/source/svdraw/svdoedge.cxx b/svx/source/svdraw/svdoedge.cxx
index c32fdefe51d2..cc7e61c9dfe9 100644
--- a/svx/source/svdraw/svdoedge.cxx
+++ b/svx/source/svdraw/svdoedge.cxx
@@ -1792,9 +1792,10 @@ void SdrEdgeObj::AddToHdlList(SdrHdlList& rHdlList) const
sal_uInt32 nO1(aEdgeInfo.nObj1Lines > 0 ? aEdgeInfo.nObj1Lines - 1 : 0);
sal_uInt32 nO2(aEdgeInfo.nObj2Lines > 0 ? aEdgeInfo.nObj2Lines - 1 : 0);
sal_uInt32 nM(aEdgeInfo.nMiddleLine != 0xFFFF ? 1 : 0);
- for(sal_uInt32 nNum = 0; nNum < (nO1 + nO2 + nM); ++nNum)
+ for(sal_uInt32 i = 0; i < (nO1 + nO2 + nM); ++i)
{
sal_Int32 nPt(0);
+ sal_uInt32 nNum = i;
std::unique_ptr<ImpEdgeHdl> pHdl(new ImpEdgeHdl(Point(),SdrHdlKind::Poly));
if (nNum<nO1) {
nPt=nNum+1;
@@ -1820,7 +1821,7 @@ void SdrEdgeObj::AddToHdlList(SdrHdlList& rHdlList) const
aPos.setX( aPos.X() / 2 );
aPos.setY( aPos.Y() / 2 );
pHdl->SetPos(aPos);
- pHdl->SetPointNum(nNum + 2);
+ pHdl->SetPointNum(i + 2);
rHdlList.AddHdl(std::move(pHdl));
}
}