3D viewer: Fix incorrect behavior when moving the scene
Fixes #12114 https://gitlab.com/kicad/code/kicad/issues/12114
This commit is contained in:
parent
0f915bf8a0
commit
4bfbf91369
|
@ -617,14 +617,17 @@ void EDA_3D_CANVAS::OnMagnify( wxMouseEvent& event )
|
|||
|
||||
void EDA_3D_CANVAS::OnMouseMove( wxMouseEvent& event )
|
||||
{
|
||||
//wxLogTrace( m_logTrace, wxT( "EDA_3D_CANVAS::OnMouseMove" ) );
|
||||
if( m_camera_is_moving )
|
||||
return;
|
||||
|
||||
OnMouseMoveCamera( event );
|
||||
|
||||
if( m_mouse_was_moved )
|
||||
{
|
||||
DisplayStatus();
|
||||
Request_refresh();
|
||||
restart_editingTimeOut_Timer();
|
||||
// *Do not* reactivate the timer here during the mouse move command:
|
||||
// OnMiddleUp() will do it at the end of mouse drag/move command
|
||||
}
|
||||
|
||||
if( !event.Dragging() && m_boardAdapter.m_Cfg->m_Render.engine == RENDER_ENGINE::OPENGL )
|
||||
|
|
|
@ -60,6 +60,7 @@ void HIDPI_GL_3D_CANVAS::OnMouseMoveCamera( wxMouseEvent& event )
|
|||
m_mouse_is_moving = true;
|
||||
m_mouse_was_moved = true;
|
||||
}
|
||||
|
||||
m_camera.SetCurMousePosition( nativePosition );
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue