fixing arrows and curved lines default control points

This commit is contained in:
Pablo Luna
2011-01-24 10:55:06 -03:00
parent 82a9dc8f24
commit 314df3ca68
8 changed files with 65 additions and 64 deletions

View File

@@ -269,5 +269,5 @@ core.Utils.calculateDefaultControlPoints = function(srcPos, tarPos){
var x2 = tarPos.x + Math.sqrt(l*l/(1+(m*m)))*fix*-1;
var y2= m*(x2-tarPos.x)+tarPos.y;
return [new core.Point(x1,y1),new core.Point(x2,y2)];
return [new core.Point(-srcPos.x + x1,-srcPos.y + y1),new core.Point(-tarPos.x + x2,-tarPos.y + y2)];
};