mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-08 05:42:07 -05:00
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:
parent
988dbc52dc
commit
4926e2c8da
1 changed files with 1 additions and 1 deletions
|
@ -83,7 +83,7 @@ PathItem.inject(new function() {
|
||||||
clockwise;
|
clockwise;
|
||||||
children.sort(function(a, b){
|
children.sort(function(a, b){
|
||||||
var b1 = a.getBounds(), b2 = b.getBounds();
|
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);
|
path.addChildren(children);
|
||||||
clockwise = children[0].isClockwise();
|
clockwise = children[0].isClockwise();
|
||||||
|
|
Loading…
Reference in a new issue