Fix Array#sort() call in reorientPath(path) for IE.

IE expects integer values in the compare function, not boolean. Closes #350 again.
This commit is contained in:
Jürg Lehni 2013-12-03 21:49:49 +01:00
parent 988dbc52dc
commit 4926e2c8da

View file

@ -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();