Update predictive back docs - #13640
Conversation
There was a problem hiding this comment.
Code Review
This pull request updates the documentation for Android predictive back gesture support in Flutter, including instructions for FlutterFragment, PopScope migration, and related breaking changes. A typo was found in the breaking changes document where 'WithResult' was duplicated in a section header.
|
Staged preview of the updated docs.flutter.dev site (updated for commit dc3a855): https://flutter-docs-prod--docs-pr13640-update-predictive-back-3ae2ylff.web.app |
|
Staged preview of the updated flutter.dev site (updated for commit dc3a855): https://flutter-dev-230821--www-pr13640-update-predictive-back-tmpj9jhe.web.app |
…tive-back.md Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
justinmc
left a comment
There was a problem hiding this comment.
Just one clarification below, otherwise looks good.
parlough
left a comment
There was a problem hiding this comment.
Thanks for tackling this @jesskuras!
Some suggestions and notes to consider. Feel free to take or leave them.
|
Checked with Gray and confirmed that last one looks correct. Thanks for the reviews!! |
Co-authored-by: Parker Lougheed <parlough@gmail.com>
Fixes #13604
Summary
Updates documentation across the site to reflect the current state of Android predictive back support (Android 14+ default enablement) and recent API migrations:
platform-integration/android/predictive-back.md): Updated support status, documented Android manifest setup (enableOnBackInvokedCallback="true"), and added a usage example forPopScopewithonPopInvokedWithResult(bool didPop, Object? result).release/breaking-changes/android-predictive-back.md): Updated code snippets fromonPopInvokedtoonPopInvokedWithResultand refactored the setup section to delegate to the primary predictive back guide to avoid duplication.ui/navigation/index.md): Replaced deprecatedWillPopScopereferences withPopScope.add-to-app/android/add-flutter-fragment.md): Added documentation and Kotlin/Java examples for configuringshouldAutomaticallyHandleOnBackPressed(true).Staged pages
add-to-app/android/add-flutter-fragmentplatform-integration/android/predictive-backrelease/breaking-changes/android-predictive-backui/navigation