WillPopScope constructor

  1. @Deprecated('Use PopScope instead. The Android predictive back feature will not work with WillPopScope. ' 'This feature was deprecated after v3.12.0-1.0.pre.')
const WillPopScope({
  1. Key? key,
  2. required Widget child,
  3. required WillPopCallback? onWillPop,
})

Creates a widget that registers a callback to veto attempts by the user to dismiss the enclosing ModalRoute.

Implementation

@Deprecated(
  'Use PopScope instead. The Android predictive back feature will not work with WillPopScope. '
  'This feature was deprecated after v3.12.0-1.0.pre.',
)
const WillPopScope({
  super.key,
  required this.child,
  required this.onWillPop,
});