mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-06 04:42:15 -05:00
Handle bounds correctly for groups with only empty children.
This commit is contained in:
parent
0f19e72733
commit
f79e561512
1 changed files with 3 additions and 1 deletions
|
@ -874,7 +874,9 @@ var Item = this.Item = Base.extend(Callback, {
|
||||||
y2 = Math.max(rect.y + rect.height, y2);
|
y2 = Math.max(rect.y + rect.height, y2);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return Rectangle.create(x1, y1, x2 - x1, y2 - y1);
|
return isFinite(x1)
|
||||||
|
? Rectangle.create(x1, y1, x2 - x1, y2 - y1)
|
||||||
|
: new Rectangle();
|
||||||
},
|
},
|
||||||
|
|
||||||
setBounds: function(rect) {
|
setBounds: function(rect) {
|
||||||
|
|
Loading…
Reference in a new issue