Commit b47b16f4 authored by Ian Hickson's avatar Ian Hickson Committed by GitHub

Clarify Overlay.initialEntries. (#6701)

Closes https://github.com/flutter/flutter/issues/6141
parent 8a91c8bc
......@@ -209,6 +209,18 @@ class Overlay extends StatefulWidget {
}
/// The entries to include in the overlay initially.
///
/// These entries are only used when the [OverlayState] is initialized. If you
/// are providing a new [Overlay] description for an overlay that's already in
/// the tree, then the new entries are ignored.
///
/// To add entries to an [Overlay] that is already in the tree, use
/// [Overlay.of] to obtain the [OverlayState] (or assign a [GlobalKey] to the
/// [Overlay] widget and obtain the [OverlayState] via
/// [GlobalKey.currentState]), and then use [OverlayState.add] or
/// [OverlayState.addAll].
///
/// To remove an entry from an [Overlay], use [OverlayEntry.remove].
final List<OverlayEntry> initialEntries;
/// The state from the closest instance of this class that encloses the given context.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment