Skip to content

Commit 0b64cc0

Browse files
committed
fix:
2 parents 741f952 + 645deb3 commit 0b64cc0

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

lib/common/widget_demo.dart

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ class _WidgetDemoState extends State<WidgetDemo> {
3636
Color _collectionColor;
3737
List widgetDemosList = new WidgetDemoList().getDemos();
3838
String _router = '';
39+
String _collText = '';
3940

4041
void showInSnackBar(String value) {
4142
Fluttertoast.showToast(
@@ -147,10 +148,10 @@ class _WidgetDemoState extends State<WidgetDemo> {
147148
Widget build(BuildContext context) {
148149
if (_hasCollected) {
149150
_collectionColor = Colors.red;
150-
_router='取消收藏';
151+
_collText='取消收藏';
151152
} else {
152153
_collectionColor =null;
153-
_router='组件收藏';
154+
_collText='组件收藏';
154155
}
155156
return Scaffold(
156157
appBar: AppBar(
@@ -186,7 +187,7 @@ class _WidgetDemoState extends State<WidgetDemo> {
186187
value: 'collection',
187188
child: ListTile(
188189
leading: Icon(Icons.star,size: 22.0,color: _collectionColor,),
189-
title: Text(_router),
190+
title: Text(_collText),
190191

191192
),
192193
),

0 commit comments

Comments
 (0)