diff --git a/VirtualRobot/examples/RobotViewer/showRobotWindow.cpp b/VirtualRobot/examples/RobotViewer/showRobotWindow.cpp index 01fe37bc36801f29f0524a91101d20bf4c3a9fc2..b3b714c236a9766fff67f0e50f1916800261a449 100644 --- a/VirtualRobot/examples/RobotViewer/showRobotWindow.cpp +++ b/VirtualRobot/examples/RobotViewer/showRobotWindow.cpp @@ -549,7 +549,7 @@ void showRobotWindow::selectJoint(int nr) float j = currentRobotNode->getJointValue(); UI.lcdNumberJointValue->display(static_cast<double>(j)); - if (fabs(ma - mi) > 0 && (currentRobotNode->isTranslationalJoint() || currentRobotNode->isRotationalJoint())) + if (std::fabs(ma - mi) > 0 && (currentRobotNode->isJoint())) { UI.horizontalSliderPos->setEnabled(true); int pos = static_cast<int>((j - mi) / (ma - mi) * 1000.0f);