From 59259f0cabfa0205acc3229c281169e8406570b3 Mon Sep 17 00:00:00 2001 From: Diederik van Lierop Date: Fri, 2 Sep 2011 22:14:29 +0200 Subject: Rename the struct "SnappedConstraints" to the more meaningfull "IntermSnapResults" (bzr r10612) --- src/gradient-drag.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/gradient-drag.cpp') diff --git a/src/gradient-drag.cpp b/src/gradient-drag.cpp index 585c55c28..afed09654 100644 --- a/src/gradient-drag.cpp +++ b/src/gradient-drag.cpp @@ -645,7 +645,7 @@ gr_knot_moved_handler(SPKnot *knot, Geom::Point const &ppointer, guint state, gp sp_knot_moveto (knot, p); } } else if (state & GDK_CONTROL_MASK) { - SnappedConstraints sc; + IntermSnapResults isr; Inkscape::SnapCandidatePoint scp = Inkscape::SnapCandidatePoint(p, Inkscape::SNAPSOURCE_OTHER_HANDLE); Inkscape::Preferences *prefs = Inkscape::Preferences::get(); unsigned snaps = abs(prefs->getInt("/options/rotationsnapsperpi/value", 12)); @@ -704,24 +704,24 @@ gr_knot_moved_handler(SPKnot *knot, Geom::Point const &ppointer, guint state, gp sp = m.constrainedAngularSnap(scp, boost::optional(), dr_snap, snaps); } m.unSetup(); - sc.points.push_back(sp); + isr.points.push_back(sp); } } m.setup(desktop, false); // turn of the snap indicator temporarily - Inkscape::SnappedPoint bsp = m.findBestSnap(scp, sc, true); + Inkscape::SnappedPoint bsp = m.findBestSnap(scp, isr, true); m.unSetup(); if (!bsp.getSnapped()) { // If we didn't truly snap to an object or to a grid, then we will still have to look for the // closest projection onto one of the constraints. findBestSnap() will not do this for us - for (std::list::const_iterator i = sc.points.begin(); i != sc.points.end(); i++) { - if (i == sc.points.begin() || (Geom::L2((*i).getPoint() - p) < Geom::L2(bsp.getPoint() - p))) { + for (std::list::const_iterator i = isr.points.begin(); i != isr.points.end(); i++) { + if (i == isr.points.begin() || (Geom::L2((*i).getPoint() - p) < Geom::L2(bsp.getPoint() - p))) { bsp.setPoint((*i).getPoint()); bsp.setTarget(Inkscape::SNAPTARGET_CONSTRAINED_ANGLE); } } } - //p = sc.points.front().getPoint(); + //p = isr.points.front().getPoint(); p = bsp.getPoint(); sp_knot_moveto (knot, p); } -- cgit v1.2.3