From 4fbee3216b9a5067e83e3ae1d90cfc397ab2604e Mon Sep 17 00:00:00 2001 From: bubnikv Date: Mon, 19 Aug 2019 19:48:07 +0200 Subject: [PATCH] Fix of Zoom by trackpad does not update until click #2750 For an unknown reason, if the scrolling is performed on Windows with the two finger gesture on touch pad, there is no Idle event generated on some computers. The Idle is not generated on Vojtech's laptop, it is generated on Enrico's laptop. evt.Skip() solves the issue on Vojtech's laptop. --- src/slic3r/GUI/GLCanvas3D.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/slic3r/GUI/GLCanvas3D.cpp b/src/slic3r/GUI/GLCanvas3D.cpp index a5906f619b..981cb38a93 100644 --- a/src/slic3r/GUI/GLCanvas3D.cpp +++ b/src/slic3r/GUI/GLCanvas3D.cpp @@ -2474,6 +2474,13 @@ void GLCanvas3D::on_mouse_wheel(wxMouseEvent& evt) evt.SetY(evt.GetY() * scale); #endif +#ifdef __WXMSW__ + // For some reason the Idle event is not being generated after the mouse scroll event in case of scrolling with the two fingers on the touch pad, + // if the event is not allowed to be passed further. + // https://github.com/prusa3d/PrusaSlicer/issues/2750 + evt.Skip(); +#endif /* __WXMSW__ */ + // Performs layers editing updates, if enabled if (is_layers_editing_enabled()) {