Footprint editor: display a warning when trying to created a custom pad shape with a Bezier curve.

Currently, Bezier curve (S_CURVE shape) is not supported in a custom pad shape.
This commit is contained in:
jean-pierre charras 2018-07-22 17:11:16 +02:00
parent 4cac974420
commit db712ea643
1 changed files with 7 additions and 0 deletions

View File

@ -348,6 +348,13 @@ int MODULE_EDITOR_TOOLS::CreatePadFromShapes( const TOOL_EVENT& aEvent )
{ {
auto em = static_cast<EDGE_MODULE*> ( item ); auto em = static_cast<EDGE_MODULE*> ( item );
// Currently, S_CURVE shape is not supported. so warn the user
if( em->GetShape() == S_CURVE )
{
illegalItemsFound = true;
break;
}
PAD_CS_PRIMITIVE shape( em->GetShape() ); PAD_CS_PRIMITIVE shape( em->GetShape() );
shape.m_Start = em->GetStart(); shape.m_Start = em->GetStart();
shape.m_End = em->GetEnd(); shape.m_End = em->GetEnd();