class_pad.h: mark m_shapesDirty true after a move to force rebuild shapes after a move.

Fix also a few comments.

Fixes #4719
https://gitlab.com/kicad/code/kicad/issues/4719

Fixes #4720
https://gitlab.com/kicad/code/kicad/issues/4720
This commit is contained in:
jean-pierre charras 2020-06-25 19:16:03 +02:00
parent 534bcc8db0
commit c9715ce304
1 changed files with 16 additions and 3 deletions

View File

@ -139,13 +139,25 @@ public:
}
/**
* Function GetShape
* Set the new shape of this pad.
*/
void SetShape( PAD_SHAPE_T aShape )
{
m_padShape = aShape;
m_shapesDirty = true;
}
/**
* @return the shape of this pad.
*/
void SetShape( PAD_SHAPE_T aShape ) { m_padShape = aShape; m_shapesDirty = true; }
PAD_SHAPE_T GetShape() const { return m_padShape; }
void SetPosition( const wxPoint& aPos ) override { m_Pos = aPos; }
void SetPosition( const wxPoint& aPos ) override
{
m_Pos = aPos;
m_shapesDirty = true;
}
const wxPoint GetPosition() const override { return m_Pos; }
/**
@ -516,6 +528,7 @@ public:
{
m_Pos += aMoveVector;
SetLocalCoord();
m_shapesDirty = true;
}
void Rotate( const wxPoint& aRotCentre, double aAngle ) override;