From 8f388bc1a25692ef0864a7d0236c19e114c1a563 Mon Sep 17 00:00:00 2001 From: James Williams <66931+jwill@users.noreply.github.com> Date: Fri, 13 Sep 2024 09:05:53 -0400 Subject: [PATCH] Update scheme.dart fix failing lint tests --- material_3_demo/lib/scheme.dart | 22 +--------------------- 1 file changed, 1 insertion(+), 21 deletions(-) diff --git a/material_3_demo/lib/scheme.dart b/material_3_demo/lib/scheme.dart index de6252107..b80ebe673 100644 --- a/material_3_demo/lib/scheme.dart +++ b/material_3_demo/lib/scheme.dart @@ -21,29 +21,10 @@ class SchemePreview extends StatefulWidget { final double contrast; @override - State createState() => _SchemePreviewState(contrast); + State createState() => _SchemePreviewState(); } class _SchemePreviewState extends State { - double contrast = 0; - - _SchemePreviewState(this.contrast); - - void setContrast(double value) { - if (mounted) { - setState(() { - contrast = value; - }); - } - } - - @override - void didUpdateWidget(covariant SchemePreview oldWidget) { - if (oldWidget.colorMatch != widget.colorMatch ) { - if (mounted) setState(() {}); - } - super.didUpdateWidget(oldWidget); - } @override Widget build(BuildContext context) { @@ -54,7 +35,6 @@ class _SchemePreviewState extends State { final dark = widget.brightness == Brightness.dark; final scheme = widget.scheme; - // TODO state.scheme(widget.brightness, contrastLevel: state.contrastLevel); return Theme( data: theme.copyWith(colorScheme: scheme),