pcbnew: Allow DRC violations when marked

We shouldn't consider any obstacles when we are routing in DRC violation
mode.

Fixes: lp:1826723
* https://bugs.launchpad.net/kicad/+bug/1826723
This commit is contained in:
Seth Hillbrand 2019-06-09 12:59:37 -07:00
parent 98e68cd66a
commit 3b3165ad51
1 changed files with 16 additions and 12 deletions

View File

@ -436,6 +436,9 @@ bool LINE_PLACER::rhMarkObstacles( const VECTOR2I& aP, LINE& aNewHead )
m_currentNode->QueryColliding( &newHead, obstacles ); m_currentNode->QueryColliding( &newHead, obstacles );
// If we are allowing DRC violations, we don't push back to the hull
if( !Settings().CanViolateDRC() )
{
for( auto& obs : obstacles ) for( auto& obs : obstacles )
{ {
int cl = m_currentNode->GetClearance( obs.m_item, &newHead ); int cl = m_currentNode->GetClearance( obs.m_item, &newHead );
@ -454,6 +457,7 @@ bool LINE_PLACER::rhMarkObstacles( const VECTOR2I& aP, LINE& aNewHead )
} }
} }
} }
}
if( hasBest ) if( hasBest )
m_head = bestHead; m_head = bestHead;