From 86dee4db2f6a4b2f3123c6f5b062758eb3fecd2e Mon Sep 17 00:00:00 2001 From: Saivan Date: Sun, 4 Mar 2018 01:56:12 +1100 Subject: Fixed most of the tests relating to transformations --- playgrounds/matrix/drag.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'playgrounds') diff --git a/playgrounds/matrix/drag.js b/playgrounds/matrix/drag.js index 636ae30..143699d 100644 --- a/playgrounds/matrix/drag.js +++ b/playgrounds/matrix/drag.js @@ -55,7 +55,6 @@ SVG.extend(SVG.Element, { reactToDrag(this, (e, x, y)=> { - let matrix = this.transform this.transform({ origin: [sx, sy], position: [x, y], @@ -67,7 +66,7 @@ SVG.extend(SVG.Element, { }, (e, x, y)=> { - var toAbsolute = this.transform().inverse() + var toAbsolute = new SVG.Matrix(this).inverse() var p = new SVG.Point(x, y).transform(toAbsolute) sx = p.x sy = p.y -- cgit v1.2.3