mirror of
https://gitlab.com/kicad/code/kicad.git
synced 2025-09-14 02:03:12 +02:00
Skip same-net-checking for hole-to-hole collisions.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/20547
This commit is contained in:
parent
c519a6b827
commit
b14472e105
@ -152,9 +152,11 @@ bool ITEM::collideSimple( const ITEM* aHead, const NODE* aNode, int aLayer,
|
||||
// And a special case for the "head" via's hole.
|
||||
if( aHead->HasHole() && shouldWeConsiderHoleCollisions( this, holeH ) )
|
||||
{
|
||||
if( Net() != holeH->Net() && collideSimple( holeH, aNode, aLayer, aCtx ) )
|
||||
collisionsFound = true;
|
||||
// Skip net check when doing hole-to-hole collisions.
|
||||
if( Kind() == HOLE_T || Net() != holeH->Net() )
|
||||
collisionsFound |= collideSimple( holeH, aNode, aLayer, aCtx );
|
||||
}
|
||||
|
||||
if( HasHole() && shouldWeConsiderHoleCollisions( holeI, aHead ) )
|
||||
{
|
||||
collisionsFound |= holeI->collideSimple( aHead, aNode, aLayer, aCtx );
|
||||
|
@ -306,10 +306,15 @@ static bool isEdge( const PNS::ITEM* aItem )
|
||||
|
||||
bool PNS_PCBNEW_RULE_RESOLVER::IsDrilledHole( const PNS::ITEM* aItem )
|
||||
{
|
||||
if( isHole( aItem ) && aItem->Parent() )
|
||||
return aItem->Parent()->HasDrilledHole();
|
||||
if( !isHole( aItem ) )
|
||||
return false;
|
||||
|
||||
return false;
|
||||
BOARD_ITEM* parent = aItem->Parent();
|
||||
|
||||
if( !parent && aItem->ParentPadVia() )
|
||||
parent = aItem->ParentPadVia()->Parent();
|
||||
|
||||
return parent && parent->HasDrilledHole();
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user