Check to see if isolating junction is part of the drag or not.
Fixes https://gitlab.com/kicad/code/kicad/issues/5960
This commit is contained in:
parent
1703729269
commit
fd874d8345
|
@ -505,13 +505,13 @@ void SCH_MOVE_TOOL::getConnectedDragItems( SCH_ITEM* aOriginalItem, wxPoint aPoi
|
||||||
{
|
{
|
||||||
EE_RTREE& items = m_frame->GetScreen()->Items();
|
EE_RTREE& items = m_frame->GetScreen()->Items();
|
||||||
EE_RTREE::EE_TYPE itemsOverlapping = items.Overlapping( aOriginalItem->GetBoundingBox() );
|
EE_RTREE::EE_TYPE itemsOverlapping = items.Overlapping( aOriginalItem->GetBoundingBox() );
|
||||||
bool ptHasJunction = false;
|
bool ptHasUnselectedJunction = false;
|
||||||
|
|
||||||
for( SCH_ITEM* item : itemsOverlapping )
|
for( SCH_ITEM* item : itemsOverlapping )
|
||||||
{
|
{
|
||||||
if( item->Type() == SCH_JUNCTION_T && item->IsConnected( aPoint ) )
|
if( item->Type() == SCH_JUNCTION_T && item->IsConnected( aPoint ) && !item->IsSelected() )
|
||||||
{
|
{
|
||||||
ptHasJunction = true;
|
ptHasUnselectedJunction = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -527,9 +527,9 @@ void SCH_MOVE_TOOL::getConnectedDragItems( SCH_ITEM* aOriginalItem, wxPoint aPoi
|
||||||
{
|
{
|
||||||
case SCH_LINE_T:
|
case SCH_LINE_T:
|
||||||
{
|
{
|
||||||
// Select the connected end of wires/bus connections that don't have a junction to
|
// Select the connected end of wires/bus connections that don't have an unselected
|
||||||
// isolate them from the drag
|
// junction isolating them from the drag
|
||||||
if( ptHasJunction )
|
if( ptHasUnselectedJunction )
|
||||||
break;
|
break;
|
||||||
|
|
||||||
SCH_LINE* testLine = static_cast<SCH_LINE*>( test );
|
SCH_LINE* testLine = static_cast<SCH_LINE*>( test );
|
||||||
|
|
Loading…
Reference in New Issue