When the button clicked, the condition changes and TextField widget is removed from tree, but the keyboard is closed too. How to keep it open even after the TextField gone ?
bool someCondition;
initState(){
someCondition = true;
}
...
Row(
children:[
someCondition ? TextField() : Text('How to keep keyboard open'),
FlatButton(child: Text('Click me'), onPress: (){
setState(() {
someCondition = false;
});
})
],
)