From ed6364b83dafb3d1b9cbedfa6675817833e9fdeb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vin=C3=ADcius=20dos=20Santos=20Oliveira?= Date: Fri, 14 Mar 2014 01:21:08 -0300 Subject: Adding default argument to PathManipulator::isBSpline. Default argument is used when function is called with missing arguments. The default was chosen to 'true', because it is the safest value in this context. From now on, the function can be called like "_pm.isBSpline()", which is more intuitive. Still, I haven't studied the code enough to determine if this cache behaviour (force the user to think if cache is correct) is appropriate. (bzr r11950.7.2) --- src/ui/tool/path-manipulator.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/ui') diff --git a/src/ui/tool/path-manipulator.h b/src/ui/tool/path-manipulator.h index 5186bfc95..594f56ff9 100644 --- a/src/ui/tool/path-manipulator.h +++ b/src/ui/tool/path-manipulator.h @@ -106,7 +106,7 @@ private: typedef boost::shared_ptr SubpathPtr; void _createControlPointsFromGeometry(); - bool isBSpline(bool recalculate); + bool isBSpline(bool recalculate = true); double BSplineHandlePosition(Handle *h); Geom::Point BSplineHandleReposition(Handle *h); Geom::Point BSplineHandleReposition(Handle *h,double pos); -- cgit v1.2.3