pcb: grab unconnected needs to ignore same-footprint ratsnets items

This commit is contained in:
Mike Williams 2024-05-28 14:43:54 -04:00
parent 8165ec66e9
commit a8daa38e83
1 changed files with 6 additions and 0 deletions

View File

@ -1896,6 +1896,12 @@ int PCB_SELECTION_TOOL::grabUnconnected( const TOOL_EVENT& aEvent )
// Check every ratsnest line for the nearest one
for( const CN_EDGE& edge : edges )
{
if( edge.GetSourceNode()->Parent()->GetParentFootprint()
== edge.GetTargetNode()->Parent()->GetParentFootprint() )
{
continue; // This edge is a loop on the same footprint
}
// Figure out if we are the source or the target node on the ratnest
const CN_ANCHOR* other = edge.GetSourceNode()->Parent() == pad ? edge.GetTargetNode().get()
: edge.GetSourceNode().get();