Fix Issue 244: Merge in Peter's fix to prevent perfectly horizontal/vertical lines from being messed up when resized
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@724 eee81c28-f429-11dd-99c0-75d572ba1ddd
This commit is contained in:
@@ -1788,16 +1788,17 @@ function BatchCommand(text) {
|
|||||||
|
|
||||||
var ts = null;
|
var ts = null;
|
||||||
var tx = 0, ty = 0;
|
var tx = 0, ty = 0;
|
||||||
var sy = (height+dy)/height, sx = (width+dx)/width;
|
var sy = height ? (height+dy)/height : 1,
|
||||||
|
sx = width ? (width+dx)/width : 1;
|
||||||
// if we are dragging on the north side, then adjust the scale factor and ty
|
// if we are dragging on the north side, then adjust the scale factor and ty
|
||||||
if(current_resize_mode.indexOf("n") != -1) {
|
if(current_resize_mode.indexOf("n") != -1) {
|
||||||
sy = (height-dy)/height;
|
sy = height ? (height-dy)/height : 1;
|
||||||
ty = height;
|
ty = height;
|
||||||
}
|
}
|
||||||
|
|
||||||
// if we dragging on the east side, then adjust the scale factor and tx
|
// if we dragging on the east side, then adjust the scale factor and tx
|
||||||
if(current_resize_mode.indexOf("w") != -1) {
|
if(current_resize_mode.indexOf("w") != -1) {
|
||||||
sx = (width-dx)/width;
|
sx = width ? (width-dx)/width : 1;
|
||||||
tx = width;
|
tx = width;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user