Add a bus instead of a wire for bus junctions.
Fixes https://gitlab.com/kicad/code/kicad/issues/7231
This commit is contained in:
parent
7a8a099259
commit
d770284fa2
|
@ -602,7 +602,13 @@ void SCH_MOVE_TOOL::getConnectedDragItems( SCH_ITEM* aOriginalItem, wxPoint aPoi
|
||||||
{
|
{
|
||||||
// Add a new wire between the component or junction and the selected item so
|
// Add a new wire between the component or junction and the selected item so
|
||||||
// the selected item can be dragged.
|
// the selected item can be dragged.
|
||||||
SCH_LINE* newWire = new SCH_LINE( aPoint, LAYER_WIRE );
|
SCH_LINE* newWire = nullptr;
|
||||||
|
|
||||||
|
if( test->GetLayer() == LAYER_BUS_JUNCTION )
|
||||||
|
newWire = new SCH_LINE( aPoint, LAYER_BUS );
|
||||||
|
else
|
||||||
|
newWire = new SCH_LINE( aPoint, LAYER_WIRE );
|
||||||
|
|
||||||
newWire->SetFlags( IS_NEW );
|
newWire->SetFlags( IS_NEW );
|
||||||
m_frame->AddToScreen( newWire, m_frame->GetScreen() );
|
m_frame->AddToScreen( newWire, m_frame->GetScreen() );
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue