Skip to content

Commit 2911bfb

Browse files
authored
Make destructiveRed a CupertinoDynamicColor (flutter#141364)
`destructiveRed` is an alias for `systemRed`, but, in the definition, the precise type information is lost. This PR gives `destructiveRed` the type `CupertinoDynamicColor` (and not the superclass `Color`) like all the other colors defined in this file.
1 parent a069e62 commit 2911bfb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/flutter/lib/src/cupertino/colors.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ abstract final class CupertinoColors {
110110
/// or the foreground red theme in various native apps such as HealthKit.
111111
///
112112
/// This is SystemRed in the iOS palette.
113-
static const Color destructiveRed = systemRed;
113+
static const CupertinoDynamicColor destructiveRed = systemRed;
114114

115115
/// A blue color that can adapt to the given [BuildContext].
116116
///

0 commit comments

Comments
 (0)