buildFromConstraints static method
Generates LayoutInfo from the BoxConstraints of the LayoutBuilder.
Uses deviceByWeigth
to catch the right LayoutDevice by maxWidth
.
Implementation
static LayoutInfo buildFromConstraints(BoxConstraints c) {
final width = c.maxWidth;
return LayoutInfo(constraints: c, device: deviceFromWeight(width));
}