diff --git a/common/eda_shape.cpp b/common/eda_shape.cpp index 0e879723de..279d5d9754 100644 --- a/common/eda_shape.cpp +++ b/common/eda_shape.cpp @@ -37,14 +37,13 @@ #include -EDA_SHAPE::EDA_SHAPE( SHAPE_T aType, int aLineWidth, FILL_T aFill, bool upsideDownCoords ) : +EDA_SHAPE::EDA_SHAPE( SHAPE_T aType, int aLineWidth, FILL_T aFill ) : m_endsSwapped( false ), m_shape( aType ), m_stroke( aLineWidth, PLOT_DASH_TYPE::DEFAULT, COLOR4D::UNSPECIFIED ), m_fill( aFill ), m_fillColor( COLOR4D::UNSPECIFIED ), - m_editState( 0 ), - m_upsideDownCoords( upsideDownCoords ) + m_editState( 0 ) { } @@ -747,9 +746,6 @@ bool EDA_SHAPE::hitTest( const VECTOR2I& aPosition, int aAccuracy ) const EDA_ANGLE endAngle; CalcArcAngles( startAngle, endAngle ); - if( m_upsideDownCoords && ( startAngle - endAngle ).Normalize180() > ANGLE_0 ) - std::swap( startAngle, endAngle ); - EDA_ANGLE relPosAngle( relPos ); startAngle.Normalize(); @@ -1035,9 +1031,6 @@ void EDA_SHAPE::computeArcBBox( EDA_RECT& aBBox ) const CalcArcAngles( t1, t2 ); - if( m_upsideDownCoords && ( t1 - t2 ).Normalize180() > ANGLE_0 ) - std::swap( t1, t2 ); - t1.Normalize(); t2.Normalize(); @@ -1448,7 +1441,6 @@ void EDA_SHAPE::SwapShape( EDA_SHAPE* aImage ) SWAPITEM( m_poly ); SWAPITEM( m_fill ); SWAPITEM( m_fillColor ); - SWAPITEM( m_upsideDownCoords ); SWAPITEM( m_editState ); SWAPITEM( m_endsSwapped ); #undef SWAPITEM diff --git a/eeschema/lib_shape.cpp b/eeschema/lib_shape.cpp index 5bc40751f2..2ce8bb47b8 100644 --- a/eeschema/lib_shape.cpp +++ b/eeschema/lib_shape.cpp @@ -36,7 +36,7 @@ LIB_SHAPE::LIB_SHAPE( LIB_SYMBOL* aParent, SHAPE_T aShape, int aLineWidth, FILL_T aFillType, KICAD_T aType ) : LIB_ITEM( aType, aParent ), - EDA_SHAPE( aShape, aLineWidth, aFillType, true ) + EDA_SHAPE( aShape, aLineWidth, aFillType ) { m_editState = 0; } diff --git a/eeschema/sch_shape.cpp b/eeschema/sch_shape.cpp index 8f817b8840..ef296b388a 100644 --- a/eeschema/sch_shape.cpp +++ b/eeschema/sch_shape.cpp @@ -36,7 +36,7 @@ SCH_SHAPE::SCH_SHAPE( SHAPE_T aShape, int aLineWidth, FILL_T aFillType, KICAD_T aType ) : SCH_ITEM( nullptr, aType ), - EDA_SHAPE( aShape, aLineWidth, aFillType, false ) + EDA_SHAPE( aShape, aLineWidth, aFillType ) { SetLayer( LAYER_NOTES ); } diff --git a/include/eda_shape.h b/include/eda_shape.h index d6c73f577d..f8a3308906 100644 --- a/include/eda_shape.h +++ b/include/eda_shape.h @@ -73,7 +73,7 @@ struct ARC_MID class EDA_SHAPE { public: - EDA_SHAPE( SHAPE_T aType, int aLineWidth, FILL_T aFill, bool eeWinding ); + EDA_SHAPE( SHAPE_T aType, int aLineWidth, FILL_T aFill ); // Do not create a copy constructor & operator=. // The ones generated by the compiler are adequate. @@ -377,7 +377,6 @@ protected: SHAPE_POLY_SET m_poly; // Stores the S_POLYGON shape int m_editState; - bool m_upsideDownCoords; // Awful hack }; #endif // EDA_SHAPE_H diff --git a/pcbnew/pcb_shape.cpp b/pcbnew/pcb_shape.cpp index c280e35129..38eac89495 100644 --- a/pcbnew/pcb_shape.cpp +++ b/pcbnew/pcb_shape.cpp @@ -36,14 +36,14 @@ PCB_SHAPE::PCB_SHAPE( BOARD_ITEM* aParent, KICAD_T aItemType, SHAPE_T aShapeType ) : BOARD_ITEM( aParent, aItemType ), - EDA_SHAPE( aShapeType, Millimeter2iu( DEFAULT_LINE_WIDTH ), FILL_T::NO_FILL, false ) + EDA_SHAPE( aShapeType, Millimeter2iu( DEFAULT_LINE_WIDTH ), FILL_T::NO_FILL ) { } PCB_SHAPE::PCB_SHAPE( BOARD_ITEM* aParent, SHAPE_T shapetype ) : BOARD_ITEM( aParent, PCB_SHAPE_T ), - EDA_SHAPE( shapetype, Millimeter2iu( DEFAULT_LINE_WIDTH ), FILL_T::NO_FILL, false ) + EDA_SHAPE( shapetype, Millimeter2iu( DEFAULT_LINE_WIDTH ), FILL_T::NO_FILL ) { }