PNS: Holes need to be moved with solids
Fixes https://gitlab.com/kicad/code/kicad/-/issues/9773
This commit is contained in:
parent
08cb573e11
commit
63718323bc
|
@ -117,14 +117,15 @@ bool COMPONENT_DRAGGER::Start( const VECTOR2I& aP, ITEM_SET& aPrimitives )
|
||||||
if( item.item->Kind() != ITEM::SOLID_T )
|
if( item.item->Kind() != ITEM::SOLID_T )
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
auto solid = static_cast<SOLID*>( item.item );
|
SOLID* solid = static_cast<SOLID*>( item.item );
|
||||||
auto jt = m_world->FindJoint( solid->Pos(), solid );
|
|
||||||
|
|
||||||
m_solids.insert( solid );
|
m_solids.insert( solid );
|
||||||
|
|
||||||
if( ! item.item->IsRoutable() )
|
if( !item.item->IsRoutable() )
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
JOINT* jt = m_world->FindJoint( solid->Pos(), solid );
|
||||||
|
|
||||||
for( auto link : jt->LinkList() )
|
for( auto link : jt->LinkList() )
|
||||||
{
|
{
|
||||||
if( link.item->OfKind( ITEM::SEGMENT_T | ITEM::ARC_T ) )
|
if( link.item->OfKind( ITEM::SEGMENT_T | ITEM::ARC_T ) )
|
||||||
|
@ -174,6 +175,9 @@ bool COMPONENT_DRAGGER::Drag( const VECTOR2I& aP )
|
||||||
m_draggedItems.Add( snew.get() );
|
m_draggedItems.Add( snew.get() );
|
||||||
m_currentNode->Add( std::move( snew ) );
|
m_currentNode->Add( std::move( snew ) );
|
||||||
|
|
||||||
|
if( !s->IsRoutable() )
|
||||||
|
continue;
|
||||||
|
|
||||||
for( auto& l : m_conns )
|
for( auto& l : m_conns )
|
||||||
{
|
{
|
||||||
if( l.attachedPad == s )
|
if( l.attachedPad == s )
|
||||||
|
|
|
@ -165,6 +165,9 @@ void SOLID::SetPos( const VECTOR2I& aCenter )
|
||||||
if( m_shape )
|
if( m_shape )
|
||||||
m_shape->Move( delta );
|
m_shape->Move( delta );
|
||||||
|
|
||||||
|
if( m_hole )
|
||||||
|
m_hole->Move( delta );
|
||||||
|
|
||||||
m_pos = aCenter;
|
m_pos = aCenter;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue