summaryrefslogtreecommitdiffstats
path: root/src/nodepath.cpp
diff options
context:
space:
mode:
authorbulia byak <buliabyak@gmail.com>2006-05-21 15:57:28 +0000
committerbuliabyak <buliabyak@users.sourceforge.net>2006-05-21 15:57:28 +0000
commitde90b509651da2ba423f69ec876442d3bd8d4ba8 (patch)
tree7631b44ad54991d450b98ec3ad80b708671e5a74 /src/nodepath.cpp
parentguard callback, catch release event, set _rgba: fixes #1491876, #1492332 (diff)
downloadinkscape-de90b509651da2ba423f69ec876442d3bd8d4ba8.tar.gz
inkscape-de90b509651da2ba423f69ec876442d3bd8d4ba8.zip
fix unstable behavior when ctrl+alt+dragging more than one sharp node
(bzr r916)
Diffstat (limited to 'src/nodepath.cpp')
-rw-r--r--src/nodepath.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/nodepath.cpp b/src/nodepath.cpp
index 90fcb26f7..96820d85b 100644
--- a/src/nodepath.cpp
+++ b/src/nodepath.cpp
@@ -2933,8 +2933,8 @@ node_request(SPKnot *knot, NR::Point *p, guint state, gpointer data)
if ((n->n.other && n->n.other->code == NR_LINETO) || fabs(yn) + fabs(xn) < 1e-6) {
if (n->n.other) { // if there is the next point
if (L2(n->n.other->p.pos - n->n.other->pos) < 1e-6) // and the next point has no handle either
- yn = n->n.other->pos[NR::Y] - n->origin[NR::Y]; // use origin because otherwise the direction will change as you drag
- xn = n->n.other->pos[NR::X] - n->origin[NR::X];
+ yn = n->n.other->origin[NR::Y] - n->origin[NR::Y]; // use origin because otherwise the direction will change as you drag
+ xn = n->n.other->origin[NR::X] - n->origin[NR::X];
}
}
if (xn < 0) { xn = -xn; yn = -yn; } // limit the angle to between 0 and pi
@@ -2947,8 +2947,8 @@ node_request(SPKnot *knot, NR::Point *p, guint state, gpointer data)
if (n->code == NR_LINETO || fabs(yp) + fabs(xp) < 1e-6) {
if (n->p.other) {
if (L2(n->p.other->n.pos - n->p.other->pos) < 1e-6)
- yp = n->p.other->pos[NR::Y] - n->origin[NR::Y];
- xp = n->p.other->pos[NR::X] - n->origin[NR::X];
+ yp = n->p.other->origin[NR::Y] - n->origin[NR::Y];
+ xp = n->p.other->origin[NR::X] - n->origin[NR::X];
}
}
if (xp < 0) { xp = -xp; yp = -yp; } // limit the angle to between 0 and pi