Set move flags at beginning of move.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16891
This commit is contained in:
Jeff Young 2024-02-09 10:19:26 +00:00
parent 4905c37712
commit 3c45145401
1 changed files with 5 additions and 3 deletions

View File

@ -606,11 +606,13 @@ bool SCH_MOVE_TOOL::doMoveSelection( const TOOL_EVENT& aEvent, SCH_COMMIT* aComm
}
else
{
aCommit->Modify( (SCH_ITEM*) item, m_frame->GetScreen() );
aCommit->Modify( item, m_frame->GetScreen() );
}
SCH_ITEM* schItem = (SCH_ITEM*) item;
schItem->SetStoredPos( schItem->GetPosition() );
item->SetFlags( IS_MOVING );
if( SCH_ITEM* schItem = dynamic_cast<SCH_ITEM*>( item ) )
schItem->SetStoredPos( schItem->GetPosition() );
}
// Set up the starting position and move/drag offset