setLayout method

  1. @override
void setLayout(
  1. BoxConstraints size
)
inherited

Update screen size information when LayoutBuilder builds.

Implementation

@override
void setLayout(BoxConstraints size) {
  final firstLayout = maxWidth == null;
  final changedSize = _updateSize(size, firstLayout);
  final changedShowFrozen = _updateShowFrozenColumn(
    size: size,
    firstLayout: firstLayout,
    changedSize: changedSize,
  );
  final bool updateVisibility =
      changedShowFrozen || firstLayout || changedSize;
  final bool notifyResizing = !firstLayout && changedSize;

  if (updateVisibility) updateVisibilityLayout();

  if (notifyResizing) notifyResizingListeners();

  if (changedShowFrozen) notifyChangedShowFrozenColumn();

  if (enableColumnsAutoSize && !activatedColumnsAutoSize) {
    activateColumnsAutoSize();
  }
}