off<T> method

  1. @override
Future<T?> off<T>(
  1. Widget page(), {
  2. bool? opaque,
  3. Transition? transition,
  4. Curve? curve,
  5. Duration? duration,
  6. int? id,
  7. String? routeName,
  8. bool fullscreenDialog = false,
  9. dynamic arguments,
  10. List<BindingsInterface> bindings = const [],
  11. bool preventDuplicates = true,
  12. bool? popGesture,
  13. bool showCupertinoParallax = true,
  14. double gestureWidth(
    1. BuildContext context
    )?,
})
override

Implementation

@override
Future<T?> off<T>(
  Widget Function() page, {
  bool? opaque,
  Transition? transition,
  Curve? curve,
  Duration? duration,
  int? id,
  String? routeName,
  bool fullscreenDialog = false,
  dynamic arguments,
  List<BindingsInterface> bindings = const [],
  bool preventDuplicates = true,
  bool? popGesture,
  bool showCupertinoParallax = true,
  double Function(BuildContext context)? gestureWidth,
}) async {
  routeName = _cleanRouteName("/${page.runtimeType}");
  final route = GetPage<T>(
    name: routeName,
    opaque: opaque ?? true,
    page: page,
    gestureWidth: gestureWidth,
    showCupertinoParallax: showCupertinoParallax,
    popGesture: popGesture ?? Get.defaultPopGesture,
    transition: transition ?? Get.defaultTransition,
    curve: curve ?? Get.defaultTransitionCurve,
    fullscreenDialog: fullscreenDialog,
    bindings: bindings,
    transitionDuration: duration ?? Get.defaultTransitionDuration,
  );

  final args = _buildPageSettings(routeName, arguments);
  return _replace(args, route);
}