nop_flutter library

Classes

AutoListenDelegate<T, P extends ValueListenable<T>>
AutoListenNotifier<T>
AutoListenWrapper<T, P extends ValueNotifier<T>>
ChangeNotifierBase
ChangeNotifierSelector<T, D extends Listenable>
ChangeScoop
CurvedAnimationWidget
CurvedAnimation需要调用dispose释放资源
Nop<C>
当前共享对象的存储位置 page: 指定一个 虚拟 page,并不是所谓的页面,是一片区域; 在一个页面中可以有多个区域,每个区域单独管理,由shared指定是否共享; 在全局中有一个依赖链表,里面的对象都是共享的; 在查找过程中,会在当前 page 依赖添加一个引用,即使是从其他 page 依赖获取的; 如果没有 page,那么创建的对象只在特定的上下文共享
NopDependencies
NopListener
NopListenerDefault
NopPreInit
统一初始化对象
NopRoute
NopRouteAction<T>
路由跳转行为
NopRouteBuilder
OverlayDelegate
OverlayDisposeEntry
OverlayMixinDelegate<T extends OverlayMixin>
OverlayObserver
OverlayObserverState
OverlayPannelBuilder
OverlaySideGesture
Widget
OverlayVerticalPannels
OverlayWidget
UserGestureController<T>

Enums

NopOverlayPosition
NopShareScope
指定共享范围 低级的共享域可以通过 NopListener.attachToParents 让高级的共享域访问 低级共享域可以任意使用高级共享域

Properties

final

Functions

showOverlay(Widget content, {Duration duration = const Duration(seconds: 3), Duration animationDuration = const Duration(milliseconds: 300), Duration delayDuration = Duration.zero, bool? closeOndismissed, Color? color, BorderRadius? radius, bool removeAll = true, double? left = 0, double? right = 0, double? top = 0, double? bottom = 0, EdgeInsets? margin, NopOverlayPosition position = NopOverlayPosition.none, Object? showKey, bool autoShow = true, void onTap(OverlayMixin owner)?, Widget builder(BuildContext context, Widget child)?, Widget transition(Widget child, UserGestureController<OverlayPannelBuilder> controller)?}) OverlayMixinDelegate<OverlayMixin>
waitForFrame() Future<void>
waitState<T extends State<StatefulWidget>>(FutureOr<void> run(T), StateGetter<T> stateGetter, VoidCallback onFailed) FutureOr<void>
在同一个代码块中读取值 确保初始化时,state.mounted == true

Typedefs

BannerDelegate = OverlayMixinDelegate<OverlayMixin>
BuildFactory<T> = T Function()
Cs = ChangeScoop
NopPreInitCallback = void Function(T? preInit<T>({bool shared}))
NopWidgetBuilder = Widget Function(BuildContext context, Widget child)
PopAndPush = Future<T?> Function<T, R>(String name, {Object? arguments, R? result})
PopAndPushNative = Future<T?> Function<T, R>(BuildContext context, String name, {Object? arguments, R? result})
PushAndRemoveUntil = Future<T?> Function<T extends Object?>(String newRouteName, RoutePredicate predicate, {Object? arguments})
PushAndRemoveUntilNative = Future<T?> Function<T extends Object?>(BuildContext context, String newRouteName, RoutePredicate predicate, {Object? arguments})
PushNamed = Future<T?> Function<T>(String name, {Object? arguments})
PushNamedNative = Future<T?> Function<T>(BuildContext context, String name, {Object? arguments})
PushReplace = Future<T?> Function<T, R>(String name, {Object? arguments, R? result})
PushReplaceNative = Future<T?> Function<T, R>(BuildContext context, String name, {Object? arguments, R? result})
RePopAndPush = Future<String?> Function<R extends Object>(String name, {Object? arguments, R? result})
RePopAndPushNative = String Function<T, R>(BuildContext context, String name, {Object? arguments, R? result})
RePushAndRemoveUntil = Future<String?> Function(String newRouteName, RoutePredicate predicate, {Object? arguments})
RePushAndRemoveUntilNative = String Function<T extends Object?>(BuildContext context, String newRouteName, RoutePredicate predicate, {Object? arguments})
RePushNamed = Future<String?> Function(String name, {Object? arguments})
RePushNamedNative = String Function<T>(BuildContext context, String name, {Object? arguments})
RePushReplace = Future<String?> Function<R extends Object>(String name, {Object? arguments, R? result})
RePushReplaceNative = String Function<T, R>(BuildContext context, String name, {Object? arguments, R? result})
ShouldNotify<T, D extends Listenable> = T Function(D parent)
SnackbarDelegate = OverlayMixinDelegate<OverlayMixin>
StateGetter<T> = T? Function()
ToastDelegate = OverlayMixinDelegate<OverlayMixin>
WidgetGestureBuilder<T> = Widget Function(BuildContext context, UserGestureController<T> controller)

Exceptions / Errors

OverlayGetterError
通过 throw,退出循环