File tree Expand file tree Collapse file tree 1 file changed +14
-5
lines changed Expand file tree Collapse file tree 1 file changed +14
-5
lines changed Original file line number Diff line number Diff line change @@ -306,11 +306,20 @@ class Explainer {
306306 return attr;
307307 }
308308
309- String _color (Color c) =>
310- '#${_colorHex (c .a )}${_colorHex (c .r )}${_colorHex (c .g )}${_colorHex (c .b )}' ;
311-
312- String _colorHex (double d) {
313- final i = (d * 255.0 ).round () & 0xff ;
309+ // TODO: remove lint ignore when our minimum Flutter version >= 3.24
310+ // ignore: deprecated_member_use
311+ String _color (Color c) => '#${_colorHex (c .alpha )}'
312+ // TODO: remove lint ignore when our minimum Flutter version >= 3.24
313+ // ignore: deprecated_member_use
314+ '${_colorHex (c .red )}'
315+ // TODO: remove lint ignore when our minimum Flutter version >= 3.24
316+ // ignore: deprecated_member_use
317+ '${_colorHex (c .green )}'
318+ // TODO: remove lint ignore when our minimum Flutter version >= 3.24
319+ // ignore: deprecated_member_use
320+ '${_colorHex (c .blue )}' ;
321+
322+ String _colorHex (int i) {
314323 final h = i.toRadixString (16 ).toUpperCase ();
315324 return h.length == 1 ? '0$h ' : h;
316325 }
You can’t perform that action at this time.
0 commit comments