Commit d4f3d0a0 authored by Hixie's avatar Hixie

Add more asserts to help catch the blackness bug

parent 519b190c
...@@ -16,13 +16,14 @@ class HomogeneousViewport extends RenderObjectWidget { ...@@ -16,13 +16,14 @@ class HomogeneousViewport extends RenderObjectWidget {
Key key, Key key,
this.builder, this.builder,
this.itemsWrap: false, this.itemsWrap: false,
this.itemExtent, // required this.itemExtent, // required, must be non-zero
this.itemCount, // optional, but you cannot shrink-wrap this class or otherwise use its intrinsic dimensions if you don't specify it this.itemCount, // optional, but you cannot shrink-wrap this class or otherwise use its intrinsic dimensions if you don't specify it
this.direction: ScrollDirection.vertical, this.direction: ScrollDirection.vertical,
this.startOffset: 0.0, this.startOffset: 0.0,
this.overlayPainter this.overlayPainter
}) : super(key: key) { }) : super(key: key) {
assert(itemExtent != null); assert(itemExtent != null);
assert(itemExtent > 0);
} }
final ListBuilder builder; final ListBuilder builder;
......
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