getContentModel method

BoxModel getContentModel()

Implementation

BoxModel getContentModel() {
  // build the _body model
  if (_body == null) {
    switch (layoutType) {
      case LayoutType.column:
        _body = ColumnModel(this, null);
        break;
      case LayoutType.stack:
        _body = StackModel(this, null);
        break;
      case LayoutType.row:
      default:
        _body = RowModel(this, null);
        _body!.center = true;
        break;
    }
  }

  // add my children to content
  _body!.expand = expand;
  _body!.children = [];
  _body!.children!.addAll(children ?? []);

  return _body!;
}