rand dart fix

This commit is contained in:
2026-01-15 17:36:22 -08:00
parent dbbdafd893
commit 91e7e39fe8
131 changed files with 976 additions and 1365 deletions
@@ -18,8 +18,7 @@ class MyApp extends StatelessWidget {
margin: const EdgeInsets.all(4.0),
color: RandomColor(title.hashCode).randomColor(),
child: Stack(
overflow: Overflow.visible,
children: [
clipBehavior: Clip.none, children: [
child,
Positioned(
left: -50,
@@ -94,7 +93,7 @@ Widget _generateScreen({
return Scaffold(
appBar: AppBar(title: title),
backgroundColor: color,
body: args == null ? null : Center(child: Text(args.toString())),
body: Center(child: Text(args.toString())),
floatingActionButton: fab,
);
},
@@ -27,8 +27,7 @@ class MyApp extends StatelessWidget {
margin: const EdgeInsets.all(4.0),
color: RandomColor(title.hashCode).randomColor(),
child: Stack(
overflow: Overflow.visible,
children: [
clipBehavior: Clip.none, children: [
child,
Positioned(
left: -50,
@@ -106,7 +105,7 @@ Widget _generateScreen({
return Scaffold(
appBar: AppBar(title: title),
backgroundColor: color,
body: args == null ? null : Center(child: Text(args.toString())),
body: Center(child: Text(args.toString())),
floatingActionButton: fab,
);
},
@@ -47,7 +47,7 @@ Widget _generateScreen({
return Scaffold(
appBar: AppBar(title: title),
backgroundColor: color,
body: args == null ? null : Center(child: Text(args.toString())),
body: Center(child: Text(args.toString())),
floatingActionButton: fab,
);
},
@@ -79,7 +79,7 @@ Widget _generateScreen({
return Scaffold(
appBar: AppBar(title: title),
backgroundColor: color,
body: args == null ? null : Center(child: Text(args.toString())),
body: Center(child: Text(args.toString())),
floatingActionButton: fab,
);
},
@@ -37,7 +37,7 @@ Widget _generateScreen({
return Scaffold(
appBar: AppBar(title: title),
backgroundColor: color,
body: args == null ? null : Center(child: Text(args.toString())),
body: Center(child: Text(args.toString())),
floatingActionButton: fab,
);
},
@@ -38,7 +38,7 @@ Widget _generateScreen({
return Scaffold(
appBar: AppBar(title: title),
backgroundColor: color,
body: args == null ? null : Center(child: Text(args.toString())),
body: Center(child: Text(args.toString())),
floatingActionButton: fab,
);
},
+1 -1
View File
@@ -80,7 +80,7 @@ Widget _generateScreen({
return Scaffold(
appBar: AppBar(title: title),
backgroundColor: color,
body: args == null ? null : Center(child: Text(args.toString())),
body: Center(child: Text(args.toString())),
floatingActionButton: fab,
);
},
@@ -23,13 +23,13 @@ class _MediaQueryObserverState extends State<MediaQueryObserver>
@override
void initState() {
WidgetsBinding.instance?.addObserver(this);
WidgetsBinding.instance.addObserver(this);
super.initState();
}
@override
void dispose() {
WidgetsBinding.instance?.removeObserver(this);
WidgetsBinding.instance.removeObserver(this);
super.dispose();
}
@@ -37,7 +37,7 @@ class _MediaQueryObserverState extends State<MediaQueryObserver>
Widget build(BuildContext context) {
return MediaQuery(
data: widget.data ??
MediaQueryData.fromWindow(WidgetsBinding.instance!.window),
MediaQueryData.fromView(WidgetsBinding.instance.window),
child: widget.child,
);
}
@@ -38,7 +38,7 @@ class _NestedAppState extends State<NestedApp> {
void setup() {
_navKey = GlobalObjectKey<NavigatorState>(this);
WidgetsBinding.instance?.addPostFrameCallback((_) {
WidgetsBinding.instance.addPostFrameCallback((_) {
if (widget.route != null) {
_navKey.currentState?.pushReplacementNamed(
widget.route!.name!,
@@ -61,7 +61,6 @@ class _Lane extends StatelessWidget {
required this.androidDevice,
required this.cupertinoDevice,
this.title,
this.itemBuilder,
this.laneBuilder,
this.size,
this.shadow,