Commit 3fc7265a authored by Adam Barth's avatar Adam Barth Committed by GitHub

Switch from Size.isInfinite to Size.isFinite (#8868)

Fixes #4301
parent f1c2d784
......@@ -150,7 +150,7 @@ class RenderBlock extends RenderBox
break;
}
assert(!size.isInfinite);
assert(size.isFinite);
}
@override
......
......@@ -1533,7 +1533,7 @@ abstract class RenderBox extends RenderObject {
);
}
// verify that the size is not infinite
if (_size.isInfinite) {
if (!_size.isFinite) {
final StringBuffer information = new StringBuffer();
if (!constraints.hasBoundedWidth) {
RenderBox node = this;
......@@ -1658,7 +1658,7 @@ abstract class RenderBox extends RenderObject {
void performResize() {
// default behavior for subclasses that have sizedByParent = true
size = constraints.smallest;
assert(!size.isInfinite);
assert(size.isFinite);
}
@override
......
......@@ -370,7 +370,7 @@ class RenderStack extends RenderBox
size = constraints.biggest;
}
assert(!size.isInfinite);
assert(size.isFinite);
child = firstChild;
while (child != null) {
......
......@@ -108,7 +108,7 @@ class RenderView extends RenderObject with RenderObjectWithChildMixin<RenderBox>
_orientation = configuration.orientation;
}
_size = configuration.size;
assert(!_size.isInfinite);
assert(_size.isFinite);
if (child != null)
child.layout(new BoxConstraints.tight(_size));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment