I am using an onChange method in a TextFormField widget... but is there a onLeave function on another parent widget.... I looked into GestureDetector but they also don't have it
TextFormField(
controller: _emailAddress_controller,
keyboardType: TextInputType.emailAddress,
validator: validateEmail,
onChanged: (value) {
print(validateEmail(_emailAddress_controller.toString()));
},
)
We don't have onLeave() but we surely do have onFieldSubmitted() for TextFormField(). It triggers some code when the user presses submit on the right-hand corner of the keyboard.
I'm assuming you want to move the focus on to a different textfield when the user leaves first textfield so you can use FocusNodes.