Called when pop is invoked but the current Route corresponds to a Page found in the pages list.
result argument is the value with which the route is to complete
(e.g. the value returned from a dialog).
This callback is responsible for calling Route.didPop and returning whether this pop is successful.
The Navigator widget should be rebuilt with a pages list that does not contain the Page for the given Route. The next time the pages list is updated, if the Page corresponding to this Route is still present, it will be interpreted as a new route to display.
final PopPageCallback? onPopPage;