From: Diederik van Lierop Date: Sat, 25 Sep 2010 09:04:23 +0000 (+0200) Subject: fix snapmanager initialization X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=0b1df92e83265415734ce26c13fc2b2ea84fcb59;p=inkscape.git fix snapmanager initialization --- diff --git a/src/ui/tool/node.cpp b/src/ui/tool/node.cpp index 1070e4bc3..575a2f59e 100644 --- a/src/ui/tool/node.cpp +++ b/src/ui/tool/node.cpp @@ -944,7 +944,12 @@ void Node::dragged(Geom::Point &new_pos, GdkEventMotion *event) { // For a note on how snapping is implemented in Inkscape, see snap.h. SnapManager &sm = _desktop->namedview->snap_manager; + // even if we won't really snap, we might still call the one of the + // constrainedSnap() methods to enforce the constraints, so we need + // to setup the snapmanager anyway; this is also required for someSnapperMightSnap() + sm.setup(_desktop); bool snap = sm.someSnapperMightSnap(); + Inkscape::SnappedPoint sp; std::vector unselected; if (snap) { @@ -966,11 +971,6 @@ void Node::dragged(Geom::Point &new_pos, GdkEventMotion *event) } } sm.setupIgnoreSelection(_desktop, true, &unselected); - } else { - // even if we won't really snap, we might still call the one of the - // constrainedSnap() methods to enforce the constraints, so we need - // to setup the snapmanager anyway - sm.setup(_desktop); } if (held_control(*event)) {