Ensure newly added pads are counted

When adding a new footprint, don't delete the single-pad nets until you
check for the net being added as part of the footprint

Fixes https://gitlab.com/kicad/code/kicad/issues/9053
This commit is contained in:
Seth Hillbrand 2021-09-01 15:11:30 -07:00
parent 243631a095
commit f14e5b61b3
1 changed files with 9 additions and 0 deletions

View File

@ -788,6 +788,15 @@ bool BOARD_NETLIST_UPDATER::deleteSinglePadNets()
std::vector<PAD*> padlist = m_board->GetPads();
// Add the new pads
for( FOOTPRINT* fp : m_addedFootprints)
{
for( PAD* pad : fp->Pads() )
{
padlist.push_back( pad );
}
}
// Sort pads by netlist name
std::sort( padlist.begin(), padlist.end(),
[ this ]( PAD* a, PAD* b ) -> bool