Group members are still children of the board (not
the group).
(cherry picked from commit 4b38932129)
This commit is contained in:
+3
-6
@@ -538,18 +538,15 @@ void BOARD::RunOnDescendants( const std::function<void ( BOARD_ITEM* )>& aFuncti
|
||||
for( PCB_MARKER* marker : m_markers )
|
||||
aFunction( marker );
|
||||
|
||||
for( PCB_GROUP* group : m_groups )
|
||||
aFunction( group );
|
||||
|
||||
for( FOOTPRINT* footprint : m_footprints )
|
||||
{
|
||||
aFunction( footprint );
|
||||
footprint->RunOnDescendants( aFunction, aDepth + 1 );
|
||||
}
|
||||
|
||||
for( PCB_GROUP* group : m_groups )
|
||||
{
|
||||
aFunction( group );
|
||||
group->RunOnDescendants( aFunction, aDepth + 1 );
|
||||
}
|
||||
|
||||
for( BOARD_ITEM* drawing : m_drawings )
|
||||
{
|
||||
aFunction( drawing );
|
||||
|
||||
@@ -2232,10 +2232,7 @@ void FOOTPRINT::RunOnDescendants( const std::function<void( BOARD_ITEM* )>& aFun
|
||||
aFunction( zone );
|
||||
|
||||
for( PCB_GROUP* group : m_groups )
|
||||
{
|
||||
aFunction( group );
|
||||
group->RunOnDescendants( aFunction, aDepth + 1 );
|
||||
}
|
||||
|
||||
for( BOARD_ITEM* drawing : m_drawings )
|
||||
{
|
||||
@@ -2735,7 +2732,7 @@ BOARD_ITEM* FOOTPRINT::DuplicateItem( const BOARD_ITEM* aItem, bool aAddToFootpr
|
||||
Add( aCurrItem );
|
||||
} );
|
||||
|
||||
Add( new_item );
|
||||
Add( group );
|
||||
}
|
||||
|
||||
new_item = group;
|
||||
|
||||
Reference in New Issue
Block a user