Final fix for Issue 103: merge in modified patch from antimatter15

git-svn-id: http://svg-edit.googlecode.com/svn/trunk@481 eee81c28-f429-11dd-99c0-75d572ba1ddd
master
Jeff Schiller 2009-08-27 01:03:08 +00:00
parent 9467ce13ba
commit 143680e3ee
1 changed files with 2 additions and 8 deletions

View File

@ -1683,14 +1683,8 @@ function SvgCanvas(c)
} }
break; break;
case "rotate": case "rotate":
// TODO: figure out cx,cy of rotated handle in absolute coords var box = canvas.getBBox(selected),cx = box.x + box.width/2, cy = box.y + box.height/2;
// TODO: determine new angle that will minimize the distance from x,y to cx,cy canvas.setRotationAngle(((Math.atan2(cy-y,cx-x) * (180/Math.PI))-90) % 360);
// TODO: rotate the shape by that angle, setRotationAngle()
var angle = canvas.getRotationAngle(current_poly) * Math.PI / 180.0;
if (angle) {
}
break; break;
default: default:
break; break;