PlatformSnackApp constructor

const PlatformSnackApp({
  1. Key? key,
  2. Key? widgetKey,
  3. GlobalKey<NavigatorState>? navigatorKey,
  4. Widget? home,
  5. String? initialRoute,
  6. Route onGenerateRoute(
    1. RouteSettings
    )?,
  7. List<Route> onGenerateInitialRoutes(
    1. String
    )?,
  8. Route onUnknownRoute(
    1. RouteSettings
    )?,
  9. Map<String, Widget Function(BuildContext)> routes = const <String, WidgetBuilder>{},
  10. String onGenerateTitle(
    1. BuildContext
    )?,
  11. List<NavigatorObserver> navigatorObservers = const <NavigatorObserver>[],
  12. Widget builder(
    1. BuildContext,
    2. Widget?
    )?,
  13. String title = '',
  14. Color? color,
  15. Locale? locale,
  16. Iterable<LocalizationsDelegate>? localizationsDelegates,
  17. Locale? localeListResolutionCallback(
    1. List<Locale>?,
    2. Iterable<Locale>
    )?,
  18. Locale? localeResolutionCallback(
    1. Locale?,
    2. Iterable<Locale>
    )?,
  19. Iterable<Locale> supportedLocales = const <Locale>[Locale('en', 'US')],
  20. bool showPerformanceOverlay = false,
  21. bool checkerboardRasterCacheImages = false,
  22. bool checkerboardOffscreenLayers = false,
  23. bool showSemanticsDebugger = false,
  24. bool debugShowCheckedModeBanner = true,
  25. Map<LogicalKeySet, Intent>? shortcuts,
  26. Map<Type, Action<Intent>>? actions,
  27. String? restorationScopeId,
  28. ScrollBehavior? scrollBehavior,
  29. GlobalKey<ScaffoldMessengerState>? scaffoldMessengerKey,
  30. CupertinoThemeData? cupertinoTheme,
  31. ThemeMode? materialThemeMode = ThemeMode.system,
  32. ThemeData? materialTheme,
  33. ThemeData? materialDarkTheme,
  34. ThemeData? materialHighContrastTheme,
  35. ThemeData? materialHighContrastDarkTheme,
  36. Curve materialThemeAnimationCurve = Curves.linear,
  37. Duration materialThemeAnimationDuration = kThemeAnimationDuration,
})

Implementation

const PlatformSnackApp({
  super.key,
  this.widgetKey,
  this.navigatorKey,
  this.home,
  this.initialRoute,
  this.onGenerateRoute,
  this.onGenerateInitialRoutes,
  this.onUnknownRoute,
  this.routes = const <String, WidgetBuilder>{},
  this.onGenerateTitle,
  this.navigatorObservers = const <NavigatorObserver>[],
  this.builder,
  this.title = '',
  this.color,
  this.locale,
  this.localizationsDelegates,
  this.localeListResolutionCallback,
  this.localeResolutionCallback,
  this.supportedLocales = const <Locale>[Locale('en', 'US')],
  this.showPerformanceOverlay = false,
  this.checkerboardRasterCacheImages = false,
  this.checkerboardOffscreenLayers = false,
  this.showSemanticsDebugger = false,
  this.debugShowCheckedModeBanner = true,
  this.shortcuts,
  this.actions,
  this.restorationScopeId,
  this.scrollBehavior,
  this.scaffoldMessengerKey,
  this.cupertinoTheme,
  this.materialThemeMode = ThemeMode.system,
  this.materialTheme,
  this.materialDarkTheme,
  this.materialHighContrastTheme,
  this.materialHighContrastDarkTheme,
  this.materialThemeAnimationCurve = Curves.linear,
  this.materialThemeAnimationDuration = kThemeAnimationDuration,
})  : _isRouter = false,
      backButtonDispatcher = null,
      routerConfig = null,
      routeInformationProvider = null,
      routeInformationParser = null,
      routerDelegate = null;