Show dangling pins when moving items; don't when dragging.
Fixes: lp:1801962 * https://bugs.launchpad.net/kicad/+bug/1801962 Fixes: lp:1801959 * https://bugs.launchpad.net/kicad/+bug/1801959
This commit is contained in:
parent
5c26b1dabd
commit
cbd13c7127
|
@ -254,6 +254,8 @@ bool SCH_EDIT_FRAME::HandleBlockEnd( wxDC* aDC )
|
||||||
nextcmd = true;
|
nextcmd = true;
|
||||||
block->SetState( STATE_BLOCK_MOVE );
|
block->SetState( STATE_BLOCK_MOVE );
|
||||||
|
|
||||||
|
if( block->GetCommand() != BLOCK_DRAG && block->GetCommand() != BLOCK_DRAG_ITEM )
|
||||||
|
{
|
||||||
// Mark dangling pins at the edges of the block:
|
// Mark dangling pins at the edges of the block:
|
||||||
std::vector<DANGLING_END_ITEM> internalPoints;
|
std::vector<DANGLING_END_ITEM> internalPoints;
|
||||||
|
|
||||||
|
@ -268,6 +270,7 @@ bool SCH_EDIT_FRAME::HandleBlockEnd( wxDC* aDC )
|
||||||
auto item = static_cast<SCH_ITEM*>( block->GetItem( i ) );
|
auto item = static_cast<SCH_ITEM*>( block->GetItem( i ) );
|
||||||
item->UpdateDanglingState( internalPoints );
|
item->UpdateDanglingState( internalPoints );
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
m_canvas->SetMouseCaptureCallback( DrawMovingBlockOutlines );
|
m_canvas->SetMouseCaptureCallback( DrawMovingBlockOutlines );
|
||||||
m_canvas->CallMouseCapture( aDC, wxDefaultPosition, false );
|
m_canvas->CallMouseCapture( aDC, wxDefaultPosition, false );
|
||||||
|
|
|
@ -772,6 +772,9 @@ void SCH_EDIT_FRAME::PrepareMoveItem( SCH_ITEM* aItem )
|
||||||
SetUndoItem( aItem );
|
SetUndoItem( aItem );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::vector<DANGLING_END_ITEM> emptySet;
|
||||||
|
aItem->UpdateDanglingState( emptySet );
|
||||||
|
|
||||||
aItem->SetFlags( IS_MOVED );
|
aItem->SetFlags( IS_MOVED );
|
||||||
|
|
||||||
if( aItem->Type() == SCH_FIELD_T && aItem->GetParent()->Type() == SCH_COMPONENT_T )
|
if( aItem->Type() == SCH_FIELD_T && aItem->GetParent()->Type() == SCH_COMPONENT_T )
|
||||||
|
|
Loading…
Reference in New Issue