@@ -160,12 +160,14 @@ two-way constraints, such as chains(not yet supported, please use with Flex).
160160 1 . fixed size(>=0)
161161 2 . matchParent(default)
162162 3 . wrapContent(minimum and maximum are temporarily not supported)
163+ 23 . layout debugging
163164
164165Follow-up development plan:
165166
1661671 . chain
1671682 . constraints visualization
168- 3 . more...
169+ 3 . provides a visual editor to create layouts by dragging and dropping
170+ 4 . more...
169171
170172Support platform:
171173
@@ -185,12 +187,12 @@ dependencies:
185187 flutter_constraintlayout :
186188 git :
187189 url : ' https://github.com/hackware1993/Flutter-ConstraintLayout.git'
188- ref : ' v1.4.4 -stable'
190+ ref : ' v1.5.0 -stable'
189191` ` `
190192
191193` ` ` yaml
192194dependencies :
193- flutter_constraintlayout : ^1.4.4 -stable
195+ flutter_constraintlayout : ^1.5.0 -stable
194196` ` `
195197
196198` ` ` dart
@@ -1335,24 +1337,24 @@ class BarrierExample extends StatelessWidget {
13351337 5 . Do you need to rearrange the order of event distribution?
13361338
13371339These comparisons will not be a performance bottleneck, but will increase CPU usage. If you know
1338- enough about the internals of ConstraintLayout, you can use ConstraintVersion to manually trigger
1339- these operations to stop parameter comparison.
1340+ enough about the internals of ConstraintLayout, you can use ConstraintLayoutController to manually
1341+ trigger these operations to stop parameter comparison.
13401342
13411343``` dart
1342- class ConstraintVersionExampleState extends State<ConstraintVersionExample > {
1344+ class ConstraintControllerExampleState extends State<ConstraintControllerExample > {
13431345 double x = 0;
13441346 double y = 0;
1345- ConstraintVersion constraintVersion = ConstraintVersion ();
1347+ ConstraintLayoutController controller = ConstraintLayoutController ();
13461348
13471349 @override
13481350 Widget build(BuildContext context) {
13491351 return Scaffold(
13501352 appBar: const CustomAppBar(
1351- title: 'Constraint Version ',
1352- codePath: 'example/constraint_version .dart',
1353+ title: 'Constraint Controller ',
1354+ codePath: 'example/constraint_controller .dart',
13531355 ),
13541356 body: ConstraintLayout(
1355- constraintVersion: constraintVersion ,
1357+ controller: controller ,
13561358 children: [
13571359 GestureDetector(
13581360 child: Container(
@@ -1364,14 +1366,14 @@ class ConstraintVersionExampleState extends State<ConstraintVersionExample> {
13641366 setState(() {
13651367 x += details.delta.dx;
13661368 y += details.delta.dy;
1367- constraintVersion.incPaintVersion ();
1369+ controller.markNeedsPaint ();
13681370 });
13691371 },
13701372 ).applyConstraint(
13711373 size: 200,
13721374 centerTo: parent,
13731375 translate: Offset(x, y),
1374- ),
1376+ )
13751377 ],
13761378 ),
13771379 );
0 commit comments