@@ -395,20 +395,6 @@ class ThemeData with Diagnosticable {
395395 'This feature was deprecated after v2.3.0-0.1.pre.' ,
396396 )
397397 Brightness ? accentColorBrightness,
398- @Deprecated (
399- 'No longer used by the framework, please remove any reference to it. '
400- 'For more information, consult the migration guide at '
401- 'https://flutter.dev/docs/release/breaking-changes/theme-data-accent-properties#migration-guide. '
402- 'This feature was deprecated after v2.3.0-0.1.pre.' ,
403- )
404- TextTheme ? accentTextTheme,
405- @Deprecated (
406- 'No longer used by the framework, please remove any reference to it. '
407- 'For more information, consult the migration guide at '
408- 'https://flutter.dev/docs/release/breaking-changes/theme-data-accent-properties#migration-guide. '
409- 'This feature was deprecated after v2.3.0-0.1.pre.' ,
410- )
411- IconThemeData ? accentIconTheme,
412398 @Deprecated (
413399 'This "fix" is now enabled by default. '
414400 'This feature was deprecated after v2.5.0-1.0.pre.' ,
@@ -521,7 +507,6 @@ class ThemeData with Diagnosticable {
521507 toggleableActiveColor ?? = isDark ? Colors .tealAccent[200 ]! : (accentColor ?? primarySwatch[600 ]! );
522508 accentColor ?? = isDark ? Colors .tealAccent[200 ]! : primarySwatch[500 ]! ;
523509 accentColorBrightness ?? = estimateBrightnessForColor (accentColor);
524- final bool accentIsDark = accentColorBrightness == Brightness .dark;
525510 focusColor ?? = isDark ? Colors .white.withOpacity (0.12 ) : Colors .black.withOpacity (0.12 );
526511 hoverColor ?? = isDark ? Colors .white.withOpacity (0.04 ) : Colors .black.withOpacity (0.04 );
527512 shadowColor ?? = Colors .black;
@@ -569,21 +554,17 @@ class ThemeData with Diagnosticable {
569554 : Typography .material2014 (platform: platform);
570555 TextTheme defaultTextTheme = isDark ? typography.white : typography.black;
571556 TextTheme defaultPrimaryTextTheme = primaryIsDark ? typography.white : typography.black;
572- TextTheme defaultAccentTextTheme = accentIsDark ? typography.white : typography.black;
573557 if (fontFamily != null ) {
574558 defaultTextTheme = defaultTextTheme.apply (fontFamily: fontFamily);
575559 defaultPrimaryTextTheme = defaultPrimaryTextTheme.apply (fontFamily: fontFamily);
576- defaultAccentTextTheme = defaultAccentTextTheme.apply (fontFamily: fontFamily);
577560 }
578561 if (fontFamilyFallback != null ) {
579562 defaultTextTheme = defaultTextTheme.apply (fontFamilyFallback: fontFamilyFallback);
580563 defaultPrimaryTextTheme = defaultPrimaryTextTheme.apply (fontFamilyFallback: fontFamilyFallback);
581- defaultAccentTextTheme = defaultAccentTextTheme.apply (fontFamilyFallback: fontFamilyFallback);
582564 }
583565 if (package != null ) {
584566 defaultTextTheme = defaultTextTheme.apply (package: package);
585567 defaultPrimaryTextTheme = defaultPrimaryTextTheme.apply (package: package);
586- defaultAccentTextTheme = defaultAccentTextTheme.apply (package: package);
587568 }
588569 textTheme = defaultTextTheme.merge (textTheme);
589570 primaryTextTheme = defaultPrimaryTextTheme.merge (primaryTextTheme);
@@ -635,8 +616,6 @@ class ThemeData with Diagnosticable {
635616 tooltipTheme ?? = const TooltipThemeData ();
636617
637618 // DEPRECATED (newest deprecations at the bottom)
638- accentTextTheme = defaultAccentTextTheme.merge (accentTextTheme);
639- accentIconTheme ?? = accentIsDark ? const IconThemeData (color: Colors .white) : const IconThemeData (color: Colors .black);
640619 fixTextFieldOutlineLabel ?? = true ;
641620 primaryColorBrightness = estimatedPrimaryColorBrightness;
642621 errorColor ?? = Colors .red[700 ]! ;
@@ -734,8 +713,6 @@ class ThemeData with Diagnosticable {
734713 // DEPRECATED (newest deprecations at the bottom)
735714 accentColor: accentColor,
736715 accentColorBrightness: accentColorBrightness,
737- accentTextTheme: accentTextTheme,
738- accentIconTheme: accentIconTheme,
739716 fixTextFieldOutlineLabel: fixTextFieldOutlineLabel,
740717 primaryColorBrightness: primaryColorBrightness,
741718 androidOverscrollIndicator: androidOverscrollIndicator,
@@ -860,20 +837,6 @@ class ThemeData with Diagnosticable {
860837 'This feature was deprecated after v2.3.0-0.1.pre.' ,
861838 )
862839 Brightness ? accentColorBrightness,
863- @Deprecated (
864- 'No longer used by the framework, please remove any reference to it. '
865- 'For more information, consult the migration guide at '
866- 'https://flutter.dev/docs/release/breaking-changes/theme-data-accent-properties#migration-guide. '
867- 'This feature was deprecated after v2.3.0-0.1.pre.' ,
868- )
869- TextTheme ? accentTextTheme,
870- @Deprecated (
871- 'No longer used by the framework, please remove any reference to it. '
872- 'For more information, consult the migration guide at '
873- 'https://flutter.dev/docs/release/breaking-changes/theme-data-accent-properties#migration-guide. '
874- 'This feature was deprecated after v2.3.0-0.1.pre.' ,
875- )
876- IconThemeData ? accentIconTheme,
877840 @Deprecated (
878841 'This "fix" is now enabled by default. '
879842 'This feature was deprecated after v2.5.0-1.0.pre.' ,
@@ -921,8 +884,6 @@ class ThemeData with Diagnosticable {
921884 // should not be `required`, use getter pattern to avoid breakages.
922885 _accentColor = accentColor,
923886 _accentColorBrightness = accentColorBrightness,
924- _accentTextTheme = accentTextTheme,
925- _accentIconTheme = accentIconTheme,
926887 _fixTextFieldOutlineLabel = fixTextFieldOutlineLabel,
927888 _primaryColorBrightness = primaryColorBrightness,
928889 _toggleableActiveColor = toggleableActiveColor,
@@ -934,8 +895,6 @@ class ThemeData with Diagnosticable {
934895 // DEPRECATED (newest deprecations at the bottom)
935896 assert (accentColor != null ),
936897 assert (accentColorBrightness != null ),
937- assert (accentTextTheme != null ),
938- assert (accentIconTheme != null ),
939898 assert (fixTextFieldOutlineLabel != null ),
940899 assert (primaryColorBrightness != null ),
941900 assert (errorColor != null ),
@@ -1630,46 +1589,6 @@ class ThemeData with Diagnosticable {
16301589 Brightness get accentColorBrightness => _accentColorBrightness! ;
16311590 final Brightness ? _accentColorBrightness;
16321591
1633- /// Obsolete property that was originally used when a [TextTheme]
1634- /// that contrasted well with the [accentColor] was needed.
1635- ///
1636- /// The material library no longer uses this property and most uses
1637- /// of [accentColor] have been replaced with
1638- /// the theme's [colorScheme] [ColorScheme.secondary] .
1639- /// You can configure the color of a [textTheme] [TextStyle] so that it
1640- /// contrasts well with the [ColorScheme.secondary] like this:
1641- ///
1642- /// ```dart
1643- /// final ThemeData theme = Theme.of(context);
1644- /// final TextStyle style = theme.textTheme.displayLarge!.copyWith(
1645- /// color: theme.colorScheme.onSecondary,
1646- /// );
1647- /// // ...use style...
1648- /// ```
1649- @Deprecated (
1650- 'No longer used by the framework, please remove any reference to it. '
1651- 'For more information, consult the migration guide at '
1652- 'https://flutter.dev/docs/release/breaking-changes/theme-data-accent-properties#migration-guide. '
1653- 'This feature was deprecated after v2.3.0-0.1.pre.' ,
1654- )
1655- TextTheme get accentTextTheme => _accentTextTheme! ;
1656- final TextTheme ? _accentTextTheme;
1657-
1658- /// Obsolete property that was originally used when an [IconTheme]
1659- /// that contrasted well with the [accentColor] was needed.
1660- ///
1661- /// The material library no longer uses this property and most uses
1662- /// of [accentColor] have been replaced with
1663- /// the theme's [colorScheme] [ColorScheme.secondary] .
1664- @Deprecated (
1665- 'No longer used by the framework, please remove any reference to it. '
1666- 'For more information, consult the migration guide at '
1667- 'https://flutter.dev/docs/release/breaking-changes/theme-data-accent-properties#migration-guide. '
1668- 'This feature was deprecated after v2.3.0-0.1.pre.' ,
1669- )
1670- IconThemeData get accentIconTheme => _accentIconTheme! ;
1671- final IconThemeData ? _accentIconTheme;
1672-
16731592 /// An obsolete flag to allow apps to opt-out of a
16741593 /// [small fix] (https://github.com/flutter/flutter/issues/54028) for the Y
16751594 /// coordinate of the floating label in a [TextField] [OutlineInputBorder] .
@@ -1868,20 +1787,6 @@ class ThemeData with Diagnosticable {
18681787 'This feature was deprecated after v2.3.0-0.1.pre.' ,
18691788 )
18701789 Brightness ? accentColorBrightness,
1871- @Deprecated (
1872- 'No longer used by the framework, please remove any reference to it. '
1873- 'For more information, consult the migration guide at '
1874- 'https://flutter.dev/docs/release/breaking-changes/theme-data-accent-properties#migration-guide. '
1875- 'This feature was deprecated after v2.3.0-0.1.pre.' ,
1876- )
1877- TextTheme ? accentTextTheme,
1878- @Deprecated (
1879- 'No longer used by the framework, please remove any reference to it. '
1880- 'For more information, consult the migration guide at '
1881- 'https://flutter.dev/docs/release/breaking-changes/theme-data-accent-properties#migration-guide. '
1882- 'This feature was deprecated after v2.3.0-0.1.pre.' ,
1883- )
1884- IconThemeData ? accentIconTheme,
18851790 @Deprecated (
18861791 'This "fix" is now enabled by default. '
18871792 'This feature was deprecated after v2.5.0-1.0.pre.' ,
@@ -2017,8 +1922,6 @@ class ThemeData with Diagnosticable {
20171922 // DEPRECATED (newest deprecations at the bottom)
20181923 accentColor: accentColor ?? _accentColor,
20191924 accentColorBrightness: accentColorBrightness ?? _accentColorBrightness,
2020- accentTextTheme: accentTextTheme ?? _accentTextTheme,
2021- accentIconTheme: accentIconTheme ?? _accentIconTheme,
20221925 fixTextFieldOutlineLabel: fixTextFieldOutlineLabel ?? _fixTextFieldOutlineLabel,
20231926 primaryColorBrightness: primaryColorBrightness ?? _primaryColorBrightness,
20241927 androidOverscrollIndicator: androidOverscrollIndicator ?? this .androidOverscrollIndicator,
@@ -2059,7 +1962,6 @@ class ThemeData with Diagnosticable {
20591962 () {
20601963 return baseTheme.copyWith (
20611964 primaryTextTheme: localTextGeometry.merge (baseTheme.primaryTextTheme),
2062- accentTextTheme: localTextGeometry.merge (baseTheme.accentTextTheme),
20631965 textTheme: localTextGeometry.merge (baseTheme.textTheme),
20641966 );
20651967 },
@@ -2212,8 +2114,6 @@ class ThemeData with Diagnosticable {
22122114 // DEPRECATED (newest deprecations at the bottom)
22132115 accentColor: Color .lerp (a.accentColor, b.accentColor, t),
22142116 accentColorBrightness: t < 0.5 ? a.accentColorBrightness : b.accentColorBrightness,
2215- accentTextTheme: TextTheme .lerp (a.accentTextTheme, b.accentTextTheme, t),
2216- accentIconTheme: IconThemeData .lerp (a.accentIconTheme, b.accentIconTheme, t),
22172117 fixTextFieldOutlineLabel: t < 0.5 ? a.fixTextFieldOutlineLabel : b.fixTextFieldOutlineLabel,
22182118 primaryColorBrightness: t < 0.5 ? a.primaryColorBrightness : b.primaryColorBrightness,
22192119 androidOverscrollIndicator: t < 0.5 ? a.androidOverscrollIndicator : b.androidOverscrollIndicator,
@@ -2321,8 +2221,6 @@ class ThemeData with Diagnosticable {
23212221 // DEPRECATED (newest deprecations at the bottom)
23222222 other.accentColor == accentColor &&
23232223 other.accentColorBrightness == accentColorBrightness &&
2324- other.accentTextTheme == accentTextTheme &&
2325- other.accentIconTheme == accentIconTheme &&
23262224 other.fixTextFieldOutlineLabel == fixTextFieldOutlineLabel &&
23272225 other.primaryColorBrightness == primaryColorBrightness &&
23282226 other.androidOverscrollIndicator == androidOverscrollIndicator &&
@@ -2427,8 +2325,6 @@ class ThemeData with Diagnosticable {
24272325 // DEPRECATED (newest deprecations at the bottom)
24282326 accentColor,
24292327 accentColorBrightness,
2430- accentTextTheme,
2431- accentIconTheme,
24322328 fixTextFieldOutlineLabel,
24332329 primaryColorBrightness,
24342330 androidOverscrollIndicator,
@@ -2535,8 +2431,6 @@ class ThemeData with Diagnosticable {
25352431 // DEPRECATED (newest deprecations at the bottom)
25362432 properties.add (ColorProperty ('accentColor' , accentColor, defaultValue: defaultData.accentColor, level: DiagnosticLevel .debug));
25372433 properties.add (EnumProperty <Brightness >('accentColorBrightness' , accentColorBrightness, defaultValue: defaultData.accentColorBrightness, level: DiagnosticLevel .debug));
2538- properties.add (DiagnosticsProperty <TextTheme >('accentTextTheme' , accentTextTheme, level: DiagnosticLevel .debug));
2539- properties.add (DiagnosticsProperty <IconThemeData >('accentIconTheme' , accentIconTheme, level: DiagnosticLevel .debug));
25402434 properties.add (DiagnosticsProperty <bool >('fixTextFieldOutlineLabel' , fixTextFieldOutlineLabel, level: DiagnosticLevel .debug));
25412435 properties.add (EnumProperty <Brightness >('primaryColorBrightness' , primaryColorBrightness, defaultValue: defaultData.primaryColorBrightness, level: DiagnosticLevel .debug));
25422436 properties.add (EnumProperty <AndroidOverscrollIndicator >('androidOverscrollIndicator' , androidOverscrollIndicator, defaultValue: null , level: DiagnosticLevel .debug));
0 commit comments