This is an automated email from the ASF dual-hosted git repository. mseidel pushed a commit to branch Pilot-Pirx-glue in repository https://gitbox.apache.org/repos/asf/openoffice.git
commit cb22d026f28016a262df1aea284f30c61ee0e249 Author: Matthias Seidel <[email protected]> AuthorDate: Sun Apr 9 18:02:35 2023 +0200 Remove unused(?) code Gluepoint is actually generated here: https://github.com/apache/openoffice/blob/trunk/main/svx/source/sdr/primitive2d/sdrprimitivetools.cxx#L80 This part looks like a leftover for me. "SdrGluePoint::Draw" is only to be found in this file and nowhere else: http://opengrok.openoffice.org/search?project=trunk&full=%22SdrGluePoint%3A%3ADraw%22 --- main/svx/source/svdraw/svdglue.cxx | 39 -------------------------------------- 1 file changed, 39 deletions(-) diff --git a/main/svx/source/svdraw/svdglue.cxx b/main/svx/source/svdraw/svdglue.cxx index d2765a38af..bafa04468f 100644 --- a/main/svx/source/svdraw/svdglue.cxx +++ b/main/svx/source/svdraw/svdglue.cxx @@ -247,45 +247,6 @@ void SdrGluePoint::Shear(const Point& rRef, long /*nWink*/, double tn, FASTBOOL if (pObj!=NULL) SetAbsolutePos(aPt,*pObj); else SetPos(aPt); } -// Unused code?! -void SdrGluePoint::Draw(OutputDevice& rOut, const SdrObject* pObj) const -{ - Color aBackPenColor(COL_WHITE); - Color aForePenColor(COL_LIGHTBLUE); - - bool bMapMerk=rOut.IsMapModeEnabled(); - Point aPt(pObj!=NULL ? GetAbsolutePos(*pObj) : GetPos()); - aPt=rOut.LogicToPixel(aPt); - rOut.EnableMapMode(sal_False); - long x=aPt.X(),y=aPt.Y(); // Groesse erstmal fest auf 7 Pixel - - rOut.SetLineColor( aBackPenColor ); - rOut.DrawLine(Point(x-2,y-3),Point(x+3,y+2)); - rOut.DrawLine(Point(x-3,y-2),Point(x+2,y+3)); - rOut.DrawLine(Point(x-3,y+2),Point(x+2,y-3)); - rOut.DrawLine(Point(x-2,y+3),Point(x+3,y-2)); - - if (bNoPercent) - { - switch (GetHorzAlign()) - { - case SDRHORZALIGN_LEFT : rOut.DrawLine(Point(x-3,y-1),Point(x-3,y+1)); break; - case SDRHORZALIGN_RIGHT : rOut.DrawLine(Point(x+3,y-1),Point(x+3,y+1)); break; - } - - switch (GetVertAlign()) - { - case SDRVERTALIGN_TOP : rOut.DrawLine(Point(x-1,y-3),Point(x+1,y-3)); break; - case SDRVERTALIGN_BOTTOM: rOut.DrawLine(Point(x-1,y+3),Point(x+1,y+3)); break; - } - } - - rOut.SetLineColor( aForePenColor ); - rOut.DrawLine(Point(x-2,y-2),Point(x+2,y+2)); - rOut.DrawLine(Point(x-2,y+2),Point(x+2,y-2)); - rOut.EnableMapMode(bMapMerk); -} - void SdrGluePoint::Invalidate(Window& rWin, const SdrObject* pObj) const { bool bMapMerk=rWin.IsMapModeEnabled();
