Add Form.onChanged, and rename FormState.onChanged (#15405)

This commit is contained in:
Ian Hickson
2018-03-22 15:56:10 -07:00
committed by GitHub
parent aba0379dcc
commit fc87097119
3 changed files with 35 additions and 12 deletions

View File

@@ -254,7 +254,7 @@ class _ExpansionPanelsDemoState extends State<ExpansionPanelsDemo> {
new Radio<_Location>(
value: _Location.Bahamas,
groupValue: field.value,
onChanged: field.onChanged,
onChanged: field.didChange,
),
const Text('Bahamas')
]
@@ -265,7 +265,7 @@ class _ExpansionPanelsDemoState extends State<ExpansionPanelsDemo> {
new Radio<_Location>(
value: _Location.Barbados,
groupValue: field.value,
onChanged: field.onChanged,
onChanged: field.didChange,
),
const Text('Barbados')
]
@@ -276,7 +276,7 @@ class _ExpansionPanelsDemoState extends State<ExpansionPanelsDemo> {
new Radio<_Location>(
value: _Location.Bermuda,
groupValue: field.value,
onChanged: field.onChanged,
onChanged: field.didChange,
),
const Text('Bermuda')
]
@@ -320,7 +320,7 @@ class _ExpansionPanelsDemoState extends State<ExpansionPanelsDemo> {
activeColor: Colors.orange[100 + (field.value * 5.0).round()],
label: '${field.value.round()}',
value: field.value,
onChanged: field.onChanged,
onChanged: field.didChange,
);
},
),