mirror of
https://gitlab.com/kicad/code/kicad.git
synced 2025-09-14 18:23:15 +02:00
PCB: fix stale ratsnest between moves in Move Individually
This commit is contained in:
parent
03f79f512c
commit
17bb57cc73
@ -2545,6 +2545,14 @@ int EDIT_TOOL::cutToClipboard( const TOOL_EVENT& aEvent )
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void EDIT_TOOL::rebuildConnectivity()
|
||||||
|
{
|
||||||
|
board()->BuildConnectivity();
|
||||||
|
m_toolMgr->PostEvent( EVENTS::ConnectivityChangedEvent );
|
||||||
|
canvas()->RedrawRatsnest();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void EDIT_TOOL::setTransitions()
|
void EDIT_TOOL::setTransitions()
|
||||||
{
|
{
|
||||||
Go( &EDIT_TOOL::GetAndPlace, PCB_ACTIONS::getAndPlace.MakeEvent() );
|
Go( &EDIT_TOOL::GetAndPlace, PCB_ACTIONS::getAndPlace.MakeEvent() );
|
||||||
|
@ -200,6 +200,9 @@ private:
|
|||||||
bool pickReferencePoint( const wxString& aTooltip, const wxString& aSuccessMessage,
|
bool pickReferencePoint( const wxString& aTooltip, const wxString& aSuccessMessage,
|
||||||
const wxString& aCanceledMessage, VECTOR2I& aReferencePoint );
|
const wxString& aCanceledMessage, VECTOR2I& aReferencePoint );
|
||||||
|
|
||||||
|
///< Rebuilds the ratsnest for operations that require it outside the commit rebuild
|
||||||
|
void rebuildConnectivity();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
PCB_SELECTION_TOOL* m_selectionTool;
|
PCB_SELECTION_TOOL* m_selectionTool;
|
||||||
std::unique_ptr<BOARD_COMMIT> m_commit;
|
std::unique_ptr<BOARD_COMMIT> m_commit;
|
||||||
|
@ -742,6 +742,8 @@ int EDIT_TOOL::doMoveSelection( const TOOL_EVENT& aEvent )
|
|||||||
if( isSkip )
|
if( isSkip )
|
||||||
orig_items[itemIdx]->SetPosition( originalPos );
|
orig_items[itemIdx]->SetPosition( originalPos );
|
||||||
|
|
||||||
|
rebuildConnectivity();
|
||||||
|
|
||||||
if( ++itemIdx < orig_items.size() )
|
if( ++itemIdx < orig_items.size() )
|
||||||
{
|
{
|
||||||
m_selectionTool->ClearSelection();
|
m_selectionTool->ClearSelection();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user