From 4926e2c8dabff5472327c006713753ebb97eeed9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCrg=20Lehni?= Date: Tue, 3 Dec 2013 21:49:49 +0100 Subject: [PATCH] Fix Array#sort() call in reorientPath(path) for IE. IE expects integer values in the compare function, not boolean. Closes #350 again. --- src/path/PathItem.Boolean.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/path/PathItem.Boolean.js b/src/path/PathItem.Boolean.js index a5027718..cc222cd4 100644 --- a/src/path/PathItem.Boolean.js +++ b/src/path/PathItem.Boolean.js @@ -83,7 +83,7 @@ PathItem.inject(new function() { clockwise; children.sort(function(a, b){ var b1 = a.getBounds(), b2 = b.getBounds(); - return b1._width * b1._height < b2._width * b2._height; + return b2._width * b2._height - b1._width * b1._height; }); path.addChildren(children); clockwise = children[0].isClockwise();