@@ -73,6 +73,7 @@ class ConstraintLayout extends MultiChildRenderObjectWidget {
7373 }
7474}
7575
76+ /// Not completed
7677List <Widget > horizontalChain ({
7778 required _Align left,
7879 required _Align right,
@@ -120,6 +121,7 @@ List<Widget> horizontalChain({
120121 return widgetList;
121122}
122123
124+ /// Not completed
123125List <Widget > verticalChain ({
124126 _Align ? top,
125127 _Align ? bottom,
@@ -391,6 +393,7 @@ class Constraint {
391393 final EdgeInsets goneMargin;
392394
393395 /// These are the base constraints constraint on sibling id or parent
396+ /// The essence of constraints is alignment
394397 @_baseConstraint
395398 _Align ? left;
396399 @_baseConstraint
@@ -728,7 +731,7 @@ class Constraint {
728731
729732 /// Convert wrapper constraints finish
730733
731- /// Constraint priority: match_parent > wrapper constraints > base constraints
734+ /// Constraint priority: matchParent > wrapper constraints > base constraints
732735 if (width == matchParent) {
733736 assert (() {
734737 if (left != null || right != null ) {
@@ -1681,6 +1684,9 @@ class _ConstraintRenderBox extends RenderBox
16811684 } else {
16821685 element.laidOut = true ;
16831686 }
1687+
1688+ /// Due to the design of the Flutter framework, even if a child element is gone, it still has to be laid out
1689+ /// I don't understand why the official design is this way
16841690 element.renderBox! .layout (
16851691 BoxConstraints (
16861692 minWidth: minWidth,
@@ -2477,9 +2483,9 @@ class _InternalBox extends RenderBox {
24772483 constraintBoxData._referencedIds = null ;
24782484 constraintBoxData.percentageTranslate = false ;
24792485 constraintBoxData.minWidth = 0 ;
2480- constraintBoxData.maxWidth = double .infinity ;
2486+ constraintBoxData.maxWidth = matchParent ;
24812487 constraintBoxData.minHeight = 0 ;
2482- constraintBoxData.maxHeight = double .infinity ;
2488+ constraintBoxData.maxHeight = matchParent ;
24832489 }
24842490}
24852491
0 commit comments