Skip to content

Switch from onBackPressed to OnBackPressedDispatcher #109558

@stuartmorgan-g

Description

@stuartmorgan-g

Internal: b/242216228

Per https://developer.android.com/guide/navigation/predictive-back-gesture onBackPressed is being deprecated, and we need to switch to OnBackPressedDispatcher and OnBackPressedCallback.

There's been some previous discussion related to this in #67011. See also #109513 for the overall predictive back.

I'm filing this separately to track the initial step of just migrating to the newer APIs, without trying to address larger feature questions discussion in those issues.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work listengineflutter/engine related. See also e: labels.platform-androidAndroid applications specificallyteam-androidOwned by Android platform teamtriaged-androidTriaged by Android platform team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions