AdoptAWidget: SliverWithKeepAliveWidget (#69470) (#69557)

This commit is contained in:
Chintan Patel 2020-11-02 15:23:02 +05:30 committed by GitHub
parent 57a13c3e3b
commit 734d2a22fe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -746,6 +746,15 @@ class SliverChildListDelegate extends SliverChildDelegate {
} }
/// A base class for sliver that have [KeepAlive] children. /// A base class for sliver that have [KeepAlive] children.
///
/// See also:
///
/// * [KeepAlive], which marks whether its chlild widget should be kept alive.
/// * [SliverChildBuilderDelegate] and [SliverChildListDelegate], slivers
/// which make usr of the keep alive functionality through the
/// `addAutomaticKeepAlives` property.
/// * [SliverGrid] and [SliverList], two sliver widgets that are commonly
/// wrapped with [KeepAlive] widgets to preserve their sliver child subtrees.
abstract class SliverWithKeepAliveWidget extends RenderObjectWidget { abstract class SliverWithKeepAliveWidget extends RenderObjectWidget {
/// Initializes fields for subclasses. /// Initializes fields for subclasses.
const SliverWithKeepAliveWidget({ const SliverWithKeepAliveWidget({