Restore state on iOS
When a user runs a mobile app and then selects another app to run, the first app is moved to the background, or backgrounded. The operating system (both iOS and Android) often kill the backgrounded app to release memory or improve performance for the app running in the foreground.
You can use the RestorationManager
(and related)
classes to handle state restoration.
An iOS app requires a bit of extra setup in Xcode,
but the restoration classes otherwise work the same on
both iOS and Android.
除非另有说明,本文档之所提及适用于 Flutter 的最新稳定版本,本页面最后更新时间: 2024-04-04。 查看文档源码 或者 为本页面内容提出建议。