Pcbnew: fixed unwanted mouse cursor move when using the t hotkey
This commit is contained in:
commit
c7623715e1
|
@ -582,7 +582,6 @@ void WinEDA_PcbFrame::Process_Special_Functions( wxCommandEvent& event )
|
|||
g_Drag_Pistes_On = true;
|
||||
|
||||
case ID_POPUP_PCB_MOVE_MODULE_REQUEST:
|
||||
|
||||
// If the current Item is a pad, text module ...: Get its parent
|
||||
if( GetCurItem()->Type() != TYPE_MODULE )
|
||||
SetCurItem( GetCurItem()->GetParent() );
|
||||
|
@ -591,6 +590,7 @@ void WinEDA_PcbFrame::Process_Special_Functions( wxCommandEvent& event )
|
|||
g_Drag_Pistes_On = false;
|
||||
break;
|
||||
}
|
||||
GetScreen()->m_Curseur = ((MODULE*) GetCurItem())->m_Pos;
|
||||
DrawPanel->MouseToCursorSchema();
|
||||
StartMove_Module( (MODULE*) GetCurItem(), &dc );
|
||||
break;
|
||||
|
|
|
@ -423,7 +423,7 @@ void WinEDA_PcbFrame::OnHotKey( wxDC* DC, int hotkey, EDA_BaseStruct* DrawStruct
|
|||
if( ItemFree )
|
||||
{
|
||||
wxCommandEvent evt;
|
||||
evt.SetId( ID_POPUP_PCB_GET_AND_MOVE_MODULE_REQUEST );
|
||||
evt.SetId( ID_POPUP_PCB_GET_AND_MOVE_MODULE_REQUEST );
|
||||
Process_Special_Functions( evt );
|
||||
}
|
||||
break;
|
||||
|
@ -657,6 +657,8 @@ void WinEDA_PcbFrame::OnHotKey( wxDC* DC, int hotkey, EDA_BaseStruct* DrawStruct
|
|||
|
||||
// fall through
|
||||
case HK_MOVE_FOOTPRINT: // Start move module
|
||||
GetScreen()->m_Curseur = module->m_Pos;
|
||||
DrawPanel->MouseToCursorSchema();
|
||||
StartMove_Module( module, DC );
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -100,9 +100,6 @@ void WinEDA_PcbFrame::StartMove_Module( MODULE* module, wxDC* DC )
|
|||
GetBoard()->m_Status_Pcb &= ~RATSNEST_ITEM_LOCAL_OK;
|
||||
module->m_Flags |= IS_MOVED;
|
||||
|
||||
GetScreen()->m_Curseur = module->m_Pos;
|
||||
DrawPanel->MouseToCursorSchema();
|
||||
|
||||
/* Show ratsnest. */
|
||||
if( GetBoard()->IsElementVisible(RATSNEST_VISIBLE) )
|
||||
DrawGeneralRatsnest( DC );
|
||||
|
|
Loading…
Reference in New Issue