DynamicApp class
Returns an app Widget depending on this user's devices' operating system.
See also:
- MaterialApp, Android Documentation located in file
package:flutter/material.dart
- CupertinoApp, IOS Documentation located in file
package:flutter/cupertino.dart
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- DynamicApp
Constructors
-
DynamicApp({Key? key, GlobalKey<
ScaffoldMessengerState> ? scaffoldMessengerKey, Widget? home, Map<String, WidgetBuilder> routes = const <String, WidgetBuilder>{}, String? initialRoute, RouteFactory? onGenerateRoute, InitialRouteListFactory? onGenerateInitialRoutes, RouteFactory? onUnknownRoute, TransitionBuilder? builder, String title = '', GenerateAppTitle? onGenerateTitle, Color? color, ThemeData? materialThemeData, ThemeData? darkTheme, ThemeData? highContrastTheme, ThemeData? highContrastDarkTheme, ThemeMode? themeMode = ThemeMode.system, Locale? locale, Iterable<LocalizationsDelegate> ? localizationsDelegates, LocaleListResolutionCallback? localeListResolutionCallback, LocaleResolutionCallback? localeResolutionCallback, Iterable<Locale> supportedLocales = const <Locale>[Locale('en', 'US')], bool debugShowMaterialGrid = false, bool showPerformanceOverlay = false, bool checkerboardRasterCacheImages = false, bool checkerboardOffscreenLayers = false, bool showSemanticsDebugger = false, bool debugShowCheckedModeBanner = true, Map<ShortcutActivator, Intent> ? shortcuts, Map<Type, Action< ? actions, String? restorationScopeId, ScrollBehavior? scrollBehavior, bool useInheritedMediaQuery = false})Intent> > -
const
Properties
-
actions
→ Map<
Type, Action< ?Intent> > -
{@tool snippet}
This example shows how to add a single action handling an
ActivateAction to the default actions without needing to
add your own Actions widget.
final
- backButtonDispatcher → BackButtonDispatcher?
-
Both Android and IOS
final
- builder → TransitionBuilder?
-
Both Android and IOS
final
- checkerboardOffscreenLayers → bool
-
Both Android and IOS
final
- checkerboardRasterCacheImages → bool
-
Both Android and IOS
final
- color → Color?
-
Both Android and IOS
final
- darkTheme → ThemeData?
-
Both Android and IOS
final
- debugShowCheckedModeBanner → bool
-
Both Android and IOS
final
- debugShowMaterialGrid → bool
-
Both Android and IOS
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- highContrastDarkTheme → ThemeData?
-
Both Android and IOS
final
- highContrastTheme → ThemeData?
-
Both Android and IOS
final
- home → Widget?
-
Both Android and IOS
final
- initialRoute → String?
-
Both Android and IOS
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- locale → Locale?
-
Both Android and IOS
final
- localeListResolutionCallback → LocaleListResolutionCallback?
-
Both Android and IOS
final
- localeResolutionCallback → LocaleResolutionCallback?
-
Both Android and IOS
final
-
localizationsDelegates
→ Iterable<
LocalizationsDelegate> ? -
Both Android and IOS
final
- materialThemeData → ThemeData?
-
Both Android and IOS
final
-
Both Android and IOS
final
-
Both Android and IOS
final
- onGenerateInitialRoutes → InitialRouteListFactory?
-
Both Android and IOS
final
- onGenerateRoute → RouteFactory?
-
Both Android and IOS
final
- onGenerateTitle → GenerateAppTitle?
-
Both Android and IOS
final
- onUnknownRoute → RouteFactory?
-
Both Android and IOS
final
- restorationScopeId → String?
-
Both Android and IOS
final
-
routeInformationParser
→ RouteInformationParser<
Object> ? -
Both Android and IOS
final
- routeInformationProvider → RouteInformationProvider?
-
Both Android and IOS
final
-
routerDelegate
→ RouterDelegate<
Object> ? -
Both Android and IOS
final
-
routes
→ Map<
String, WidgetBuilder> ? -
Both Android and IOS
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
scaffoldMessengerKey
→ GlobalKey<
ScaffoldMessengerState> ? -
Both Android and IOS
final
- scrollBehavior → ScrollBehavior?
-
Both Android and IOS
final
-
shortcuts
→ Map<
ShortcutActivator, Intent> ? -
Both Android and IOS
final
- showPerformanceOverlay → bool
-
Both Android and IOS
final
- showSemanticsDebugger → bool
-
Both Android and IOS
final
-
supportedLocales
→ Iterable<
Locale> -
Both Android and IOS
final
- themeMode → ThemeMode?
-
Both Android and IOS
final
- title → String
-
Both Android and IOS
final
- useInheritedMediaQuery → bool
-
Both Android and IOS
final
Methods
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → DynamicMaterialAppState - Creates the mutable state for this widget at a given location in the tree.
-
debugDescribeChildren(
) → List< DiagnosticsNode> -
Returns a list of
DiagnosticsNode
objects describing this node's children.inherited -
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toDiagnosticsNode(
{String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode -
Returns a debug representation of the object that is used by debugging
tools and by DiagnosticsNode.toStringDeep.
inherited
-
toString(
{DiagnosticLevel minLevel = DiagnosticLevel.info}) → String -
A string representation of this object.
inherited
-
toStringDeep(
{String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a string representation of this node and its descendants.
inherited
-
toStringShallow(
{String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a one-line detailed description of the object.
inherited
-
toStringShort(
) → String -
A short, textual description of this widget.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited