Commit 873e0740 authored by John Beard's avatar John Beard Committed by Wayne Stambaugh

Fix bug in footrpint editor when creating circular arrays. (fixes lp:1424331)

parent 00f8994e
...@@ -324,3 +324,12 @@ void EDGE_MODULE::Flip( const wxPoint& aCentre ) ...@@ -324,3 +324,12 @@ void EDGE_MODULE::Flip( const wxPoint& aCentre )
SetLayer( FlipLayer( GetLayer() ) ); SetLayer( FlipLayer( GetLayer() ) );
} }
void EDGE_MODULE::Rotate( const wxPoint& aRotCentre, double aAngle )
{
// do the base class rotation
DRAWSEGMENT::Rotate( aRotCentre, aAngle );
// and now work out the new offset
SetLocalCoord();
}
...@@ -100,6 +100,8 @@ public: ...@@ -100,6 +100,8 @@ public:
EDA_ITEM* Clone() const; EDA_ITEM* Clone() const;
void Rotate( const wxPoint& aRotCentre, double aAngle ); // override
#if defined(DEBUG) #if defined(DEBUG)
void Show( int nestLevel, std::ostream& os ) const { ShowDummy( os ); } // override void Show( int nestLevel, std::ostream& os ) const { ShowDummy( os ); } // override
#endif #endif
......
...@@ -838,6 +838,9 @@ void D_PAD::Rotate( const wxPoint& aRotCentre, double aAngle ) ...@@ -838,6 +838,9 @@ void D_PAD::Rotate( const wxPoint& aRotCentre, double aAngle )
{ {
RotatePoint( &m_Pos, aRotCentre, aAngle ); RotatePoint( &m_Pos, aRotCentre, aAngle );
m_Orient += aAngle; m_Orient += aAngle;
NORMALIZE_ANGLE_360( m_Orient );
SetLocalCoord();
} }
......
...@@ -90,8 +90,11 @@ TEXTE_MODULE::~TEXTE_MODULE() ...@@ -90,8 +90,11 @@ TEXTE_MODULE::~TEXTE_MODULE()
void TEXTE_MODULE::Rotate( const wxPoint& aRotCentre, double aAngle ) void TEXTE_MODULE::Rotate( const wxPoint& aRotCentre, double aAngle )
{ {
RotatePoint( &m_Pos, aRotCentre, aAngle ); RotatePoint( &m_Pos, aRotCentre, aAngle );
m_Orient += aAngle; m_Orient += aAngle;
NORMALIZE_ANGLE_360( m_Orient ); NORMALIZE_ANGLE_360( m_Orient );
SetLocalCoord();
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment