WillPopCallback onWillPop
final

Called to veto attempts by the user to dismiss the enclosing ModalRoute.

If the callback returns a Future that resolves to false, the enclosing route will not be popped.

Source

final WillPopCallback onWillPop