state method

  1. @visibleForTesting
RefreshIndicatorMode state (BuildContext context)
@visibleForTesting

Retrieve the current state of the CupertinoSliverRefreshControl. The same as the state that gets passed into the builder function. Used for testing.

Implementation

@visibleForTesting
static RefreshIndicatorMode state(BuildContext context) {
  final _CupertinoSliverRefreshControlState state
      = context.ancestorStateOfType(const TypeMatcher<_CupertinoSliverRefreshControlState>());
  return state.refreshState;
}