pcbnew: Fix dragging snap to items
Snapping while dragging depends on the current net being assigned during
dragging. This initializes the placer to hold the current net while
performing inline dragging. The placer is reset along with the dragger
in StopRouting(). This fixes the difference in snap between drag and
create new route.
( cherry-picked from 219695953
)
This commit is contained in:
parent
2b634004ee
commit
9523b26472
|
@ -135,6 +135,9 @@ bool ROUTER::StartDragging( const VECTOR2I& aP, ITEM* aStartItem, int aDragMode
|
|||
if( !aStartItem || aStartItem->OfKind( ITEM::SOLID_T ) )
|
||||
return false;
|
||||
|
||||
m_placer.reset( new LINE_PLACER( this ) );
|
||||
m_placer->Start( aP, aStartItem );
|
||||
|
||||
m_dragger.reset( new DRAGGER( this ) );
|
||||
m_dragger->SetMode( aDragMode );
|
||||
m_dragger->SetWorld( m_world.get() );
|
||||
|
|
Loading…
Reference in New Issue