From b5fbebdee9ad52de4b9b373998d91581b9fd9004 Mon Sep 17 00:00:00 2001 From: "Johan B. C. Engelen" Date: Fri, 9 May 2008 17:06:59 +0000 Subject: complete adding const to have only NArtBpath const * get_bpath() const; for accessing the protected member of SPCurve. Nowhere in Inkscape source is the path data changed of SPCurve, except within SPCurve's own methods ! So removed the non-const NArtBpath* get_bpath. (bzr r5642) --- src/object-snapper.cpp | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'src/object-snapper.cpp') diff --git a/src/object-snapper.cpp b/src/object-snapper.cpp index ffb776dfe..2584d5b49 100644 --- a/src/object-snapper.cpp +++ b/src/object-snapper.cpp @@ -321,9 +321,7 @@ void Inkscape::ObjectSnapper::_collectPaths(Inkscape::Snapper::PointType const & SPCurve *curve = curve_for_item(root_item); if (curve) { NArtBpath *bpath = bpath_for_curve(root_item, curve, true, true); - _bpaths_to_snap_to->push_back(bpath); - // Because we set doTransformation to true in bpath_for_curve, we - // will get a dupe of the path, which must be freed at some point + _bpaths_to_snap_to->push_back(bpath); // we will get a dupe of the path, which must be freed at some point curve->unref(); } } @@ -376,9 +374,7 @@ void Inkscape::ObjectSnapper::_snapPaths(SnappedConstraints &sc, SPCurve *curve = curve_for_item(SP_ITEM(selected_path)); if (curve) { NArtBpath *bpath = bpath_for_curve(SP_ITEM(selected_path), curve, true, true); - _bpaths_to_snap_to->push_back(bpath); - // Because we set doTransformation to true in bpath_for_curve, we - // will get a dupe of the path, which must be freed at some point + _bpaths_to_snap_to->push_back(bpath); // we will get a dupe of the path, which must be freed at some point curve->unref(); } } -- cgit v1.2.3