Пример #1
0
        public override Widget build(BuildContext context)
        {
            ThemeData theme  = this.widget.theme ?? ThemeData.fallback();
            Widget    result = new AnimatedTheme(
                data: theme,
                isMaterialAppTheme: true,
                child: new WidgetsApp(
                    key: new GlobalObjectKey <State>(this),
                    navigatorKey: this.widget.navigatorKey,
                    navigatorObservers: this._navigatorObservers,
                    pageRouteBuilder: (RouteSettings settings, WidgetBuilder builder) =>
                    new MaterialPageRoute(settings: settings, builder: builder),
                    home: this.widget.home,
                    routes: this.widget.routes,
                    initialRoute: this.widget.initialRoute,
                    onGenerateRoute: this.widget.onGenerateRoute,
                    onUnknownRoute: this.widget.onUnknownRoute,
                    builder: this.widget.builder,
                    textStyle: AppUtils._errorTextStyle,
                    locale: this.widget.locale,
                    localizationsDelegates: this._localizationsDelegates,
                    localeResolutionCallback: this.widget.localeResolutionCallback,
                    localeListResolutionCallback: this.widget.localeListResolutionCallback,
                    supportedLocales: this.widget.supportedLocales,
                    showPerformanceOverlay: this.widget.showPerformanceOverlay
                    )
                );

            return(result);
        }
Пример #2
0
        public override Widget build(BuildContext context)
        {
            ThemeData theme  = this.widget.theme ?? ThemeData.fallback();
            Widget    result = new AnimatedTheme(
                data: theme,
                isMaterialAppTheme: true,
                child: new WidgetsApp(
                    key: new GlobalObjectKey <State>(this),
                    navigatorKey: this.widget.navigatorKey,
                    navigatorObservers: this._navigatorObservers,
                    pageRouteBuilder: (RouteSettings settings, WidgetBuilder builder) =>
                    new MaterialPageRoute(settings: settings, builder: builder),
                    home: this.widget.home,
                    routes: this.widget.routes,
                    initialRoute: this.widget.initialRoute,
                    onGenerateRoute: this.widget.onGenerateRoute,
                    onUnknownRoute: this.widget.onUnknownRoute,
                    builder: this.widget.builder,
                    textStyle: AppUtils._errorTextStyle
                    )
                );

            return(result);
        }