Skip to content

Commit

Permalink
Fixed issue #43. Chrome removed getTransformToElement. See dagrejs/da…
Browse files Browse the repository at this point in the history
  • Loading branch information
0x17de committed Apr 13, 2016
1 parent 3d68f70 commit 433c0d9
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions registration-system/view/signups/game1/js/svgUtils.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
// Chrome removed getTranfformToElement https://github.com/cpettitt/dagre-d3/issues/202
SVGElement.prototype.getTransformToElement = SVGElement.prototype.getTransformToElement || function(toElement) {
return toElement.getScreenCTM().inverse().multiply(this.getScreenCTM());
};


function translate(x, y) {
return "translate("+x+", "+y+")";
}
Expand Down

0 comments on commit 433c0d9

Please sign in to comment.