Make expand connection work on generated tracks
This commit is contained in:
parent
69a69cc624
commit
037f349585
|
@ -1241,9 +1241,9 @@ int PCB_SELECTION_TOOL::expandConnection( const TOOL_EVENT& aEvent )
|
||||||
|
|
||||||
for( const EDA_ITEM* item : m_selection.GetItems() )
|
for( const EDA_ITEM* item : m_selection.GetItems() )
|
||||||
{
|
{
|
||||||
if( item->Type() == PCB_FOOTPRINT_T ||
|
if( item->Type() == PCB_FOOTPRINT_T
|
||||||
( BOARD_CONNECTED_ITEM::ClassOf( item )
|
|| item->Type() == PCB_GENERATOR_T
|
||||||
&& static_cast<const BOARD_CONNECTED_ITEM*>( item )->IsConnected() ) )
|
|| ( static_cast<const BOARD_ITEM*>( item )->IsConnected() ) )
|
||||||
{
|
{
|
||||||
initialCount++;
|
initialCount++;
|
||||||
}
|
}
|
||||||
|
@ -1287,6 +1287,14 @@ int PCB_SELECTION_TOOL::expandConnection( const TOOL_EVENT& aEvent )
|
||||||
for( PAD* pad : footprint->Pads() )
|
for( PAD* pad : footprint->Pads() )
|
||||||
startItems.push_back( pad );
|
startItems.push_back( pad );
|
||||||
}
|
}
|
||||||
|
else if( item->Type() == PCB_GENERATOR_T )
|
||||||
|
{
|
||||||
|
for( BOARD_ITEM* generatedItem : static_cast<PCB_GENERATOR*>( item )->GetItems() )
|
||||||
|
{
|
||||||
|
if( BOARD_CONNECTED_ITEM::ClassOf( generatedItem ) )
|
||||||
|
startItems.push_back( static_cast<BOARD_CONNECTED_ITEM*>( generatedItem ) );
|
||||||
|
}
|
||||||
|
}
|
||||||
else if( BOARD_CONNECTED_ITEM::ClassOf( item ) )
|
else if( BOARD_CONNECTED_ITEM::ClassOf( item ) )
|
||||||
{
|
{
|
||||||
startItems.push_back( static_cast<BOARD_CONNECTED_ITEM*>( item ) );
|
startItems.push_back( static_cast<BOARD_CONNECTED_ITEM*>( item ) );
|
||||||
|
|
Loading…
Reference in New Issue