layoutWithoutSize method
Like layout but does not return the child's size, this is usually more efficient because the boxy doesn't need to be laid out when the child's size changes.
If useSize
is true, this boxy will re-layout when the child changes
size regardless.
See also:
- layout, which does the same but returns a size.
- layoutRect, which positions the child so that it fits in a rect.
- layoutFit, which positions and scales the child given a BoxFit.
Implementation
void layoutWithoutSize(BoxConstraints constraints, {bool useSize = false}) {
if (_parent.isDryLayout) {
// Do nothing since the delegate doesn't need a size.
return;
}
_checkConstraints(constraints);
render.layout(constraints);
}