diff --git a/pcbnew/tools/pcbnew_control.cpp b/pcbnew/tools/pcbnew_control.cpp index 3b214e3969..3140a30352 100644 --- a/pcbnew/tools/pcbnew_control.cpp +++ b/pcbnew/tools/pcbnew_control.cpp @@ -767,10 +767,16 @@ int PCBNEW_CONTROL::placeBoardItems( std::vector& aItems, bool aIsN editTool->GetCurrentCommit()->Added( item ); } - selection.SetReferencePoint( VECTOR2I( 0, 0 ) ); + if( selection.Size() > 0 ) + { + BOARD_ITEM* item = (BOARD_ITEM*) selection.GetTopLeftItem(); - m_toolMgr->ProcessEvent( EVENTS::SelectedEvent ); - m_toolMgr->RunAction( PCB_ACTIONS::move, true ); + selection.SetReferencePoint( item->GetPosition() ); + getViewControls()->SetCursorPosition( getViewControls()->GetMousePosition(), false ); + + m_toolMgr->ProcessEvent( EVENTS::SelectedEvent ); + m_toolMgr->RunAction( PCB_ACTIONS::move, true ); + } return 0; }