defaultTapHandler static method
Default tap handler for PullDownMenuItem.
The behaviour is to pop the menu and than call the onTap
.
Implementation
static void defaultTapHandler(BuildContext context, VoidCallback? onTap) {
// If menu was opened from [PullDownButton] or [showPullDownMenu] then pop
// route.
if (ModalRoute.of(context) is PullDownMenuRoute) {
Navigator.pop(context, onTap);
} else {
noPopTapHandler(context, onTap);
}
}