getSearchAction method
Returns an IconButton suitable for an Action
Put this inside your buildDefaultAppBar method!
Implementation
IconButton getSearchAction(BuildContext context) {
return IconButton(
icon: Icon(Icons.search),
onPressed: () {
beginSearch(context);
});
}