Schematic: update dragged lines dangling state in realtime

Makes the visuals a little nicer as we add bend lines
This commit is contained in:
Mike Williams 2022-12-28 08:44:24 -05:00
parent e7300ffb5c
commit b5b65e1455
1 changed files with 6 additions and 0 deletions

View File

@ -322,6 +322,12 @@ void SCH_MOVE_TOOL::orthoLineDrag( SCH_LINE* line, const VECTOR2I& splitDelta, i
splitDelta.y ? splitDelta.y : yMove ) ); splitDelta.y ? splitDelta.y : yMove ) );
} }
// Update the dangling state of our original line to not show a dangling
// end since it is now connected. This doesn't effect anything but is more
// consistent visually
std::vector<DANGLING_END_ITEM> endPoints;
b->GetEndPoints( endPoints );
line->UpdateDanglingState( endPoints );
updateItem( line, true ); updateItem( line, true );
// Update our cache of the connected items. First, attach our drag labels to the line // Update our cache of the connected items. First, attach our drag labels to the line