Preserve logic that assumes footprint shapes can't have nets

This commit is contained in:
Jon Evans 2023-08-11 00:01:39 -04:00
parent f70b9920cb
commit e9c51f1d12
2 changed files with 9 additions and 0 deletions

View File

@ -86,6 +86,13 @@ bool PCB_SHAPE::IsType( const std::vector<KICAD_T>& aScanTypes ) const
}
bool PCB_SHAPE::IsConnected() const
{
// Only board-level copper shapes are connectable
return IsOnCopperLayer() && !GetParentFootprint();
}
void PCB_SHAPE::SetLayer( PCB_LAYER_ID aLayer )
{
BOARD_ITEM::SetLayer( aLayer );

View File

@ -57,6 +57,8 @@ public:
return wxT( "PCB_SHAPE" );
}
bool IsConnected() const override;
wxString GetFriendlyName() const override { return EDA_SHAPE::GetFriendlyName(); }
bool IsType( const std::vector<KICAD_T>& aScanTypes ) const override;