From 3a2c408c8fcb5cd39e8903ed5b17201bd6094db9 Mon Sep 17 00:00:00 2001 From: Uwe Date: Sat, 13 Aug 2022 15:02:26 +0200 Subject: [PATCH] [Gui] fix NaviCube step handling - as reported in https://forum.freecadweb.org/viewtopic.php?f=3&t=71050 --- src/Gui/NaviCube.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/Gui/NaviCube.cpp b/src/Gui/NaviCube.cpp index 2166d57343..e84ea98552 100644 --- a/src/Gui/NaviCube.cpp +++ b/src/Gui/NaviCube.cpp @@ -1267,10 +1267,9 @@ bool NaviCubeImplementation::mouseReleased(short x, short y) { float tilt = 90 - Base::toDegrees(atan(sqrt(2.0))); int pick = pickFace(x, y); - ParameterGrp::handle hGrp = App::GetApplication().GetParameterGroupByPath("User parameter:BaseApp/Preferences/View"); - long step = Base::clamp(hGrp->GetInt("NaviStepByTurn", 8), 4L, 36L); - float rotStepAngle = 360.0f / step; ParameterGrp::handle hGrpNavi = App::GetApplication().GetParameterGroupByPath("User parameter:BaseApp/Preferences/NaviCube"); + long step = Base::clamp(hGrpNavi->GetInt("NaviStepByTurn", 8), 4L, 36L); + float rotStepAngle = 360.0f / step; bool toNearest = hGrpNavi->GetBool("NaviRotateToNearest", true); bool applyRotation = true;