onPressed method

void onPressed(
  1. BuildContext context
)

Implementation

void onPressed(BuildContext context) {
  //execute the onTap function (if provided)
  onTap?.call();

  //remove the Done button Overlay
  KeyboardOverlay.removeOverlay();

  //pop out of the keyboard Focus
  FocusScope.of(context).requestFocus(FocusNode());
}