Don't consider heatsink, castellated or fiducial pads for THT vs SMD.
Also fixes a bug where the Footprint Checker's marker list wasn't cleared correctly from the last run. Fixes https://gitlab.com/kicad/code/kicad/issues/9821
This commit is contained in:
parent
dede3f5709
commit
3af65936c1
|
@ -96,6 +96,8 @@ void DIALOG_FOOTPRINT_CHECKER::runChecks()
|
|||
FOOTPRINT* footprint = board->GetFirstFootprint();
|
||||
wxString msg;
|
||||
|
||||
SetMarkersProvider( new BOARD_DRC_ITEMS_PROVIDER( board ) );
|
||||
|
||||
deleteAllMarkers();
|
||||
|
||||
if( !footprint )
|
||||
|
@ -150,7 +152,7 @@ void DIALOG_FOOTPRINT_CHECKER::runChecks()
|
|||
footprint->CheckFootprintTHPadNoHoles( &tstHoleInTHPad );
|
||||
m_checksRun = true;
|
||||
|
||||
SetMarkersProvider( new BOARD_DRC_ITEMS_PROVIDER( m_frame->GetBoard() ) );
|
||||
SetMarkersProvider( new BOARD_DRC_ITEMS_PROVIDER( board ) );
|
||||
|
||||
refreshEditor();
|
||||
}
|
||||
|
|
|
@ -657,14 +657,32 @@ int FOOTPRINT::GetLikelyAttribute() const
|
|||
|
||||
for( PAD* pad : m_pads )
|
||||
{
|
||||
switch( pad->GetProperty() )
|
||||
{
|
||||
case PAD_PROP::FIDUCIAL_GLBL:
|
||||
case PAD_PROP::FIDUCIAL_LOCAL:
|
||||
continue;
|
||||
|
||||
case PAD_PROP::HEATSINK:
|
||||
case PAD_PROP::CASTELLATED:
|
||||
continue;
|
||||
|
||||
case PAD_PROP::NONE:
|
||||
case PAD_PROP::BGA:
|
||||
case PAD_PROP::TESTPOINT:
|
||||
break;
|
||||
}
|
||||
|
||||
switch( pad->GetAttribute() )
|
||||
{
|
||||
case PAD_ATTRIB::PTH:
|
||||
tht_count++;
|
||||
break;
|
||||
|
||||
case PAD_ATTRIB::SMD:
|
||||
smd_count++;
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue