Support expanding selection for schematic graphic lines

Fixes https://gitlab.com/kicad/code/kicad/-/issues/12032
This commit is contained in:
Jon Evans 2023-08-01 21:22:35 -04:00
parent af58281a08
commit 35c372a072
2 changed files with 9 additions and 2 deletions

View File

@ -451,6 +451,11 @@ std::set<SCH_ITEM*> SCH_SCREEN::MarkConnections( SCH_LINE* aSegment, bool aSecon
break;
}
else if( line->GetLayer() == LAYER_NOTES && item->GetLayer() == LAYER_NOTES )
{
retval.insert( line );
to_search.push( line );
}
}
}
}

View File

@ -1565,7 +1565,8 @@ int EE_SELECTION_TOOL::SelectNode( const TOOL_EVENT& aEvent )
int EE_SELECTION_TOOL::SelectConnection( const TOOL_EVENT& aEvent )
{
RequestSelection( { SCH_ITEM_LOCATE_WIRE_T, SCH_ITEM_LOCATE_BUS_T } );
RequestSelection( { SCH_ITEM_LOCATE_WIRE_T, SCH_ITEM_LOCATE_BUS_T,
SCH_ITEM_LOCATE_GRAPHIC_LINE_T } );
if( m_selection.Empty() )
return 0;
@ -1578,7 +1579,8 @@ int EE_SELECTION_TOOL::SelectConnection( const TOOL_EVENT& aEvent )
for( SCH_ITEM* item : conns )
{
if( item->IsType( { SCH_ITEM_LOCATE_WIRE_T, SCH_ITEM_LOCATE_BUS_T } )
if( item->IsType( { SCH_ITEM_LOCATE_WIRE_T, SCH_ITEM_LOCATE_BUS_T,
SCH_ITEM_LOCATE_GRAPHIC_LINE_T } )
&& !item->IsSelected() )
{
done = true;