MaterialSwipeRefresh class
Refresh indicator widget with Material Design style. stateStream - indicator state(SwipeRefreshState.loading or SwipeRefreshState.hidden). onRefresh - function that's called when the user has dragged the refresh indicator far enough to demonstrate that they want the app to refresh. indicatorColor - progress indicator's foreground color (default - ColorScheme.primary). children - list of any widgets. childrenDelegate - pass the inheritor to SliverChildDelegate to avoid creating more children than are visible through the Viewport. initState - initialization state(SwipeRefreshState.loading or SwipeRefreshState.hidden). backgroundColor - progress indicator's background color (default - Color(0xFFFFFFFF)). scrollController - ScrollController for ListView. padding - corresponds to having a SliverPadding in the CustomScrollView.slivers property instead of the list itself, and having the SliverList instead be a child of the SliverPadding. shrinkWrap - Whether the extent of the scroll view should be determined by the contents being viewed(default - false). keyboardDismissBehavior - ScrollViewKeyboardDismissBehavior the defines how this ScrollView will dismiss the keyboard automatically. (if == null it will be ScrollViewKeyboardDismissBehavior.manual). physics - defines the physics of the scroll(if == null it will be AlwaysScrollableScrollPhysics).
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- MaterialSwipeRefresh
Constructors
-
MaterialSwipeRefresh({required Stream<
SwipeRefreshState> stateStream, required VoidCallback onRefresh, Color? indicatorColor, List<Widget> ? children, SliverChildDelegate? childrenDelegate, SwipeRefreshState? initState, Color? backgroundColor, EdgeInsets? padding, ScrollController? scrollController, bool shrinkWrap = false, ScrollViewKeyboardDismissBehavior? keyboardDismissBehavior, ScrollPhysics? physics, Key? key, double? cacheExtent}) -
const
Properties
- backgroundColor → Color
-
final
- cacheExtent → double?
-
final
-
children
→ List<
Widget> ? -
finalinherited
- childrenDelegate → SliverChildDelegate?
-
finalinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- indicatorColor → Color?
-
final
- initState → SwipeRefreshState?
-
finalinherited
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- keyboardDismissBehavior → ScrollViewKeyboardDismissBehavior?
-
finalinherited
- onRefresh → VoidCallback
-
finalinherited
- padding → EdgeInsets?
-
finalinherited
- physics → ScrollPhysics?
-
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- scrollController → ScrollController?
-
finalinherited
- shrinkWrap → bool
-
finalinherited
-
stateStream
→ Stream<
SwipeRefreshState> -
finalinherited
Methods
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → SwipeRefreshBaseState< SwipeRefreshBase> - Creates the mutable state for this widget at a given location in the tree.
-
debugDescribeChildren(
) → List< DiagnosticsNode> -
Returns a list of
DiagnosticsNode
objects describing this node's children.inherited -
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toDiagnosticsNode(
{String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode -
Returns a debug representation of the object that is used by debugging
tools and by DiagnosticsNode.toStringDeep.
inherited
-
toString(
{DiagnosticLevel minLevel = DiagnosticLevel.info}) → String -
A string representation of this object.
inherited
-
toStringDeep(
{String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a string representation of this node and its descendants.
inherited
-
toStringShallow(
{String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a one-line detailed description of the object.
inherited
-
toStringShort(
) → String -
A short, textual description of this widget.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited