Explain that predictive back doesn't work with WillPopScope (#152116)

Clearly explains that WillPopScope will break predictive back support.

Came up in https://github.com/flutter/flutter/pull/152057#pullrequestreview-2191560087.
This commit is contained in:
Justin McCandless 2024-08-01 14:33:16 -07:00 committed by GitHub
parent 67a958568e
commit 4b74c1a8a6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -19,14 +19,14 @@ import 'routes.dart';
/// * [Form], which provides an `onWillPop` callback that enables the form
/// to veto a `pop` initiated by the app's back button.
@Deprecated(
'Use PopScope instead. '
'Use PopScope instead. The Android predictive back feature will not work with WillPopScope. '
'This feature was deprecated after v3.12.0-1.0.pre.',
)
class WillPopScope extends StatefulWidget {
/// Creates a widget that registers a callback to veto attempts by the user to
/// dismiss the enclosing [ModalRoute].
@Deprecated(
'Use PopScope instead. '
'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({