pcbnew: Correct polygon flipping in custom pads

Custom pads are referenced to the anchor pad 0-point, so flipping the
polygon should be about 0 and not the flip point.

Fixes: lp:1831311
* https://bugs.launchpad.net/kicad/+bug/1831311
This commit is contained in:
Seth Hillbrand 2019-06-15 15:25:54 -07:00
parent aa3aafc4ff
commit 909a25c147
1 changed files with 2 additions and 2 deletions

View File

@ -496,7 +496,7 @@ void D_PAD::MirrorXPrimitives( int aX )
{ {
case S_POLYGON: // polygon case S_POLYGON: // polygon
for( unsigned jj = 0; jj < primitive.m_Poly.size(); jj++ ) for( unsigned jj = 0; jj < primitive.m_Poly.size(); jj++ )
MIRROR( primitive.m_Poly[jj].x, aX ); MIRROR( primitive.m_Poly[jj].x, 0 );
break; break;
default: default:
@ -510,7 +510,7 @@ void D_PAD::MirrorXPrimitives( int aX )
SHAPE_LINE_CHAIN& poly = m_customShapeAsPolygon.Outline( cnt ); SHAPE_LINE_CHAIN& poly = m_customShapeAsPolygon.Outline( cnt );
for( int ii = 0; ii < poly.PointCount(); ++ii ) for( int ii = 0; ii < poly.PointCount(); ++ii )
MIRROR( poly.Point( ii ).x, aX ); MIRROR( poly.Point( ii ).x, 0 );
} }
} }