mirror of
https://gitlab.com/kicad/code/kicad.git
synced 2025-09-14 18:23:15 +02:00
3D viewer: Ensure the 3D display view is not modified after left clicking.
After opening a context menu and left clicking on the 3D canvas, the view was modified because a drag event was generated, probably a wxWidgets bug. Fixes https://gitlab.com/kicad/code/kicad/-/issues/17422
This commit is contained in:
parent
e24d43178a
commit
05e34714fc
@ -830,6 +830,11 @@ void EDA_3D_CANVAS::OnLeftDown( wxMouseEvent& event )
|
||||
SetFocus();
|
||||
stop_editingTimeOut_Timer();
|
||||
|
||||
// Ensure m_camera.m_lastPosition (current mouse position) is up to date for
|
||||
// future drag events (can be not the case when left clicking after
|
||||
// opening a context menu)
|
||||
OnMouseMoveCamera( event );
|
||||
|
||||
if( !event.Dragging() && ( m_3d_render_raytracing != nullptr ) )
|
||||
{
|
||||
RAY mouseRay = getRayAtCurrentMousePosition();
|
||||
|
Loading…
x
Reference in New Issue
Block a user