AnimatedThemeApp.router constructor

const AnimatedThemeApp.router({
  1. Key? key,
  2. GlobalKey<ScaffoldMessengerState>? scaffoldMessengerKey,
  3. RouteInformationProvider? routeInformationProvider,
  4. required RouteInformationParser<Object> routeInformationParser,
  5. required RouterDelegate<Object> routerDelegate,
  6. BackButtonDispatcher? backButtonDispatcher,
  7. TransitionBuilder? builder,
  8. String title = '',
  9. GenerateAppTitle? onGenerateTitle,
  10. Color? color,
  11. ThemeData? theme,
  12. AnimationType animationType = AnimationType.FADE_ANIMATED_THEME,
  13. Duration animationDuration = const Duration(milliseconds: 600),
  14. ThemeData? darkTheme,
  15. ThemeData? highContrastTheme,
  16. ThemeData? highContrastDarkTheme,
  17. ThemeMode? themeMode = ThemeMode.system,
  18. Locale? locale,
  19. Iterable<LocalizationsDelegate>? localizationsDelegates,
  20. LocaleListResolutionCallback? localeListResolutionCallback,
  21. LocaleResolutionCallback? localeResolutionCallback,
  22. Iterable<Locale> supportedLocales = const <Locale>[Locale('en', 'US')],
  23. bool debugShowMaterialGrid = false,
  24. bool showPerformanceOverlay = false,
  25. bool checkerboardRasterCacheImages = false,
  26. bool checkerboardOffscreenLayers = false,
  27. bool showSemanticsDebugger = false,
  28. bool debugShowCheckedModeBanner = true,
  29. Map<LogicalKeySet, Intent>? shortcuts,
  30. Map<Type, Action<Intent>>? actions,
  31. String? restorationScopeId,
  32. ScrollBehavior? scrollBehavior,
})

Creates a MaterialApp that uses the Router instead of a Navigator.

Implementation

const AnimatedThemeApp.router({
  Key? key,
  this.scaffoldMessengerKey,
  this.routeInformationProvider,
  required RouteInformationParser<Object> this.routeInformationParser,
  required RouterDelegate<Object> this.routerDelegate,
  this.backButtonDispatcher,
  this.builder,
  this.title = '',
  this.onGenerateTitle,
  this.color,
  this.theme,
  this.animationType = AnimationType.FADE_ANIMATED_THEME,
  this.animationDuration = const Duration(milliseconds: 600),
  this.darkTheme,
  this.highContrastTheme,
  this.highContrastDarkTheme,
  this.themeMode = ThemeMode.system,
  this.locale,
  this.localizationsDelegates,
  this.localeListResolutionCallback,
  this.localeResolutionCallback,
  this.supportedLocales = const <Locale>[Locale('en', 'US')],
  this.debugShowMaterialGrid = false,
  this.showPerformanceOverlay = false,
  this.checkerboardRasterCacheImages = false,
  this.checkerboardOffscreenLayers = false,
  this.showSemanticsDebugger = false,
  this.debugShowCheckedModeBanner = true,
  this.shortcuts,
  this.actions,
  this.restorationScopeId,
  this.scrollBehavior,
})  : assert(routeInformationParser != null),
      assert(routerDelegate != null),
      assert(title != null),
      assert(debugShowMaterialGrid != null),
      assert(showPerformanceOverlay != null),
      assert(checkerboardRasterCacheImages != null),
      assert(checkerboardOffscreenLayers != null),
      assert(showSemanticsDebugger != null),
      assert(debugShowCheckedModeBanner != null),
      navigatorObservers = null,
      navigatorKey = null,
      onGenerateRoute = null,
      home = null,
      onGenerateInitialRoutes = null,
      onUnknownRoute = null,
      routes = null,
      initialRoute = null,
      super(key: key);